1
我試圖在我的終端執行rake db:migrate
命令,但它給出了錯誤。幾分鐘前它正在工作。這裏的錯誤,我得到:rake db:遷移失敗(活動記錄)
rake aborted!
no such file to load -- activerecord
錯誤的完整的跟蹤:
/Users/amritayalur/.rvm/gems/ruby-1.9.2-p318/gems/activesupport-3.2.6/lib/active_support/dependencies.rb:251:inrequire'
/Users/amritayalur/.rvm/gems/ruby-1.9.2-p318/gems/activesupport-3.2.6/lib/active_support/dependencies.rb:251:in block in require'
/Users/amritayalur/.rvm/gems/ruby-1.9.2-p318/gems/activesupport-3.2.6/lib/active_support/dependencies.rb:236:inload_dependency'
/Users/amritayalur/.rvm/gems/ruby-1.9.2-p318/gems/activesupport-3.2.6/lib/active_support/dependencies.rb:251:in require'
/Users/amritayalur/.rvm/gems/ruby-1.9.2-p318/gems/has_one_autocreate-1.0.0/lib/has_one_autocreate.rb:2:in'
/Users/amritayalur/.rvm/gems/[email protected]/gems/bundler-1.1.4/lib/bundler/runtime.rb:68:in require'
/Users/amritayalur/.rvm/gems/[email protected]/gems/bundler-1.1.4/lib/bundler/runtime.rb:68:inblock (2 levels) in require'
/Users/amritayalur/.rvm/gems/[email protected]/gems/bundler-1.1.4/lib/bundler/runtime.rb:66:in each'
/Users/amritayalur/.rvm/gems/[email protected]/gems/bundler-1.1.4/lib/bundler/runtime.rb:66:inblock in require'
/Users/amritayalur/.rvm/gems/[email protected]/gems/bundler-1.1.4/lib/bundler/runtime.rb:55:in each'
/Users/amritayalur/.rvm/gems/[email protected]/gems/bundler-1.1.4/lib/bundler/runtime.rb:55:inrequire'
/Users/amritayalur/.rvm/gems/[email protected]/gems/bundler-1.1.4/lib/bundler.rb:119:in require'
/Users/amritayalur/rails_projects/mobilecapdb/config/application.rb:7:in'
/Users/amritayalur/.rvm/rubies/ruby-1.9.2-p318/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:in require'
/Users/amritayalur/.rvm/rubies/ruby-1.9.2-p318/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:inrequire'
/Users/amritayalur/rails_projects/mobilecapdb/Rakefile:5:in <top (required)>'
/Users/amritayalur/.rvm/gems/ruby-1.9.2-p318/gems/rake-0.9.2.2/lib/rake/rake_module.rb:25:inload'
/Users/amritayalur/.rvm/gems/ruby-1.9.2-p318/gems/rake-0.9.2.2/lib/rake/rake_module.rb:25:in load_rakefile'
/Users/amritayalur/.rvm/gems/ruby-1.9.2-p318/gems/rake-0.9.2.2/lib/rake/application.rb:501:inraw_load_rakefile'
/Users/amritayalur/.rvm/gems/ruby-1.9.2-p318/gems/rake-0.9.2.2/lib/rake/application.rb:82:in block in load_rakefile'
/Users/amritayalur/.rvm/gems/ruby1.9.2p318/gems/rake0.9.2.2/lib/rake/application.rb:133:instandard_exception_handling'
/Users/amritayalur/.rvm/gems/ruby-1.9.2-p318/gems/rake-0.9.2.2/lib/rake/application.rb:81:in load_rakefile'
/Users/amritayalur/.rvm/gems/ruby-1.9.2-p318/gems/rake-0.9.2.2/lib/rake/application.rb:65:inblock in run'
/Users/amritayalur/.rvm/gems/ruby-1.9.2-p318/gems/rake-0.9.2.2/lib/rake/application.rb:133:in standard_exception_handling'
/Users/amritayalur/.rvm/gems/ruby-1.9.2-p318/gems/rake-0.9.2.2/lib/rake/application.rb:63:inrun'
/Users/amritayalur/.rvm/gems/ruby-1.9.2-p318/gems/rake-0.9.2.2/bin/rake:33:in <top (required)>'
/Users/amritayalur/.rvm/gems/ruby-1.9.2-p318/bin/rake:23:inload' /Users/amritayalur/.rvm/gems/ruby-1.9.2-p318/bin/rake:23:in <main>'
我該如何解決這個問題?
你正在使用哪個版本的導軌? – CodeMaster123
請運行此命令'rake db:migrate -trace'並粘貼完整的錯誤跟蹤 – abhas
我在rails 3.2.6 – Slicekick