Paperclip wont let me unpack gems :(

3 views
Skip to first unread message

pimpmaster

unread,
Oct 30, 2009, 7:22:08 AM10/30/09
to Paperclip Plugin
I have this problem since upgrading to Rails 2.3.4. I had some
conflicts with gem versions so I update config.gems and then:

rake gems:unpack --trace
(in /Users/home/Desktop/stellenverteiler)
** Invoke gems:unpack (first_time)
** Invoke gems:install (first_time)
** Invoke gems:base (first_time)
** Execute gems:base
** Invoke environment (first_time)
** Execute environment
rake aborted!
undefined method `has_attached_file' for #<Class:0x3558284>
/usr/local/lib/ruby/gems/1.8/gems/activerecord-2.3.4/lib/active_record/
base.rb:1959:in `method_missing'
/Users/home/Desktop/stellenverteiler/app/models/applicant.rb:21
/usr/local/lib/ruby/gems/1.8/gems/activesupport-2.3.4/lib/
active_support/dependencies.rb:380:in
`load_without_new_constant_marking'
/usr/local/lib/ruby/gems/1.8/gems/activesupport-2.3.4/lib/
active_support/dependencies.rb:380:in `load_file'
/usr/local/lib/ruby/gems/1.8/gems/activesupport-2.3.4/lib/
active_support/dependencies.rb:521:in `new_constants_in'
/usr/local/lib/ruby/gems/1.8/gems/activesupport-2.3.4/lib/
active_support/dependencies.rb:379:in `load_file'
/usr/local/lib/ruby/gems/1.8/gems/activesupport-2.3.4/lib/
active_support/dependencies.rb:259:in `require_or_load'
/usr/local/lib/ruby/gems/1.8/gems/activesupport-2.3.4/lib/
active_support/dependencies.rb:224:in `depend_on'
/usr/local/lib/ruby/gems/1.8/gems/activesupport-2.3.4/lib/
active_support/dependencies.rb:136:in `require_dependency'
/Users/home/Desktop/stellenverteiler/app/workers/email_worker.rb:2
/usr/local/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:31:in
`gem_original_require'
/usr/local/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:31:in
`require'
/usr/local/lib/ruby/gems/1.8/gems/activesupport-2.3.4/lib/
active_support/dependencies.rb:156:in `require'
/usr/local/lib/ruby/gems/1.8/gems/activesupport-2.3.4/lib/
active_support/dependencies.rb:521:in `new_constants_in'
/usr/local/lib/ruby/gems/1.8/gems/activesupport-2.3.4/lib/
active_support/dependencies.rb:156:in `require'
/Users/home/Desktop/stellenverteiler/vendor/plugins/workling/lib/
workling/discovery.rb:11:in `discover!'
/Users/home/Desktop/stellenverteiler/vendor/plugins/workling/lib/
workling/discovery.rb:11:in `each'
/Users/home/Desktop/stellenverteiler/vendor/plugins/workling/lib/
workling/discovery.rb:11:in `discover!'
/Users/home/Desktop/stellenverteiler/vendor/plugins/workling/init.rb:
2:in `evaluate_init_rb'
/usr/local/lib/ruby/gems/1.8/gems/rails-2.3.4/lib/rails/plugin.rb:
158:in `evaluate_init_rb'
/usr/local/lib/ruby/gems/1.8/gems/activesupport-2.3.4/lib/
active_support/core_ext/kernel/reporting.rb:11:in `silence_warnings'
/usr/local/lib/ruby/gems/1.8/gems/rails-2.3.4/lib/rails/plugin.rb:
154:in `evaluate_init_rb'
/usr/local/lib/ruby/gems/1.8/gems/rails-2.3.4/lib/rails/plugin.rb:
48:in `load'
/usr/local/lib/ruby/gems/1.8/gems/rails-2.3.4/lib/rails/plugin/
loader.rb:38:in `load_plugins'
/usr/local/lib/ruby/gems/1.8/gems/rails-2.3.4/lib/rails/plugin/
loader.rb:37:in `each'
/usr/local/lib/ruby/gems/1.8/gems/rails-2.3.4/lib/rails/plugin/
loader.rb:37:in `load_plugins'
/usr/local/lib/ruby/gems/1.8/gems/rails-2.3.4/lib/initializer.rb:
369:in `load_plugins'
/usr/local/lib/ruby/gems/1.8/gems/rails-2.3.4/lib/initializer.rb:
165:in `process'
/usr/local/lib/ruby/gems/1.8/gems/rails-2.3.4/lib/initializer.rb:
113:in `send'
/usr/local/lib/ruby/gems/1.8/gems/rails-2.3.4/lib/initializer.rb:
113:in `run'
/Users/home/Desktop/stellenverteiler/config/environment.rb:16
/usr/local/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:31:in
`gem_original_require'
/usr/local/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:31:in
`require'
/usr/local/lib/ruby/gems/1.8/gems/activesupport-2.3.4/lib/
active_support/dependencies.rb:156:in `require'
/usr/local/lib/ruby/gems/1.8/gems/activesupport-2.3.4/lib/
active_support/dependencies.rb:521:in `new_constants_in'
/usr/local/lib/ruby/gems/1.8/gems/activesupport-2.3.4/lib/
active_support/dependencies.rb:156:in `require'
/usr/local/lib/ruby/gems/1.8/gems/rails-2.3.4/lib/tasks/misc.rake:4
/usr/local/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:636:in `call'
/usr/local/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:636:in
`execute'
/usr/local/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:631:in `each'
/usr/local/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:631:in
`execute'
/usr/local/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:597:in
`invoke_with_call_chain'
/usr/local/lib/ruby/1.8/monitor.rb:242:in `synchronize'
/usr/local/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:590:in
`invoke_with_call_chain'
/usr/local/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:583:in
`invoke'
/usr/local/lib/ruby/gems/1.8/gems/rails-2.3.4/lib/tasks/gems.rake:17
/usr/local/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:636:in `call'
/usr/local/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:636:in
`execute'
/usr/local/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:631:in `each'
/usr/local/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:631:in
`execute'
/usr/local/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:597:in
`invoke_with_call_chain'
/usr/local/lib/ruby/1.8/monitor.rb:242:in `synchronize'
/usr/local/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:590:in
`invoke_with_call_chain'
/usr/local/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:607:in
`invoke_prerequisites'
/usr/local/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:604:in `each'
/usr/local/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:604:in
`invoke_prerequisites'
/usr/local/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:596:in
`invoke_with_call_chain'
/usr/local/lib/ruby/1.8/monitor.rb:242:in `synchronize'
/usr/local/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:590:in
`invoke_with_call_chain'
/usr/local/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:607:in
`invoke_prerequisites'
/usr/local/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:604:in `each'
/usr/local/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:604:in
`invoke_prerequisites'
/usr/local/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:596:in
`invoke_with_call_chain'
/usr/local/lib/ruby/1.8/monitor.rb:242:in `synchronize'
/usr/local/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:590:in
`invoke_with_call_chain'
/usr/local/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:583:in
`invoke'
/usr/local/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:2051:in
`invoke_task'
/usr/local/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:2029:in
`top_level'
/usr/local/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:2029:in
`each'
/usr/local/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:2029:in
`top_level'
/usr/local/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:2068:in
`standard_exception_handling'
/usr/local/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:2023:in
`top_level'
/usr/local/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:2001:in `run'
/usr/local/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:2068:in
`standard_exception_handling'
/usr/local/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:1998:in `run'
/usr/local/lib/ruby/gems/1.8/gems/rake-0.8.7/bin/rake:31
/usr/local/bin/rake:19:in `load'
/usr/local/bin/rake:19

Adam Grant

unread,
Oct 30, 2009, 11:10:16 AM10/30/09
to papercli...@googlegroups.com
Sounds like the gem isn't getting correctly loaded when the Rails framework starts, and when you model declares 'has_attached_file', it doesn't know the reference. If you try "script/console" does that produce the same error? I don't think it is specifically a "rake gems:unpack" issue. Just my guess....

- Adam

pimpmaster

unread,
Nov 6, 2009, 11:25:49 AM11/6/09
to Paperclip Plugin
script/console works just fine - this only happens whenever I run any
type of rake gems:* command
Reply all
Reply to author
Forward
0 new messages