rake aborted! undefined method `sorcery'
rake aborted! undefined method `sorcery' for #<Rails::Application::Configuration:0x93a9554>
really don't know what is wrong here. I installed https://github.com/NoamB/sorcery as per the instructions.
Then I decided it wasn't exactly what I wanted. Done a lot of faffing about but eventually just decided to revert to an earlier pre sorcery commit.
Trouble is now I get the above message every time I try to seed or migrate a db.
I have tried emptying the rvm gemset, uninstalling the sorcery gem, have looked in the seeds.rb and schema.rb as well as the Gemfile and I am definitely using the pre 'sorcery' version of my app.
I even tried dropping the db. rake db:create worked but back to the same error with rake db:seed.
It's my first time using rails so not entirely sure what's going on and 'undefined method' returns so many hits I can't find a clear debug path.
trace
/home/kzu/.rvm/gems/ruby-1.9.3-p392/gems/railties-3.2.13/lib/rails/railtie/configuration.rb:85:in method_missing' /home/kzu/Development/hub-blog/config/initializers/sorcery.rb:5:in
' /home/kzu/.rvm/gems/ruby-1.9.3-p392/gems/activesupport-3.2.13/lib/active_support/dependencies.rb:245:in load' /home/kzu/.rvm/gems/ruby-1.9.3-p392/gems/activesupport-3.2.13/lib/active_support/dependencies.rb:245:in
block in load' /home/kzu/.rvm/gems/ruby-1.9.3-p392/gems/activesupport-3.2.13/lib/active_support/dependencies.rb:236:in load_dependency' /home/kzu/.rvm/gems/ruby-1.9.3-p392/gems/activesupport-3.2.13/lib/active_support/dependencies.rb:245:in
load' /home/kzu/.rvm/gems/ruby-1.9.3-p392/gems/railties-3.2.13/lib/rails/engine.rb:588:in block (2 levels) in <class:Engine>' /home/kzu/.rvm/gems/ruby-1.9.3-p392/gems/railties-3.2.13/lib/rails/engine.rb:587:in
each' /home/kzu/.rvm/gems/ruby-1.9.3-p392/gems/railties-3.2.13/lib/rails/engine.rb:587:in block in <class:Engine>' /home/kzu/.rvm/gems/ruby-1.9.3-p392/gems/railties-3.2.13/lib/rails/initializable.rb:30:in
block in <class:Engine>' /home/kzu/.rvm/gems/ruby-1.9.3-p392/gems/railties-3.2.13/lib/rails/initializable.rb:30:in
instance_exec' /home/kzu/.rvm/gems/ruby-1.9.3-p392/gems/railties-3.2.13/lib/rails/initializable.rb:30:in run' /home/kzu/.rvm/gems/ruby-1.9.3-p392/gems/railties-3.2.13/lib/rails/initializable.rb:55:in
block in run_initializers' /home/kzu/.rvm/gems/ruby-1.9.3-p392/gems/railties-3.2.13/lib/rails/initializable.rb:54:in each' /home/kzu/.rvm/gems/ruby-1.9.3-p392/gems/railties-3.2.13/lib/rails/initializable.rb:54:in
run_initializers' /home/kzu/.rvm/gems/ruby-1.9.3-p392/gems/railties-3.2.13/lib/rails/application.rb:136:in initialize!' /home/kzu/.rvm/gems/ruby-1.9.3-p392/gems/railties-3.2.13/lib/rails/railtie/configurable.rb:30:in
initialize!' /home/kzu/.rvm/gems/ruby-1.9.3-p392/gems/railties-3.2.13/lib/rails/railtie/configurable.rb:30:in
method_missing' /home/kzu/Development/hub-blog/config/environment.rb:5:in <top (required)>' /home/kzu/.rvm/gems/ruby-1.9.3-p392/gems/railties-3.2.13/lib/rails/application.rb:103:in
require' /home/kzu/.rvm/gems/ruby-1.9.3-p392/gems/railties-3.2.13/lib/rails/application.rb:103:in require_environment!' /home/kzu/.rvm/gems/ruby-1.9.3-p392/gems/railties-3.2.13/lib/rails/application.rb:297:in
require_environment!' /home/kzu/.rvm/gems/ruby-1.9.3-p392/gems/railties-3.2.13/lib/rails/application.rb:297:in
block (2 levels) in initialize_tasks' /home/kzu/.rvm/gems/ruby-1.9.3-p392@global/gems/rake-10.0.4/lib/rake/task.rb:246:in call' /home/kzu/.rvm/gems/ruby-1.9.3-p392@global/gems/rake-10.0.4/lib/rake/task.rb:246:in
block in execute' /home/kzu/.rvm/gems/ruby-1.9.3-p392@global/gems/rake-10.0.4/lib/rake/task.rb:241:in each' /home/kzu/.rvm/gems/ruby-1.9.3-p392@global/gems/rake-10.0.4/lib/rake/task.rb:241:in
execute' /home/kzu/.rvm/gems/ruby-1.9.3-p392@global/gems/rake-10.0.4/lib/rake/task.rb:184:in block in invoke_with_call_chain' /home/kzu/.rvm/gems/ruby-1.9.3-p392@global/gems/rake-10.0.4/lib/rake/task.rb:177:in
invoke_with_call_chain' /home/kzu/.rvm/gems/ruby-1.9.3-p392@global/gems/rake-10.0.4/lib/rake/task.rb:205:in block in invoke_prerequisites' /home/kzu/.rvm/gems/ruby-1.9.3-p392@global/gems/rake-10.0.4/lib/rake/task.rb:203:in
each' /home/kzu/.rvm/gems/ruby-1.9.3-p392@global/gems/rake-10.0.4/lib/rake /task.rb:203:in invoke_prerequisites' /home/kzu/.rvm/gems/ruby-1.9.3-p392@global/gems/rake-10.0.4/lib/rake/task.rb:183:in
block in invoke_with_call_chain' /home/kzu/.rvm/gems/ruby-1.9.3-p392@global/gems/rake-10.0.4/lib/rake/task.rb:177:in invoke_with_call_chain' /home/kzu/.rvm/gems/ruby-1.9.3-p392@global/gems/rake-10.0.4/lib/rake/task.rb:170:in
invoke' /home/kzu/.rvm/gems/ruby-1.9.3-p392/gems/activerecord-3.2.13/lib/active_record/railties/databases.rake:346:in block (2 levels) in <top (required)>' /home/kzu/.rvm/gems/ruby-1.9.3-p392@global/gems/rake-10.0.4/lib/rake/task.rb:246:in
call' /home/kzu/.rvm/gems/ruby-1.9.3-p392@global/gems/rake-10.0.4/lib/rake/task.rb:246:in block in execute' /home/kzu/.rvm/gems/ruby-1.9.3-p392@global/gems/rake-10.0.4/lib/rake/task.rb:241:in
each' /home/kzu/.rvm/gems/ruby-1.9.3-p392@global/gems/rake-10.0.4/lib/rake/task.rb:241:in execute' /home/kzu/.rvm/gems/ruby-1.9.3-p392@global/gems/rake-10.0.4/lib/rake/task.rb:184:in
block in invoke_with_call_chain' /home /kzu/.rvm/gems/ruby-1.9.3-p392@global/gems/rake-10.0.4/lib/rake/task.rb:177:in invoke_with_call_chain' /home/kzu/.rvm/gems/ruby-1.9.3-p392@global/gems/rake-10.0.4/lib/rake/task.rb:170:in
invoke' /home/kzu/.rvm/gems/ruby-1.9.3-p392@global/gems/rake-10.0.4/lib/rake/application.rb:143:in invoke_task' /home/kzu/.rvm/gems/ruby-1.9.3-p392@global/gems/rake-10.0.4/lib/rake/application.rb:101:in
block (2 levels) in top_level' /home/kzu/.rvm/gems/ruby-1.9.3-p392@global/gems/rake-10.0.4/lib/rake/application.rb:101:in each' /home/kzu/.rvm/gems/ruby-1.9.3-p392@global/gems/rake-10.0.4/lib/rake/application.rb:101:in
block in top_level' /home/kzu/.rvm/gems/ruby-1.9.3-p392@global/gems/rake-10.0.4/lib/rake/application.rb:110:in run_with_threads' /home/kzu/.rvm/gems/ruby-1.9.3-p392@global/gems/rake-10.0.4/lib/rake/application.rb:95:in
top_level' /home/kzu/.rvm/gems/ruby-1.9.3-p392@global/gems/rake-10.0.4/lib/rake/application.rb:73:in block in run' /home/kzu/.rvm/gems/ruby-1.9.3-p392@global/gems/rake-10.0.4/lib/rake/application.rb:160:in
block in run' /home/kzu/.rvm/gems/ruby-1.9.3-p392@global/gems/rake-10.0.4/lib/rake/application.rb:160:in
standard_exception_handling' /home/kzu/.rvm/gems/ruby-1.9.3-p392@global/gems/rake-10.0.4/lib/rake/application.rb:70:in run' /home/kzu/.rvm/gems/ruby-1.9.3-p392/bin/ruby_noexec_wrapper:14:in
eval' /home/kzu/.rvm/gems/ruby-1.9.3-p392/bin/ruby_noexec_wrapper:14:in `' Tasks: TOP => db:abort_if_pending_migrations => environment
看起来你的应用程序文件夹中仍然有一个sorcery.rb文件,在config / initializer中,你可以检查一下吗?
链接地址: http://www.djcxy.com/p/57902.html上一篇: 我不能让铁轨生成控制器
下一篇: 耙子中止了! 未定义的方法`巫术'