I'hve used spree paypal express extension on spree(https://github.com/spree/spree_paypal_express), got following error for rake db:migrate.
Ruby 1.8.7 and rails 3.1.3
rake aborted!
superclass must be a Class (Module given)
/Users/kunalsupe/Developer/.rvm/gems/ruby-1.8.7-p302/gems/activesupport-3.1.1/lib/active_support/dependencies.rb:456:in `load_file'
/Users/kunalsupe/Developer/.rvm/gems/ruby-1.8.7-p302/gems/activesupport-3.1.1/lib/active_support/dependencies.rb:640:in `new_constants_in'
/Users/kunalsupe/Developer/.rvm/gems/ruby-1.8.7-p302/gems/activesupport-3.1.1/lib/active_support/dependencies.rb:455:in `load_file'
/Users/kunalsupe/Developer/.rvm/gems/ruby-1.8.7-p302/gems/activesupport-3.1.1/lib/active_support/dependencies.rb:342:in `require_or_load'
/Users/kunalsupe/Developer/.rvm/gems/ruby-1.8.7-p302/gems/activesupport-3.1.1/lib/active_support/dependencies.rb:489:in `load_missing_constant'
/Users/kunalsupe/Developer/.rvm/gems/ruby-1.8.7-p302/gems/activesupport-3.1.1/lib/active_support/dependencies.rb:181:in `const_missing'
/Users/kunalsupe/Developer/.rvm/gems/ruby-1.8.7-p302/gems/activesupport-3.1.1/lib/active_support/dependencies.rb:179:in `each'
/Users/kunalsupe/Developer/.rvm/gems/ruby-1.8.7-p302/gems/activesupport-3.1.1/lib/active_support/dependencies.rb:179:in `const_missing'
/Users/kunalsupe/Developer/.rvm/gems/ruby-1.8.7-p302/bundler/gems/spree_paypal_express-6e6b553313c5/lib/spree_paypal_express/engine.rb:20
/Users/kunalsupe/Developer/.rvm/gems/ruby-1.8.7-p302/gems/activesupport-3.1.1/lib/active_support/lazy_load_hooks.rb:34:in `call'
/Users/kunalsupe/Developer/.rvm/gems/ruby-1.8.7-p302/gems/activesupport-3.1.1/lib/active_support/lazy_load_hooks.rb:34:in `execute_hook'
/Users/kunalsupe/Developer/.rvm/gems/ruby-1.8.7-p302/gems/activesupport-3.1.1/lib/active_support/lazy_load_hooks.rb:43:in `run_load_hooks'
/Users/kunalsupe/Developer/.rvm/gems/ruby-1.8.7-p302/gems/activesupport-3.1.1/lib/active_support/lazy_load_hooks.rb:42:in `each'
/Users/kunalsupe/Developer/.rvm/gems/ruby-1.8.7-p302/gems/activesupport-3.1.1/lib/active_support/lazy_load_hooks.rb:42:in `run_load_hooks'
/Users/kunalsupe/Developer/.rvm/gems/ruby-1.8.7-p302/gems/railties-3.1.1/lib/rails/application/finisher.rb:56
/Users/kunalsupe/Developer/.rvm/gems/ruby-1.8.7-p302/gems/railties-3.1.1/lib/rails/initializable.rb:30:in `instance_exec'
/Users/kunalsupe/Developer/.rvm/gems/ruby-1.8.7-p302/gems/railties-3.1.1/lib/rails/initializable.rb:30:in `run'
/Users/kunalsupe/Developer/.rvm/gems/ruby-1.8.7-p302/gems/railties-3.1.1/lib/rails/initializable.rb:55:in `run_initializers'
/Users/kunalsupe/Developer/.rvm/gems/ruby-1.8.7-p302/gems/railties-3.1.1/lib/rails/initializable.rb:54:in `each'
/Users/kunalsupe/Developer/.rvm/gems/ruby-1.8.7-p302/gems/railties-3.1.1/lib/rails/initializable.rb:54:in `run_initializers'
/Users/kunalsupe/Developer/.rvm/gems/ruby-1.8.7-p302/gems/railties-3.1.1/lib/rails/application.rb:96:in `initialize!'
/Users/kunalsupe/Developer/.rvm/gems/ruby-1.8.7-p302/gems/railties-3.1.1/lib/rails/railtie/configurable.rb:30:in `send'
/Users/kunalsupe/Developer/.rvm/gems/ruby-1.8.7-p302/gems/railties-3.1.1/lib/rails/railtie/configurable.rb:30:in `method_missing'
Is there any solution to this
You're using the wrong version of this extension. Please check the extension's Version for the correct version to use with the version of Spree that you're using.
For example, with Spree 0.70.x you should be using this ref.
Your problem is caused by using a too-new version of the extension for the version of Spree that you're on.
Related
I'm using Ruby 1.9.3 and Rails 3.2.17 for this project. I plan to upgrade to Rails 4 but meet a lot gem incompatibilities, so I try to update some gem at first.
I am updating formtastic from 2.0.2 to 3.1.3.
I see a lot of deprecation warnings like this:
DEPRECATION WARNING: input_class is deprecated and will be removed from Formtastic 4.0 (configure Formtastic::FormBuilder.input_class_finder instead (upgrade guide on wiki: http://bit.ly/1F9QtKc )). (called from _app_views_prescriptions__fields_html_haml___278490936240938991_103076320 at /home/hegwin/Workspace/rails_projects/pharmmd/app/views/prescriptions/_fields.html.haml:7)
And I followed formtastic wiki Upgrading to Formtastic 3.1 , and I added these two lines to config/initializers/formtastic.rb
Formtastic::FormBuilder.action_class_finder = Formtastic::ActionClassFinder
Formtastic::FormBuilder.input_class_finder = Formtastic::InputClassFinder
After that when I tried to run the rspec, it threw an error:
NoMethodError: undefined method `eager_load' for #<Rails::Application::Configuration:0x00000006306a50>
/home/hegwin/.rvm/gems/ruby-1.9.3-p362#medpro/gems/railties-3.2.17/lib/rails/railtie/configuration.rb:85:in `method_missing': undefined method `eager_load' for #<Rails::Application::Configuration:0x00000006459b50> (NoMethodError)
from /home/hegwin/.rvm/gems/ruby-1.9.3-p362#medpro/gems/formtastic-3.1.3/lib/formtastic/namespaced_class_finder.rb:32:in `use_const_defined?'
from /home/hegwin/.rvm/gems/ruby-1.9.3-p362#medpro/gems/formtastic-3.1.3/lib/formtastic/namespaced_class_finder.rb:69:in `<class:NamespacedClassFinder>'
from /home/hegwin/.rvm/gems/ruby-1.9.3-p362#medpro/gems/formtastic-3.1.3/lib/formtastic/namespaced_class_finder.rb:24:in `<module:Formtastic>'
from /home/hegwin/.rvm/gems/ruby-1.9.3-p362#medpro/gems/formtastic-3.1.3/lib/formtastic/namespaced_class_finder.rb:1:in `<top (required)>'
from /home/hegwin/.rvm/gems/ruby-1.9.3-p362#medpro/gems/formtastic-3.1.3/lib/formtastic/action_class_finder.rb:7:in `<module:Formtastic>'
from /home/hegwin/.rvm/gems/ruby-1.9.3-p362#medpro/gems/formtastic-3.1.3/lib/formtastic/action_class_finder.rb:1:in `<top (required)>'
from /home/hegwin/Workspace/rails_projects/pharmmd/config/initializers/formtastic.rb:104:in `<top (required)>'
from /home/hegwin/.rvm/gems/ruby-1.9.3-p362#medpro/gems/zeus-0.13.3/lib/zeus/load_tracking.rb:50:in `load'
from /home/hegwin/.rvm/gems/ruby-1.9.3-p362#medpro/gems/zeus-0.13.3/lib/zeus/load_tracking.rb:50:in `load'
from /home/hegwin/.rvm/gems/ruby-1.9.3-p362#medpro/gems/zeus-0.13.3/lib/zeus/load_tracking.rb:43:in `load'
from /home/hegwin/.rvm/gems/ruby-1.9.3-p362#medpro/gems/activesupport-3.2.17/lib/active_support/dependencies.rb:245:in `block in load'
from /home/hegwin/.rvm/gems/ruby-1.9.3-p362#medpro/gems/activesupport-3.2.17/lib/active_support/dependencies.rb:236:in `load_dependency'
from /home/hegwin/.rvm/gems/ruby-1.9.3-p362#medpro/gems/activesupport-3.2.17/lib/active_support/dependencies.rb:245:in `load'
from /home/hegwin/.rvm/gems/ruby-1.9.3-p362#medpro/gems/railties-3.2.17/lib/rails/engine.rb:593:in `block (2 levels) in <class:Engine>'
from /home/hegwin/.rvm/gems/ruby-1.9.3-p362#medpro/gems/railties-3.2.17/lib/rails/engine.rb:592:in `each'
from /home/hegwin/.rvm/gems/ruby-1.9.3-p362#medpro/gems/railties-3.2.17/lib/rails/engine.rb:592:in `block in <class:Engine>'
from /home/hegwin/.rvm/gems/ruby-1.9.3-p362#medpro/gems/railties-3.2.17/lib/rails/initializable.rb:30:in `instance_exec'
from /home/hegwin/.rvm/gems/ruby-1.9.3-p362#medpro/gems/railties-3.2.17/lib/rails/initializable.rb:30:in `run'
from /home/hegwin/.rvm/gems/ruby-1.9.3-p362#medpro/gems/railties-3.2.17/lib/rails/initializable.rb:55:in `block in run_initializers'
from /home/hegwin/.rvm/gems/ruby-1.9.3-p362#medpro/gems/railties-3.2.17/lib/rails/initializable.rb:54:in `each'
from /home/hegwin/.rvm/gems/ruby-1.9.3-p362#medpro/gems/railties-3.2.17/lib/rails/initializable.rb:54:in `run_initializers'
from /home/hegwin/.rvm/gems/ruby-1.9.3-p362#medpro/gems/railties-3.2.17/lib/rails/application.rb:136:in `initialize!'
from /home/hegwin/.rvm/gems/ruby-1.9.3-p362#medpro/gems/railties-3.2.17/lib/rails/railtie/configurable.rb:30:in `method_missing'
from /home/hegwin/Workspace/rails_projects/pharmmd/config/environment.rb:5:in `<top (required)>'
from /home/hegwin/Workspace/rails_projects/pharmmd/spec/spec_helper.rb:12:in `require'
from /home/hegwin/Workspace/rails_projects/pharmmd/spec/spec_helper.rb:12:in `<top (required)>'
from /home/hegwin/Workspace/rails_projects/pharmmd/spec/features/patient_edit_medication.feature:1:in `require'
from /home/hegwin/Workspace/rails_projects/pharmmd/spec/features/patient_edit_medication.feature:1:in `<top (required)>'
from /home/hegwin/.rvm/gems/ruby-1.9.3-p362#medpro/gems/rspec-core-2.13.1/lib/rspec/core/configuration.rb:819:in `load'
from /home/hegwin/.rvm/gems/ruby-1.9.3-p362#medpro/gems/rspec-core-2.13.1/lib/rspec/core/configuration.rb:819:in `block in load_spec_files'
from /home/hegwin/.rvm/gems/ruby-1.9.3-p362#medpro/gems/rspec-core-2.13.1/lib/rspec/core/configuration.rb:819:in `each'
from /home/hegwin/.rvm/gems/ruby-1.9.3-p362#medpro/gems/rspec-core-2.13.1/lib/rspec/core/configuration.rb:819:in `load_spec_files'
from /home/hegwin/.rvm/gems/ruby-1.9.3-p362#medpro/gems/rspec-core-2.13.1/lib/rspec/core/command_line.rb:22:in `run'
from /home/hegwin/.rvm/gems/ruby-1.9.3-p362#medpro/gems/rspec-core-2.13.1/lib/rspec/core/runner.rb:80:in `run'
from /home/hegwin/.rvm/gems/ruby-1.9.3-p362#medpro/gems/rspec-core-2.13.1/lib/rspec/core/runner.rb:17:in `block in autorun'
The issue is known to the formtastic team. See issues #1137 and #1135 for details. In short, a stop-gap measure is to utilize the issue_1135 branch of the sepastian fork. Here's the Gemfile line:
gem 'formtastic', :git => 'git://github.com/sepastian/formtastic.git', :branch => 'issue_1135'
A better idea is to fork that branch to create your own repository.
just started learning Ruby on Rails, I'm trying to install the devise gem for creating a login/signin lesson, but I keep getting the following messages..
Could anyone help please? and feel free to correct me on how i'm asking the questions. New to this community and would love to be involved.
alexs-air:pinteresting alexkwon$ rails generate devise:install
/Users/alexkwon/.rvm/gems/ruby-2.1.2/gems/activerecord-4.1.1/lib/active_record/dynamic_matchers.rb:26:in `method_missing': undefined method `devise' for Install (call 'Install.connection' to establish a connection):Class (NoMethodError)
from /Users/alexkwon/Desktop/pinteresting/app/models/install.rb:4:in `<class:Install>'
from /Users/alexkwon/Desktop/pinteresting/app/models/install.rb:1:in `<top (required)>'
from /Users/alexkwon/.rvm/gems/ruby-2.1.2/gems/activesupport-4.1.1/lib/active_support/dependencies.rb:443:in `load'
from /Users/alexkwon/.rvm/gems/ruby-2.1.2/gems/activesupport-4.1.1/lib/active_support/dependencies.rb:443:in `block in load_file'
from /Users/alexkwon/.rvm/gems/ruby-2.1.2/gems/activesupport-4.1.1/lib/active_support/dependencies.rb:633:in `new_constants_in'
from /Users/alexkwon/.rvm/gems/ruby-2.1.2/gems/activesupport-4.1.1/lib/active_support/dependencies.rb:442:in `load_file'
from /Users/alexkwon/.rvm/gems/ruby-2.1.2/gems/activesupport-4.1.1/lib/active_support/dependencies.rb:342:in `require_or_load'
from /Users/alexkwon/.rvm/gems/ruby-2.1.2/gems/activesupport-4.1.1/lib/active_support/dependencies.rb:480:in `load_missing_constant'
from /Users/alexkwon/.rvm/gems/ruby-2.1.2/gems/activesupport-4.1.1/lib/active_support/dependencies.rb:180:in `const_missing'
from /Users/alexkwon/.rvm/gems/ruby-2.1.2/gems/activesupport-4.1.1/lib/active_support/inflector/methods.rb:238:in `const_get'
from /Users/alexkwon/.rvm/gems/ruby-2.1.2/gems/activesupport-4.1.1/lib/active_support/inflector/methods.rb:238:in `block in constantize'
from /Users/alexkwon/.rvm/gems/ruby-2.1.2/gems/activesupport-4.1.1/lib/active_support/inflector/methods.rb:236:in `each'
from /Users/alexkwon/.rvm/gems/ruby-2.1.2/gems/activesupport-4.1.1/lib/active_support/inflector/methods.rb:236:in `inject'
from /Users/alexkwon/.rvm/gems/ruby-2.1.2/gems/activesupport-4.1.1/lib/active_support/inflector/methods.rb:236:in `constantize'
from /Users/alexkwon/.rvm/gems/ruby-2.1.2/gems/activesupport-4.1.1/lib/active_support/dependencies.rb:552:in `get'
from /Users/alexkwon/.rvm/gems/ruby-2.1.2/gems/activesupport-4.1.1/lib/active_support/dependencies.rb:583:in `constantize'
from /Users/alexkwon/.rvm/gems/ruby-2.1.2/gems/devise-3.2.4/lib/devise.rb:297:in `get'
from /Users/alexkwon/.rvm/gems/ruby-2.1.2/gems/devise-3.2.4/lib/devise/mapping.rb:77:in `to'
from /Users/alexkwon/.rvm/gems/ruby-2.1.2/gems/devise-3.2.4/lib/devise/mapping.rb:72:in `modules'
from /Users/alexkwon/.rvm/gems/ruby-2.1.2/gems/devise-3.2.4/lib/devise/mapping.rb:89:in `routes'
from /Users/alexkwon/.rvm/gems/ruby-2.1.2/gems/devise-3.2.4/lib/devise/mapping.rb:156:in `default_used_route'
from /Users/alexkwon/.rvm/gems/ruby-2.1.2/gems/devise-3.2.4/lib/devise/mapping.rb:66:in `initialize'
from /Users/alexkwon/.rvm/gems/ruby-2.1.2/gems/devise-3.2.4/lib/devise.rb:331:in `new'
from /Users/alexkwon/.rvm/gems/ruby-2.1.2/gems/devise-3.2.4/lib/devise.rb:331:in `add_mapping'
from /Users/alexkwon/.rvm/gems/ruby-2.1.2/gems/devise-3.2.4/lib/devise/rails/routes.rb:221:in `block in devise_for'
from /Users/alexkwon/.rvm/gems/ruby-2.1.2/gems/devise-3.2.4/lib/devise/rails/routes.rb:220:in `each'
from /Users/alexkwon/.rvm/gems/ruby-2.1.2/gems/devise-3.2.4/lib/devise/rails/routes.rb:220:in `devise_for'
from /Users/alexkwon/Desktop/pinteresting/config/routes.rb:2:in `block in <top (required)>'
from /Users/alexkwon/.rvm/gems/ruby-2.1.2/gems/actionpack-4.1.1/lib/action_dispatch/routing/route_set.rb:335:in `instance_exec'
from /Users/alexkwon/.rvm/gems/ruby-2.1.2/gems/actionpack-4.1.1/lib/action_dispatch/routing/route_set.rb:335:in `eval_block'
from /Users/alexkwon/.rvm/gems/ruby-2.1.2/gems/actionpack-4.1.1/lib/action_dispatch/routing/route_set.rb:313:in `draw'
from /Users/alexkwon/Desktop/pinteresting/config/routes.rb:1:in `<top (required)>'
from /Users/alexkwon/.rvm/gems/ruby-2.1.2/gems/activesupport-4.1.1/lib/active_support/dependencies.rb:241:in `load'
from /Users/alexkwon/.rvm/gems/ruby-2.1.2/gems/activesupport-4.1.1/lib/active_support/dependencies.rb:241:in `block in load'
from /Users/alexkwon/.rvm/gems/ruby-2.1.2/gems/activesupport-4.1.1/lib/active_support/dependencies.rb:232:in `load_dependency'
from /Users/alexkwon/.rvm/gems/ruby-2.1.2/gems/activesupport-4.1.1/lib/active_support/dependencies.rb:241:in `load'
from /Users/alexkwon/.rvm/gems/ruby-2.1.2/gems/railties-4.1.1/lib/rails/application/routes_reloader.rb:40:in `block in load_paths'
from /Users/alexkwon/.rvm/gems/ruby-2.1.2/gems/railties-4.1.1/lib/rails/application/routes_reloader.rb:40:in `each'
from /Users/alexkwon/.rvm/gems/ruby-2.1.2/gems/railties-4.1.1/lib/rails/application/routes_reloader.rb:40:in `load_paths'
from /Users/alexkwon/.rvm/gems/ruby-2.1.2/gems/railties-4.1.1/lib/rails/application/routes_reloader.rb:16:in `reload!'
from /Users/alexkwon/.rvm/gems/ruby-2.1.2/gems/railties-4.1.1/lib/rails/application/routes_reloader.rb:26:in `block in updater'
from /Users/alexkwon/.rvm/gems/ruby-2.1.2/gems/activesupport-4.1.1/lib/active_support/file_update_checker.rb:75:in `call'
from /Users/alexkwon/.rvm/gems/ruby-2.1.2/gems/activesupport-4.1.1/lib/active_support/file_update_checker.rb:75:in `execute'
from /Users/alexkwon/.rvm/gems/ruby-2.1.2/gems/railties-4.1.1/lib/rails/application/routes_reloader.rb:27:in `updater'
from /Users/alexkwon/.rvm/gems/ruby-2.1.2/gems/railties-4.1.1/lib/rails/application/routes_reloader.rb:7:in `execute_if_updated'
from /Users/alexkwon/.rvm/gems/ruby-2.1.2/gems/railties-4.1.1/lib/rails/application/finisher.rb:71:in `block in <module:Finisher>'
from /Users/alexkwon/.rvm/gems/ruby-2.1.2/gems/railties-4.1.1/lib/rails/initializable.rb:30:in `instance_exec'
from /Users/alexkwon/.rvm/gems/ruby-2.1.2/gems/railties-4.1.1/lib/rails/initializable.rb:30:in `run'
from /Users/alexkwon/.rvm/gems/ruby-2.1.2/gems/railties-4.1.1/lib/rails/initializable.rb:55:in `block in run_initializers'
from /Users/alexkwon/.rvm/rubies/ruby-2.1.2/lib/ruby/2.1.0/tsort.rb:226:in `block in tsort_each'
from /Users/alexkwon/.rvm/rubies/ruby-2.1.2/lib/ruby/2.1.0/tsort.rb:348:in `block (2 levels) in each_strongly_connected_component'
from /Users/alexkwon/.rvm/rubies/ruby-2.1.2/lib/ruby/2.1.0/tsort.rb:427:in `each_strongly_connected_component_from'
from /Users/alexkwon/.rvm/rubies/ruby-2.1.2/lib/ruby/2.1.0/tsort.rb:347:in `block in each_strongly_connected_component'
from /Users/alexkwon/.rvm/rubies/ruby-2.1.2/lib/ruby/2.1.0/tsort.rb:345:in `each'
from /Users/alexkwon/.rvm/rubies/ruby-2.1.2/lib/ruby/2.1.0/tsort.rb:345:in `call'
from /Users/alexkwon/.rvm/rubies/ruby-2.1.2/lib/ruby/2.1.0/tsort.rb:345:in `each_strongly_connected_component'
from /Users/alexkwon/.rvm/rubies/ruby-2.1.2/lib/ruby/2.1.0/tsort.rb:224:in `tsort_each'
from /Users/alexkwon/.rvm/rubies/ruby-2.1.2/lib/ruby/2.1.0/tsort.rb:205:in `tsort_each'
from /Users/alexkwon/.rvm/gems/ruby-2.1.2/gems/railties-4.1.1/lib/rails/initializable.rb:54:in `run_initializers'
from /Users/alexkwon/.rvm/gems/ruby-2.1.2/gems/railties-4.1.1/lib/rails/application.rb:288:in `initialize!'
from /Users/alexkwon/Desktop/pinteresting/config/environment.rb:5:in `<top (required)>'
from /Users/alexkwon/.rvm/gems/ruby-2.1.2/gems/activesupport-4.1.1/lib/active_support/dependencies.rb:247:in `require'
from /Users/alexkwon/.rvm/gems/ruby-2.1.2/gems/activesupport-4.1.1/lib/active_support/dependencies.rb:247:in `block in require'
from /Users/alexkwon/.rvm/gems/ruby-2.1.2/gems/activesupport-4.1.1/lib/active_support/dependencies.rb:232:in `load_dependency'
from /Users/alexkwon/.rvm/gems/ruby-2.1.2/gems/activesupport-4.1.1/lib/active_support/dependencies.rb:247:in `require'
from /Users/alexkwon/.rvm/gems/ruby-2.1.2/gems/railties-4.1.1/lib/rails/application.rb:264:in `require_environment!'
from /Users/alexkwon/.rvm/gems/ruby-2.1.2/gems/railties-4.1.1/lib/rails/commands/commands_tasks.rb:147:in `require_application_and_environment!'
from /Users/alexkwon/.rvm/gems/ruby-2.1.2/gems/railties-4.1.1/lib/rails/commands/commands_tasks.rb:133:in `generate_or_destroy'
from /Users/alexkwon/.rvm/gems/ruby-2.1.2/gems/railties-4.1.1/lib/rails/commands/commands_tasks.rb:51:in `generate'
from /Users/alexkwon/.rvm/gems/ruby-2.1.2/gems/railties-4.1.1/lib/rails/commands/commands_tasks.rb:40:in `run_command!'
from /Users/alexkwon/.rvm/gems/ruby-2.1.2/gems/railties-4.1.1/lib/rails/commands.rb:17:in `<top (required)>'
from bin/rails:8:in `require'
from bin/rails:8:in `<main>'
Welcome to Rails man.
I know the community is all up on the devise gem. The reality is that Devise is an advanced authentication app that's a gem.
If you're learning, and you need authentication, some super geek named Ryan Bates hooked you up with a tutorial and screencast on basic authentication that will work exactly how you need it, and you will understand what's going on:
http://railscasts.com/episodes/250-authentication-from-scratch
WHABAM!
Be mindful that is based on rails 3. Check the differences between rails, and ruby versions if you encounter problems while following directions. If you do get errors, still, this path will get your further to deploying that app of yours.
Come back to Devise when you need the features it provides, Rails, and confident you can implement ideas found in the book 'Crafting Rails Application' by José Valim. He's one of the main contributors of Devise, so you'll get insight on his thought process.
I've recently upgraded my rails 3.2 project to 4.0. I've been successful in upgrading my app for the most part by following the guides. I have a few issues that I'm not sure what direction I should go and I'm looking for some help.
I was using quite a few attr_accessible on my models that I've now removed based in the advice in the guides. The guides say :
Rails 4.0 has removed attr_accessible and attr_protected feature in
favor of Strong Parameters. You can use the Protected Attributes gem
for a smooth upgrade path.
This gem got my application running but anytime I try to create a new object such as a user, message, etc. I get an error. From some research this seems common when using the new gem. It was suggested to remove the gem which would solve the new object issues. I did that but now I'm getting multiple errors from some of the other gems in my applications (And yes I've upgraded all gems to the most recent versions). Here is the error I'm getting:
/usr/local/rvm/gems/ruby-2.0.0-p247/gems/activemodel-4.0.0/lib/active_model/deprecated_mass_assignment_security.rb:14:in `attr_accessible': `attr_accessible` is extracted out of Rails into a gem. Please use new recommended protection model for params(strong_parameters) or add `protected_attributes` to your Gemfile to use old one. (RuntimeError)
from /usr/local/rvm/gems/ruby-2.0.0-p247/gems/acts-as-messageable-0.4.8/lib/acts-as-messageable/message.rb:8:in `<class:Message>'
from /usr/local/rvm/gems/ruby-2.0.0-p247/gems/acts-as-messageable-0.4.8/lib/acts-as-messageable/message.rb:4:in `<module:ActsAsMessageable>'
from /usr/local/rvm/gems/ruby-2.0.0-p247/gems/acts-as-messageable-0.4.8/lib/acts-as-messageable/message.rb:3:in `<top (required)>'
from /usr/local/rvm/gems/ruby-2.0.0-p247/gems/activesupport-4.0.0/lib/active_support/inflector/methods.rb:228:in `const_get'
from /usr/local/rvm/gems/ruby-2.0.0-p247/gems/activesupport-4.0.0/lib/active_support/inflector/methods.rb:228:in `block in constantize'
from /usr/local/rvm/gems/ruby-2.0.0-p247/gems/activesupport-4.0.0/lib/active_support/inflector/methods.rb:224:in `each'
from /usr/local/rvm/gems/ruby-2.0.0-p247/gems/activesupport-4.0.0/lib/active_support/inflector/methods.rb:224:in `inject'
from /usr/local/rvm/gems/ruby-2.0.0-p247/gems/activesupport-4.0.0/lib/active_support/inflector/methods.rb:224:in `constantize'
from /usr/local/rvm/gems/ruby-2.0.0-p247/gems/activesupport-4.0.0/lib/active_support/core_ext/string/inflections.rb:66:in `constantize'
from /usr/local/rvm/gems/ruby-2.0.0-p247/gems/acts-as-messageable-0.4.8/lib/acts-as-messageable/model.rb:34:in `acts_as_messageable'
from /Users/dave/rails_projects/EquiptMe/app/models/user.rb:14:in `<class:User>'
from /Users/dave/rails_projects/EquiptMe/app/models/user.rb:1:in `<top (required)>'
from /usr/local/rvm/gems/ruby-2.0.0-p247/gems/activesupport-4.0.0/lib/active_support/dependencies.rb:423:in `load'
from /usr/local/rvm/gems/ruby-2.0.0-p247/gems/activesupport-4.0.0/lib/active_support/dependencies.rb:423:in `block in load_file'
from /usr/local/rvm/gems/ruby-2.0.0-p247/gems/activesupport-4.0.0/lib/active_support/dependencies.rb:615:in `new_constants_in'
from /usr/local/rvm/gems/ruby-2.0.0-p247/gems/activesupport-4.0.0/lib/active_support/dependencies.rb:422:in `load_file'
from /usr/local/rvm/gems/ruby-2.0.0-p247/gems/activesupport-4.0.0/lib/active_support/dependencies.rb:323:in `require_or_load'
from /usr/local/rvm/gems/ruby-2.0.0-p247/gems/activesupport-4.0.0/lib/active_support/dependencies.rb:462:in `load_missing_constant'
from /usr/local/rvm/gems/ruby-2.0.0-p247/gems/activesupport-4.0.0/lib/active_support/dependencies.rb:183:in `const_missing'
from /usr/local/rvm/gems/ruby-2.0.0-p247/gems/activesupport-4.0.0/lib/active_support/inflector/methods.rb:226:in `const_get'
from /usr/local/rvm/gems/ruby-2.0.0-p247/gems/activesupport-4.0.0/lib/active_support/inflector/methods.rb:226:in `block in constantize'
from /usr/local/rvm/gems/ruby-2.0.0-p247/gems/activesupport-4.0.0/lib/active_support/inflector/methods.rb:224:in `each'
from /usr/local/rvm/gems/ruby-2.0.0-p247/gems/activesupport-4.0.0/lib/active_support/inflector/methods.rb:224:in `inject'
from /usr/local/rvm/gems/ruby-2.0.0-p247/gems/activesupport-4.0.0/lib/active_support/inflector/methods.rb:224:in `constantize'
from /usr/local/rvm/gems/ruby-2.0.0-p247/gems/activesupport-4.0.0/lib/active_support/dependencies.rb:534:in `get'
from /usr/local/rvm/gems/ruby-2.0.0-p247/gems/activesupport-4.0.0/lib/active_support/dependencies.rb:565:in `constantize'
from /usr/local/rvm/gems/ruby-2.0.0-p247/gems/devise-3.0.1/lib/devise.rb:278:in `get'
from /usr/local/rvm/gems/ruby-2.0.0-p247/gems/devise-3.0.1/lib/devise/mapping.rb:77:in `to'
from /usr/local/rvm/gems/ruby-2.0.0-p247/gems/devise-3.0.1/lib/devise/mapping.rb:72:in `modules'
from /usr/local/rvm/gems/ruby-2.0.0-p247/gems/devise-3.0.1/lib/devise/mapping.rb:89:in `routes'
from /usr/local/rvm/gems/ruby-2.0.0-p247/gems/devise-3.0.1/lib/devise/mapping.rb:156:in `default_used_route'
from /usr/local/rvm/gems/ruby-2.0.0-p247/gems/devise-3.0.1/lib/devise/mapping.rb:66:in `initialize'
from /usr/local/rvm/gems/ruby-2.0.0-p247/gems/devise-3.0.1/lib/devise.rb:312:in `new'
from /usr/local/rvm/gems/ruby-2.0.0-p247/gems/devise-3.0.1/lib/devise.rb:312:in `add_mapping'
from /usr/local/rvm/gems/ruby-2.0.0-p247/gems/devise-3.0.1/lib/devise/rails/routes.rb:208:in `block in devise_for'
from /usr/local/rvm/gems/ruby-2.0.0-p247/gems/devise-3.0.1/lib/devise/rails/routes.rb:207:in `each'
from /usr/local/rvm/gems/ruby-2.0.0-p247/gems/devise-3.0.1/lib/devise/rails/routes.rb:207:in `devise_for'
from /Users/dave/rails_projects/EquiptMe/config/routes.rb:7:in `block in <top (required)>'
from /usr/local/rvm/gems/ruby-2.0.0-p247/gems/actionpack-4.0.0/lib/action_dispatch/routing/route_set.rb:316:in `instance_exec'
from /usr/local/rvm/gems/ruby-2.0.0-p247/gems/actionpack-4.0.0/lib/action_dispatch/routing/route_set.rb:316:in `eval_block'
from /usr/local/rvm/gems/ruby-2.0.0-p247/gems/actionpack-4.0.0/lib/action_dispatch/routing/route_set.rb:294:in `draw'
from /Users/dave/rails_projects/EquiptMe/config/routes.rb:1:in `<top (required)>'
from /usr/local/rvm/gems/ruby-2.0.0-p247/gems/activesupport-4.0.0/lib/active_support/dependencies.rb:222:in `load'
from /usr/local/rvm/gems/ruby-2.0.0-p247/gems/activesupport-4.0.0/lib/active_support/dependencies.rb:222:in `block in load'
from /usr/local/rvm/gems/ruby-2.0.0-p247/gems/activesupport-4.0.0/lib/active_support/dependencies.rb:213:in `load_dependency'
from /usr/local/rvm/gems/ruby-2.0.0-p247/gems/activesupport-4.0.0/lib/active_support/dependencies.rb:222:in `load'
from /usr/local/rvm/gems/ruby-2.0.0-p247/gems/railties-4.0.0/lib/rails/application/routes_reloader.rb:40:in `block in load_paths'
from /usr/local/rvm/gems/ruby-2.0.0-p247/gems/railties-4.0.0/lib/rails/application/routes_reloader.rb:40:in `each'
from /usr/local/rvm/gems/ruby-2.0.0-p247/gems/railties-4.0.0/lib/rails/application/routes_reloader.rb:40:in `load_paths'
from /usr/local/rvm/gems/ruby-2.0.0-p247/gems/railties-4.0.0/lib/rails/application/routes_reloader.rb:16:in `reload!'
from /usr/local/rvm/gems/ruby-2.0.0-p247/gems/railties-4.0.0/lib/rails/application/routes_reloader.rb:26:in `block in updater'
from /usr/local/rvm/gems/ruby-2.0.0-p247/gems/activesupport-4.0.0/lib/active_support/file_update_checker.rb:75:in `call'
from /usr/local/rvm/gems/ruby-2.0.0-p247/gems/activesupport-4.0.0/lib/active_support/file_update_checker.rb:75:in `execute'
from /usr/local/rvm/gems/ruby-2.0.0-p247/gems/railties-4.0.0/lib/rails/application/routes_reloader.rb:27:in `updater'
from /usr/local/rvm/gems/ruby-2.0.0-p247/gems/railties-4.0.0/lib/rails/application/routes_reloader.rb:6:in `execute_if_updated'
from /usr/local/rvm/gems/ruby-2.0.0-p247/gems/railties-4.0.0/lib/rails/application/finisher.rb:69:in `block in <module:Finisher>'
from /usr/local/rvm/gems/ruby-2.0.0-p247/gems/railties-4.0.0/lib/rails/initializable.rb:30:in `instance_exec'
from /usr/local/rvm/gems/ruby-2.0.0-p247/gems/railties-4.0.0/lib/rails/initializable.rb:30:in `run'
from /usr/local/rvm/gems/ruby-2.0.0-p247/gems/railties-4.0.0/lib/rails/initializable.rb:55:in `block in run_initializers'
from /usr/local/rvm/rubies/ruby-2.0.0-p247/lib/ruby/2.0.0/tsort.rb:150:in `block in tsort_each'
from /usr/local/rvm/rubies/ruby-2.0.0-p247/lib/ruby/2.0.0/tsort.rb:183:in `block (2 levels) in each_strongly_connected_component'
from /usr/local/rvm/rubies/ruby-2.0.0-p247/lib/ruby/2.0.0/tsort.rb:219:in `each_strongly_connected_component_from'
from /usr/local/rvm/rubies/ruby-2.0.0-p247/lib/ruby/2.0.0/tsort.rb:182:in `block in each_strongly_connected_component'
from /usr/local/rvm/rubies/ruby-2.0.0-p247/lib/ruby/2.0.0/tsort.rb:180:in `each'
from /usr/local/rvm/rubies/ruby-2.0.0-p247/lib/ruby/2.0.0/tsort.rb:180:in `each_strongly_connected_component'
from /usr/local/rvm/rubies/ruby-2.0.0-p247/lib/ruby/2.0.0/tsort.rb:148:in `tsort_each'
from /usr/local/rvm/gems/ruby-2.0.0-p247/gems/railties-4.0.0/lib/rails/initializable.rb:54:in `run_initializers'
from /usr/local/rvm/gems/ruby-2.0.0-p247/gems/railties-4.0.0/lib/rails/application.rb:215:in `initialize!'
from /usr/local/rvm/gems/ruby-2.0.0-p247/gems/railties-4.0.0/lib/rails/railtie/configurable.rb:30:in `method_missing'
from /Users/dave/rails_projects/EquiptMe/config/environment.rb:5:in `<top (required)>'
from /usr/local/rvm/gems/ruby-2.0.0-p247/gems/activesupport-4.0.0/lib/active_support/dependencies.rb:228:in `require'
from /usr/local/rvm/gems/ruby-2.0.0-p247/gems/activesupport-4.0.0/lib/active_support/dependencies.rb:228:in `block in require'
from /usr/local/rvm/gems/ruby-2.0.0-p247/gems/activesupport-4.0.0/lib/active_support/dependencies.rb:213:in `load_dependency'
from /usr/local/rvm/gems/ruby-2.0.0-p247/gems/activesupport-4.0.0/lib/active_support/dependencies.rb:228:in `require'
from /Users/dave/rails_projects/EquiptMe/config.ru:3:in `block in <main>'
from /usr/local/rvm/gems/ruby-2.0.0-p247/gems/rack-1.5.2/lib/rack/builder.rb:55:in `instance_eval'
from /usr/local/rvm/gems/ruby-2.0.0-p247/gems/rack-1.5.2/lib/rack/builder.rb:55:in `initialize'
from /Users/dave/rails_projects/EquiptMe/config.ru:in `new'
from /Users/dave/rails_projects/EquiptMe/config.ru:in `<main>'
from /usr/local/rvm/gems/ruby-2.0.0-p247/gems/rack-1.5.2/lib/rack/builder.rb:49:in `eval'
from /usr/local/rvm/gems/ruby-2.0.0-p247/gems/rack-1.5.2/lib/rack/builder.rb:49:in `new_from_string'
from /usr/local/rvm/gems/ruby-2.0.0-p247/gems/rack-1.5.2/lib/rack/builder.rb:40:in `parse_file'
from /usr/local/rvm/gems/ruby-2.0.0-p247/gems/rack-1.5.2/lib/rack/server.rb:277:in `build_app_and_options_from_config'
from /usr/local/rvm/gems/ruby-2.0.0-p247/gems/rack-1.5.2/lib/rack/server.rb:199:in `app'
from /usr/local/rvm/gems/ruby-2.0.0-p247/gems/railties-4.0.0/lib/rails/commands/server.rb:48:in `app'
from /usr/local/rvm/gems/ruby-2.0.0-p247/gems/rack-1.5.2/lib/rack/server.rb:314:in `wrapped_app'
from /usr/local/rvm/gems/ruby-2.0.0-p247/gems/railties-4.0.0/lib/rails/commands/server.rb:75:in `start'
from /usr/local/rvm/gems/ruby-2.0.0-p247/gems/railties-4.0.0/lib/rails/commands.rb:78:in `block in <top (required)>'
from /usr/local/rvm/gems/ruby-2.0.0-p247/gems/railties-4.0.0/lib/rails/commands.rb:73:in `tap'
from /usr/local/rvm/gems/ruby-2.0.0-p247/gems/railties-4.0.0/lib/rails/commands.rb:73:in `<top (required)>'
from script/rails:6:in `require'
from script/rails:6:in `<main>'
Could someone point me in the right direction?
Thanks
I would try using the master branch of the "acts-as-messageable" gem in your Gemfile. It looks like there have been some updates related to Rails 4 since it was last released. If that fixes it, I'd ping the author to see if they'd release a new version.
There is a new gem created recently to help with upgrading from Rails 3 to Rails 4. I've used it recently and it made the upgrading process so much easier.
The gem is called wize_upgrader.
One thing that this gem does with attr_accessible in rails 3 models is that is converts it into strong params for you in your controller.
i.e: (in posts_controller)
def post_params
params.require(:post).permit(:title, :content, :tag)
end
I am getting this error when starting JBoss with my application built with warbler:
Error: unable to initialize application
org.jruby.rack.RackInitializationException: wrong number of arguments (1 for 0)
Callstack:
gems/gems/actionpack-3.0.9/lib/action_controller/railtie.rb:54:in `Railtie'
gems/gems/activesupport-3.0.9/lib/active_support/ordered_hash.rb:139:in `each'
org/jruby/RubyArray.java:1612:in `each'
gems/gems/activesupport-3.0.9/lib/active_support/ordered_hash.rb:139:in `each'
gems/gems/actionpack-3.0.9/lib/action_controller/railtie.rb:54:in `Railtie'
org/jruby/RubyKernel.java:2062:in `instance_eval'
gems/gems/activesupport-3.0.9/lib/active_support/lazy_load_hooks.rb:36:in `execute_hook'
gems/gems/activesupport-3.0.9/lib/active_support/lazy_load_hooks.rb:43:in `run_load_hooks'
org/jruby/RubyArray.java:1612:in `each'
gems/gems/activesupport-3.0.9/lib/active_support/lazy_load_hooks.rb:42:in `run_load_hooks'
gems/gems/actionpack-3.0.9/lib/action_controller/base.rb:232:in `Base'
gems/gems/actionpack-3.0.9/lib/action_controller/base.rb:169:in `ActionController'
gems/gems/actionpack-3.0.9/lib/action_controller/base.rb:3:in `(root)'
gems/gems/actionpack-3.0.9/lib/action_controller/base.rb:48:in `Railtie'
org/jruby/RubyKernel.java:2079:in `instance_exec'
gems/gems/railties-3.0.9/lib/rails/initializable.rb:25:in `run'
gems/gems/railties-3.0.9/lib/rails/initializable.rb:50:in `run_initializers'
org/jruby/RubyArray.java:1612:in `each'
gems/gems/railties-3.0.9/lib/rails/initializable.rb:49:in `run_initializers'
gems/gems/railties-3.0.9/lib/rails/application.rb:134:in `initialize!'
org/jruby/RubyKernel.java:2093:in `send'
gems/gems/railties-3.0.9/lib/rails/application.rb:77:in `method_missing'
config/environment.rb:5:in `(root)'
org/jruby/RubyKernel.java:1038:in `require'
config/environment.rb:167:in `load_environment'
classpath:/./jruby/rack/rails.rb:172:in `to_app'
classpath:/./jruby/rack/rails.rb:192:in `new'
<web.xml>:1:in `(root)'
org/jruby/RubyKernel.java:2062:in `instance_eval'
classpath:/./vendor/rack-1.3.5/rack/builder.rb:51:in `initialize'
<web.xml>:1:in `(root)'
Any ideas?
We had the same problems with Rails 3.0.11 / JBoss 5 and the latest jruby-rack.
To sort this out we had to use jruby-rack 1.0.10
Please try to put this line into your Gemfile:
gem 'jruby-rack', '1.0.10'
I got this same error when upgrading an app to Rails 3. The problem was related to invoking ActionController::Base.relative_url_root=, which is supposed to emit a deprecation warning, but it was busted in Rails 3.0.10.
My solution was to upgrade to jruby-rack 1.1.4 and rack 1.2.5.
I updated to Rails 3.0.8.rc2 recently, and then updated the paperclip gem to 2.3.11 (this fails on 2.3.10 as well). On startup, the paperclip gem seems to be not registering:
/Users/jade/code/plantworking/app/models/comment.rb:17: undefined method `has_attached_file' for Comment:Class (NoMethodError)
from /Users/jade/.rvm/gems/ree-1.8.7-2010.02#plantworking/gems/activesupport-3.0.8.rc2/lib/active_support/dependencies.rb:454:in `load'
from /Users/jade/.rvm/gems/ree-1.8.7-2010.02#plantworking/gems/activesupport-3.0.8.rc2/lib/active_support/dependencies.rb:454:in `load_file'
from /Users/jade/.rvm/gems/ree-1.8.7-2010.02#plantworking/gems/activesupport-3.0.8.rc2/lib/active_support/dependencies.rb:596:in `new_constants_in'
from /Users/jade/.rvm/gems/ree-1.8.7-2010.02#plantworking/gems/activesupport-3.0.8.rc2/lib/active_support/dependencies.rb:453:in `load_file'
from /Users/jade/.rvm/gems/ree-1.8.7-2010.02#plantworking/gems/activesupport-3.0.8.rc2/lib/active_support/dependencies.rb:340:in `require_or_load'
from /Users/jade/.rvm/gems/ree-1.8.7-2010.02#plantworking/gems/activesupport-3.0.8.rc2/lib/active_support/dependencies.rb:300:in `depend_on'
from /Users/jade/.rvm/gems/ree-1.8.7-2010.02#plantworking/gems/activesupport-3.0.8.rc2/lib/active_support/dependencies.rb:216:in `require_dependency'
from /Users/jade/.rvm/gems/ree-1.8.7-2010.02#plantworking/gems/mongoid-2.0.2/lib/rails/mongoid.rb:55:in `load_model'
from /Users/jade/.rvm/gems/ree-1.8.7-2010.02#plantworking/gems/mongoid-2.0.2/lib/rails/mongoid.rb:18:in `load_models'
from /Users/jade/.rvm/gems/ree-1.8.7-2010.02#plantworking/gems/mongoid-2.0.2/lib/rails/mongoid.rb:17:in `each'
from /Users/jade/.rvm/gems/ree-1.8.7-2010.02#plantworking/gems/mongoid-2.0.2/lib/rails/mongoid.rb:17:in `load_models'
from /Users/jade/.rvm/gems/ree-1.8.7-2010.02#plantworking/gems/railties-3.0.8.rc2/lib/rails/paths.rb:102:in `each'
from /Users/jade/.rvm/gems/ree-1.8.7-2010.02#plantworking/gems/railties-3.0.8.rc2/lib/rails/paths.rb:102:in `each'
from /Users/jade/.rvm/gems/ree-1.8.7-2010.02#plantworking/gems/mongoid-2.0.2/lib/rails/mongoid.rb:16:in `load_models'
from /Users/jade/.rvm/gems/ree-1.8.7-2010.02#plantworking/gems/mongoid-2.0.2/lib/mongoid/railtie.rb:86:in `_callback_before_5'
from /Users/jade/.rvm/gems/ree-1.8.7-2010.02#plantworking/gems/activesupport-3.0.8.rc2/lib/active_support/callbacks.rb:420:in `_run_prepare_callbacks'
from /Users/jade/.rvm/gems/ree-1.8.7-2010.02#plantworking/gems/actionpack-3.0.8.rc2/lib/action_dispatch/middleware/callbacks.rb:40:in `initialize'
from /Users/jade/.rvm/gems/ree-1.8.7-2010.02#plantworking/gems/actionpack-3.0.8.rc2/lib/action_dispatch/middleware/stack.rb:33:in `new'
from /Users/jade/.rvm/gems/ree-1.8.7-2010.02#plantworking/gems/actionpack-3.0.8.rc2/lib/action_dispatch/middleware/stack.rb:33:in `build'
from /Users/jade/.rvm/gems/ree-1.8.7-2010.02#plantworking/gems/actionpack-3.0.8.rc2/lib/action_dispatch/middleware/stack.rb:79:in `build'
from /Users/jade/.rvm/gems/ree-1.8.7-2010.02#plantworking/gems/railties-3.0.8.rc2/lib/rails/application.rb:209:in `inject'
from /Users/jade/.rvm/gems/ree-1.8.7-2010.02#plantworking/gems/actionpack-3.0.8.rc2/lib/action_dispatch/middleware/stack.rb:79:in `each'
from /Users/jade/.rvm/gems/ree-1.8.7-2010.02#plantworking/gems/actionpack-3.0.8.rc2/lib/action_dispatch/middleware/stack.rb:79:in `inject'
from /Users/jade/.rvm/gems/ree-1.8.7-2010.02#plantworking/gems/actionpack-3.0.8.rc2/lib/action_dispatch/middleware/stack.rb:79:in `build'
from /Users/jade/.rvm/gems/ree-1.8.7-2010.02#plantworking/gems/railties-3.0.8.rc2/lib/rails/application.rb:162:in `build_middleware_stack'
from /Users/jade/.rvm/gems/ree-1.8.7-2010.02#plantworking/gems/railties-3.0.8.rc2/lib/rails/application/finisher.rb:35
from /Users/jade/.rvm/gems/ree-1.8.7-2010.02#plantworking/gems/railties-3.0.8.rc2/lib/rails/initializable.rb:25:in `instance_exec'
from /Users/jade/.rvm/gems/ree-1.8.7-2010.02#plantworking/gems/railties-3.0.8.rc2/lib/rails/initializable.rb:25:in `run'
from /Users/jade/.rvm/gems/ree-1.8.7-2010.02#plantworking/gems/railties-3.0.8.rc2/lib/rails/initializable.rb:50:in `run_initializers'
from /Users/jade/.rvm/gems/ree-1.8.7-2010.02#plantworking/gems/railties-3.0.8.rc2/lib/rails/initializable.rb:49:in `each'
from /Users/jade/.rvm/gems/ree-1.8.7-2010.02#plantworking/gems/railties-3.0.8.rc2/lib/rails/initializable.rb:49:in `run_initializers'
from /Users/jade/.rvm/gems/ree-1.8.7-2010.02#plantworking/gems/railties-3.0.8.rc2/lib/rails/application.rb:134:in `initialize!'
from /Users/jade/.rvm/gems/ree-1.8.7-2010.02#plantworking/gems/railties-3.0.8.rc2/lib/rails/application.rb:77:in `send'
from /Users/jade/.rvm/gems/ree-1.8.7-2010.02#plantworking/gems/railties-3.0.8.rc2/lib/rails/application.rb:77:in `method_missing'
from /Users/jade/code/plantworking/config/environment.rb:11
from /Users/jade/.rvm/gems/ree-1.8.7-2010.02#plantworking/gems/polyglot-0.3.1/lib/polyglot.rb:64:in `polyglot_original_require'
from /Users/jade/.rvm/gems/ree-1.8.7-2010.02#plantworking/gems/polyglot-0.3.1/lib/polyglot.rb:64:in `require'
from /Users/jade/.rvm/gems/ree-1.8.7-2010.02#plantworking/gems/activesupport-3.0.8.rc2/lib/active_support/dependencies.rb:239:in `require'
from /Users/jade/.rvm/gems/ree-1.8.7-2010.02#plantworking/gems/activesupport-3.0.8.rc2/lib/active_support/dependencies.rb:225:in `load_dependency'
from /Users/jade/.rvm/gems/ree-1.8.7-2010.02#plantworking/gems/activesupport-3.0.8.rc2/lib/active_support/dependencies.rb:596:in `new_constants_in'
from /Users/jade/.rvm/gems/ree-1.8.7-2010.02#plantworking/gems/activesupport-3.0.8.rc2/lib/active_support/dependencies.rb:225:in `load_dependency'
from /Users/jade/.rvm/gems/ree-1.8.7-2010.02#plantworking/gems/activesupport-3.0.8.rc2/lib/active_support/dependencies.rb:239:in `require'
from /Users/jade/code/plantworking/config.ru:3
from /Users/jade/.rvm/gems/ree-1.8.7-2010.02#plantworking/gems/rack-1.2.3/lib/rack/builder.rb:46:in `instance_eval'
from /Users/jade/.rvm/gems/ree-1.8.7-2010.02#plantworking/gems/rack-1.2.3/lib/rack/builder.rb:46:in `initialize'
from /Users/jade/code/plantworking/config.ru:1:in `new'
from /Users/jade/code/plantworking/config.ru:1
I am using Mongoid 2.0.2.
Anyone get paperclip working with Rails 3.0.8+ ?
PaperClip by default only works on ActiveRecord. You might want to try the mongoid version of PaperClip or switch over to Carrierwave.