railsmachine/shadow_puppet — Issue #12: Uncaught exception: LoadError: no such file to load -- active_support/core_ext/class/inheritable_attributes
Author: charliejones
Created: 2012-01-25 19:08:18+00:00
State: open

I'm running into a moonshine problem and it appears to be linked to shadow_puppet. Specifically, on a new host a cap deploy:setup fails. I've included before and after snippets or the console output.

This used to work:
* executing "sudo -p 'sudo password: ' shadow_puppet /tmp/moonshine_setup_manifest.rb"
servers: ["ec2-nn-nn-nn-nn.compute-1.amazonaws.com"]
[ec2-nn-nn-nn-nn.compute-1.amazonaws.com] executing command
** [out :: ec2-nn-nn-nn-nn.compute-1.amazonaws.com] DEPRECATION WARNING: class_inheritable_attribute is deprecated, please use class_attribute method instead. Notice their behavior are slightly different, so refer to class_attribute documentation first. (called from gem_original_require at /usr/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:36)
** [out :: ec2-nn-nn-nn-nn.compute-1.amazonaws.com] DEPRECATION WARNING: class_inheritable_attribute is deprecated, please use class_attribute method instead. Notice their behavior are slightly different, so refer to class_attribute documentation first. (called from gem_original_require at /usr/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:36)
** [out :: ec2-nn-nn-nn-nn.compute-1.amazonaws.com] DEPRECATION WARNING: class_inheritable_attribute is deprecated, please use class_attribute method instead. Notice their behavior are slightly different, so refer to class_attribute documentation first. (called from gem_original_require at /usr/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:36)
** [out :: ec2-nn-nn-nn-nn.compute-1.amazonaws.com] DEPRECATION WARNING: class_inheritable_attribute is deprecated, please use class_attribute method instead. Notice their behavior are slightly different, so refer to class_attribute documentation first. (called from gem_original_require at /usr/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:36)
** [out :: ec2-nn-nn-nn-nn.compute-1.amazonaws.com] notice: /File[/etc/shadow_puppet]/ensure: created
** [out :: ec2-nn-nn-nn-nn.compute-1.amazonaws.com] notice: /File[/var/shadow_puppet]/ensure: created
** [out :: ec2-nn-nn-nn-nn.compute-1.amazonaws.com] notice: /File[/srv/connected_health_platform]/ensure: created
** [out :: ec2-nn-nn-nn-nn.compute-1.amazonaws.com] notice: /File[/srv/connected_health_platform/shared]/ensure: created
** [out :: ec2-nn-nn-nn-nn.compute-1.amazonaws.com] notice: /File[/srv/connected_health_platform/releases]/ensure: created
** [out :: ec2-nn-nn-nn-nn.compute-1.amazonaws.com] notice: /File[/srv/connected_health_platform/shared/config]/ensure: created
command finished in 3173ms

Now it does not:
* executing "sudo -p 'sudo password: ' shadow_puppet /tmp/moonshine_setup_manifest.rb"
servers: ["ec2-nn-nn-nn-nn.compute-1.amazonaws.com"]
[ec2-nn-nn-nn-nn.compute-1.amazonaws.com] executing command
** [out :: ec2-nn-nn-nn-nn.compute-1.amazonaws.com] Uncaught exception: LoadError: no such file to load -- active_support/core_ext/class/inheritable_attributes
** [out :: ec2-nn-nn-nn-nn.compute-1.amazonaws.com] /usr/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:36:in `gem_original_require'
** [out :: ec2-nn-nn-nn-nn.compute-1.amazonaws.com] /usr/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:36:in `require'
** [out :: ec2-nn-nn-nn-nn.compute-1.amazonaws.com] /usr/lib/ruby/gems/1.8/gems/shadow_puppet-0.5.2/bin/../lib/shadow_puppet/core_ext.rb:7
** [out :: ec2-nn-nn-nn-nn.compute-1.amazonaws.com] /usr/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:36:in `gem_original_require'
** [out :: ec2-nn-nn-nn-nn.compute-1.amazonaws.com] /usr/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:36:in `require'
** [out :: ec2-nn-nn-nn-nn.compute-1.amazonaws.com] /usr/lib/ruby/gems/1.8/gems/shadow_puppet-0.5.2/bin/shadow_puppet:118
** [out :: ec2-nn-nn-nn-nn.compute-1.amazonaws.com] /usr/bin/shadow_puppet:19:in `load'
** [out :: ec2-nn-nn-nn-nn.compute-1.amazonaws.com] /usr/bin/shadow_puppet:19
command finished in 306ms
failed: "sh -c 'sudo -p '\\''sudo password: '\\'' shadow_puppet /tmp/moonshine_setup_manifest.rb'" on ec2-nn-nn-nn-nn.compute-1.amazonaws.com

The problem appears to be that shadow_puppet is installing activesuport-3.2.0 to fulfill a dependency requirement. The calls that were deprecation warnings in previous versions of activesupport are now removed and failing. My initial research shows that activesupport-3.1.3 is last version this worked under, as such I'm hoping you can alter the dependency to not exceed this version. For reference here are the gems that are getting installed during the deploy:setup.

*** LOCAL GEMS ***

activesupport (3.2.0)
builder (3.0.0)
bundler (1.0.21)
facter (1.6.4)
highline (1.6.9)
i18n (0.6.0)
multi_json (1.0.4)
puppet (2.7.3, 0.24.8)
rake (0.9.2.2)
shadow_puppet (0.5.2)