The Puppet Labs Issue Tracker has Moved: https://tickets.puppetlabs.com

Bug #17305

puppet module build fails with Error: undefined method `downcase' for nil:NilClass

Added by Jeff McCune over 1 year ago. Updated over 1 year ago.

Status:DuplicateStart date:
Priority:NormalDue date:
Assignee:-% Done:

0%

Category:module tool
Target version:3.1.0
Affected Puppet version:3.0.0 Branch:mccune
Keywords:module

We've Moved!

Ticket tracking is now hosted in JIRA: https://tickets.puppetlabs.com

This issue is currently not available for export. If you are experiencing the issue described below, please file a new ticket in JIRA. Once a new ticket has been created, please add a link to it that points back to this Redmine ticket.


Description

Overview

This appears to be a regression of #13070 and GH-677 and GH-950.

Trying to build the mount_providers module, the following exception is raised:

$ git describe
3.0.0-37-g38f975f

$ puppet module build --trace
Error: undefined method `downcase' for nil:NilClass
/workspace/puppet-3.x/src/puppet/lib/puppet/type.rb:1353:in `block in providify'
/workspace/puppet-3.x/src/puppet/lib/puppet/util/classgen.rb:117:in `class_eval'
/workspace/puppet-3.x/src/puppet/lib/puppet/util/classgen.rb:117:in `genthing'
/workspace/puppet-3.x/src/puppet/lib/puppet/util/classgen.rb:28:in `genclass'
/workspace/puppet-3.x/src/puppet/lib/puppet/type.rb:226:in `newparam'
/workspace/puppet-3.x/src/puppet/lib/puppet/type.rb:1347:in `providify'
/workspace/puppet-3.x/src/puppet/lib/puppet/metatype/manager.rb:94:in `newtype'
/workspace/puppet-3.x/modules/mount_providers/lib/puppet/type/mountpoint.rb:1:in `'
/Users/jeff/.rbenv/versions/1.9.3-p194/lib/ruby/1.9.1/rubygems/custom_require.rb:36:in `require'
/Users/jeff/.rbenv/versions/1.9.3-p194/lib/ruby/1.9.1/rubygems/custom_require.rb:36:in `require'
/workspace/puppet-3.x/src/puppet/lib/puppet/module_tool/contents_description.rb:34:in `block in data'
/workspace/puppet-3.x/src/puppet/lib/puppet/module_tool/contents_description.rb:33:in `each'
/workspace/puppet-3.x/src/puppet/lib/puppet/module_tool/contents_description.rb:33:in `data'
/workspace/puppet-3.x/src/puppet/lib/puppet/module_tool/contents_description.rb:15:in `annotate'
/workspace/puppet-3.x/src/puppet/lib/puppet/module_tool/applications/application.rb:44:in `metadata'
/workspace/puppet-3.x/src/puppet/lib/puppet/module_tool/applications/application.rb:59:in `load_modulefile!'
/workspace/puppet-3.x/src/puppet/lib/puppet/module_tool/applications/builder.rb:14:in `run'
/workspace/puppet-3.x/src/puppet/lib/puppet/module_tool/applications/application.rb:11:in `run'
/workspace/puppet-3.x/src/puppet/lib/puppet/face/module/build.rb:55:in `block (3 levels) in '
/workspace/puppet-3.x/src/puppet/lib/puppet/interface/action.rb+eval[wrapper]:210:in `build'
/workspace/puppet-3.x/src/puppet/lib/puppet/application/face_base.rb:229:in `main'
/workspace/puppet-3.x/src/puppet/lib/puppet/application.rb:354:in `run_command'
/workspace/puppet-3.x/src/puppet/lib/puppet/application.rb:346:in `block (2 levels) in run'
/workspace/puppet-3.x/src/puppet/lib/puppet/application.rb:438:in `plugin_hook'
/workspace/puppet-3.x/src/puppet/lib/puppet/application.rb:346:in `block in run'
/workspace/puppet-3.x/src/puppet/lib/puppet/util.rb:500:in `exit_on_fail'
/workspace/puppet-3.x/src/puppet/lib/puppet/application.rb:346:in `run'
/workspace/puppet-3.x/src/puppet/lib/puppet/util/command_line.rb:87:in `execute'
/workspace/puppet-3.x/src/puppet/bin/puppet:4:in `
'

Steps to reproduce

$ rake voltron
 * puppet                   3.0.x                     3.0.1-27-gf9d70b5       f9d70b5
 * facter                   fix/2.x/cleanup_ec2_facts 1.6.14-rc1-306-g1034b82 1034b82
 * hiera                    1.x                       1.0.0rc4-6-g3b89fbe     3b89fbe
 * rspec-puppet             master                    v0.1.5                  695b9a4
 * puppetlabs_spec_helper   master                    0.3.0-3-gdf3b021        df3b021
 * fog                      0.7.2                     v0.7.2                  c7ec7c9
 * rbvmomi                  master                    N/A                     5dc0ca3
 * stdlib                   3.x                       3.1.1-7-g6f0c1e2        6f0c1e2
 * hiera_puppet             v0.3.0                    v0.3.0                  06e70f3
 * mount_providers          master                    0.0.2                   233e3f6
 * pe_mcollective           master                    0.0.45-2-g64c6523       64c6523
 * pe_accounts              master                    1.0.3                   0725c16
 * pe_compliance            master                    0.0.5                   dddc001
 * cloud_provisioner        master                    1.0.5-6-gd69f962        d69f962
 * cloud_provisioner_vmware master                    v1.0.0-5-g6eaab64       6eaab64
 * hiera_puppet             v0.3.0                    v0.3.0                  06e70f3
 * json                     gem                       1.5.4                   N/A    
 * mocha                    gem                       0.10.5                  N/A    
 * rack                     gem                       1.4.1                   N/A    
 * rack-protection          gem                       1.2.0                   N/A    
 * rspec                    gem                       2.10.0                  N/A    
 * rspec-core               gem                       2.10.1                  N/A    
 * rspec-expectations       gem                       2.10.0                  N/A    
 * rspec-mocks              gem                       2.10.1                  N/A    
 * rspec-puppet             gem                       0.1.5                   N/A    

$ git clone git://github.com/puppetlabs/puppetlabs-mount_providers.git
Cloning into 'puppetlabs-mount_providers'...
remote: Counting objects: 235, done.
remote: Compressing objects: 100% (164/164), done.
remote: Total 235 (delta 56), reused 220 (delta 42)
Receiving objects: 100% (235/235), 36.82 KiB, done.
Resolving deltas: 100% (56/56), done.

$ cd puppetlabs-mount_providers

$ puppet module build --trace
Error: undefined method `downcase' for nil:NilClass
/workspace/puppet-3.x/src/puppet/lib/puppet/type.rb:1353:in `block in providify'
/workspace/puppet-3.x/src/puppet/lib/puppet/util/classgen.rb:117:in `class_eval'
/workspace/puppet-3.x/src/puppet/lib/puppet/util/classgen.rb:117:in `genthing'
/workspace/puppet-3.x/src/puppet/lib/puppet/util/classgen.rb:28:in `genclass'
/workspace/puppet-3.x/src/puppet/lib/puppet/type.rb:226:in `newparam'
/workspace/puppet-3.x/src/puppet/lib/puppet/type.rb:1347:in `providify'
/workspace/puppet-3.x/src/puppet/lib/puppet/metatype/manager.rb:94:in `newtype'
/workspace/puppet-3.x/puppetlabs-mount_providers/lib/puppet/type/mountpoint.rb:1:in `'
/Users/jeff/.rbenv/versions/1.9.3-p194/lib/ruby/1.9.1/rubygems/custom_require.rb:36:in `require'
/Users/jeff/.rbenv/versions/1.9.3-p194/lib/ruby/1.9.1/rubygems/custom_require.rb:36:in `require'
/workspace/puppet-3.x/src/puppet/lib/puppet/module_tool/contents_description.rb:34:in `block in data'
/workspace/puppet-3.x/src/puppet/lib/puppet/module_tool/contents_description.rb:33:in `each'
/workspace/puppet-3.x/src/puppet/lib/puppet/module_tool/contents_description.rb:33:in `data'
/workspace/puppet-3.x/src/puppet/lib/puppet/module_tool/contents_description.rb:15:in `annotate'
/workspace/puppet-3.x/src/puppet/lib/puppet/module_tool/applications/application.rb:44:in `metadata'
/workspace/puppet-3.x/src/puppet/lib/puppet/module_tool/applications/application.rb:59:in `load_modulefile!'
/workspace/puppet-3.x/src/puppet/lib/puppet/module_tool/applications/builder.rb:14:in `run'
/workspace/puppet-3.x/src/puppet/lib/puppet/module_tool/applications/application.rb:11:in `run'
/workspace/puppet-3.x/src/puppet/lib/puppet/face/module/build.rb:55:in `block (3 levels) in '
/workspace/puppet-3.x/src/puppet/lib/puppet/interface/action.rb+eval[wrapper]:210:in `build'
/workspace/puppet-3.x/src/puppet/lib/puppet/application/face_base.rb:229:in `main'
/workspace/puppet-3.x/src/puppet/lib/puppet/application.rb:354:in `run_command'
/workspace/puppet-3.x/src/puppet/lib/puppet/application.rb:346:in `block (2 levels) in run'
/workspace/puppet-3.x/src/puppet/lib/puppet/application.rb:438:in `plugin_hook'
/workspace/puppet-3.x/src/puppet/lib/puppet/application.rb:346:in `block in run'
/workspace/puppet-3.x/src/puppet/lib/puppet/util.rb:500:in `exit_on_fail'
/workspace/puppet-3.x/src/puppet/lib/puppet/application.rb:346:in `run'
/workspace/puppet-3.x/src/puppet/lib/puppet/util/command_line.rb:87:in `execute'
/workspace/puppet-3.x/src/puppet/bin/puppet:4:in `
' Error: Try 'puppet help module build' for usage

Related issues

Related to Puppet - Bug #7316: puppet face applications (subcommands) delivered via modu... Closed 05/02/2011
Related to Puppet - Refactor #18569: Implement "whiny nil" for Puppet, solve `Undefined method... Rejected
Duplicates Puppet - Bug #13070: puppet describe --list explodes with undefined method 'do... Closed 03/12/2012

History

#1 Updated by Jeff McCune over 1 year ago

  • Subject changed from mccune to puppet module build fails with Error: undefined method `downcase' for nil:NilClass

#2 Updated by Jeff McCune over 1 year ago

  • Description updated (diff)

#3 Updated by Andrew Parker over 1 year ago

  • Status changed from Unreviewed to Needs More Information
  • Assignee set to Jeff McCune
  • Target version changed from 3.0.x to 3.1.0

Is this only a problem with module build? If so then this is an extension of #13070, but not a regression. I’m going to tie this to the code-loading work that we are going to do in 3.1.

#4 Updated by Josh Cooper over 1 year ago

I’m not able to reproduce this with 3.0.0 or later. I think it is a dup of #13070, but Jeff can you confirm?

#5 Updated by Jeff McCune over 1 year ago

  • Status changed from Needs More Information to Duplicate
  • Assignee deleted (Jeff McCune)

Josh Cooper wrote:

I’m not able to reproduce this with 3.0.0 or later. I think it is a dup of #13070, but Jeff can you confirm?

Confirmed.

-Jeff

Also available in: Atom PDF