Uploaded image for project: 'Puppet'
  1. Puppet
  2. PUP-7795

Running "bundle install" on a new puppet module breaks puppet

    XMLWordPrintable

Details

    • Bug
    • Status: Closed
    • Blocker
    • Resolution: Cannot Reproduce
    • PUP 4.8.2
    • None
    • Modules
    • Platform Core
    • Needs Assessment
    • Needs Assessment

    Description

      After creating a new module using "puppet module generate tristan-test" (for example) and installing the gems with bundler ("cd test && bundle install"), lots of puppet functionality seems to break.

      For example, I cannot run unit tests with "rake spec", every single test fails with the same error message:

      NoMethodError:
      undefined method `_' for #<Puppet::Resource::Catalog::Compiler:0x0055c17a1290d0>

      1. /var/lib/gems/2.3.0/gems/puppet-5.0.1/lib/puppet/indirector/catalog/compiler.rb:68:in `initialize'
      2. /var/lib/gems/2.3.0/gems/rspec-puppet-2.6.4/lib/rspec-puppet/adapters.rb:83:in `catalog'
      3. /var/lib/gems/2.3.0/gems/rspec-puppet-2.6.4/lib/rspec-puppet/adapters.rb:161:in `catalog'
      4. /var/lib/gems/2.3.0/gems/rspec-puppet-2.6.4/lib/rspec-puppet/support.rb:366:in `build_catalog_without_cache'
      5. /var/lib/gems/2.3.0/gems/rspec-puppet-2.6.4/lib/rspec-puppet/support.rb:381:in `block in build_catalog'
      6. /var/lib/gems/2.3.0/gems/rspec-puppet-2.6.4/lib/rspec-puppet/cache.rb:17:in `get'
      7. /var/lib/gems/2.3.0/gems/rspec-puppet-2.6.4/lib/rspec-puppet/support.rb:380:in `build_catalog'
      8. /var/lib/gems/2.3.0/gems/rspec-puppet-2.6.4/lib/rspec-puppet/support.rb:87:in `block in load_catalogue'
      9. /var/lib/gems/2.3.0/gems/rspec-puppet-2.6.4/lib/rspec-puppet/support.rb:331:in `with_vardir'
      10. /var/lib/gems/2.3.0/gems/rspec-puppet-2.6.4/lib/rspec-puppet/support.rb:81:in `load_catalogue'
      11. /var/lib/gems/2.3.0/gems/rspec-puppet-2.6.4/lib/rspec-puppet/example/class_example_group.rb:7:in `catalogue'
      12. /var/lib/gems/2.3.0/gems/rspec-puppet-2.6.4/lib/rspec-puppet/support.rb:11:in `block in subject'
      13. /var/lib/gems/2.3.0/gems/rspec-puppet-2.6.4/lib/rspec-puppet/matchers/create_generic.rb:84:in `matches?'
      14. ./spec/classes/init_spec.rb:4:in `block (3 levels) in <top (required)>'

      Additionally, some of puppet's own commands seem to also break. For example, if I try to create a new puppet module after installing the gems (using "puppet module generate tristan-test2"), I get the following error:

      Error: Could not autoload puppet/face/module/list: undefined method `_' for #<Puppet::Interface::ActionBuilder:0x0055d341742b78>
      Error: Could not parse application options: Could not autoload puppet/face/module/list: undefined method `_' for #<Puppet::Interface::ActionBuilder:0x0055d341742b78>

      Attachments

        Activity

          People

            starcraft66 Tristan Gosselin-Hane
            starcraft66 Tristan Gosselin-Hane
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Zendesk Support