2013-07-16 28 views
0

长话短说,我启动了我的系统,当我告诉Rubymine运行开发时,我得到了这个结果。Ruby on Rails:Code Rot

/home/barnabus/.rvm/rubies/ruby-1.9.3-p385/bin/ruby -e $stdout.sync=true;$stderr.sync=true;load($0=ARGV.shift) /home/barnabus/Projects/Ruby/houston/script/rails server -b 0.0.0.0 -p 3000 -e development 
/home/barnabus/.rvm/gems/ruby-1.9.3-p385/gems/actionpack-3.2.8/lib/action_controller/metal/mime_responds.rb:9:in `<module:MimeResponds>': /home/barnabus/.rvm/gems/ruby-1.9.3-p385/gems/actionpack-3.2.8/lib/action_controller/metal/implicit_render.rb:10: syntax error, unexpected tINTEGER, expecting keyword_end (SyntaxError) 
from /home/barnabus/.rvm/gems/ruby-1.9.3-p385/gems/actionpack-3.2.8/lib/action_controller/metal/mime_responds.rb:6:in `<module:ActionController>' 
from /home/barnabus/.rvm/gems/ruby-1.9.3-p385/gems/actionpack-3.2.8/lib/action_controller/metal/mime_responds.rb:5:in `<top (required)>' 
from /home/barnabus/.rvm/gems/ruby-1.9.3-p385/gems/actionpack-3.2.8/lib/action_controller/base.rb:196:in `<class:Base>' 
from /home/barnabus/.rvm/gems/ruby-1.9.3-p385/gems/actionpack-3.2.8/lib/action_controller/base.rb:171:in `<module:ActionController>' 
from /home/barnabus/.rvm/gems/ruby-1.9.3-p385/gems/actionpack-3.2.8/lib/action_controller/base.rb:3:in `<top (required)>' 
from /home/barnabus/.rvm/gems/ruby-1.9.3-p385/gems/cancan-1.6.10/lib/cancan/controller_additions.rb:394:in `<top (required)>' 
from /home/barnabus/.rvm/gems/ruby-1.9.3-p385/gems/activesupport-3.2.8/lib/active_support/dependencies.rb:251:in `require' 
from /home/barnabus/.rvm/gems/ruby-1.9.3-p385/gems/activesupport-3.2.8/lib/active_support/dependencies.rb:251:in `block in require' 
from /home/barnabus/.rvm/gems/ruby-1.9.3-p385/gems/activesupport-3.2.8/lib/active_support/dependencies.rb:236:in `load_dependency' 
from /home/barnabus/.rvm/gems/ruby-1.9.3-p385/gems/activesupport-3.2.8/lib/active_support/dependencies.rb:251:in `require' 
from /home/barnabus/.rvm/gems/ruby-1.9.3-p385/gems/cancan-1.6.10/lib/cancan.rb:4:in `<top (required)>' 
from /home/barnabus/.rvm/gems/ruby-1.9.3-p385/gems/bundler-1.2.4/lib/bundler/runtime.rb:68:in `require' 
from /home/barnabus/.rvm/gems/ruby-1.9.3-p385/gems/bundler-1.2.4/lib/bundler/runtime.rb:68:in `block (2 levels) in require' 
from /home/barnabus/.rvm/gems/ruby-1.9.3-p385/gems/bundler-1.2.4/lib/bundler/runtime.rb:66:in `each' 
from /home/barnabus/.rvm/gems/ruby-1.9.3-p385/gems/bundler-1.2.4/lib/bundler/runtime.rb:66:in `block in require' 
from /home/barnabus/.rvm/gems/ruby-1.9.3-p385/gems/bundler-1.2.4/lib/bundler/runtime.rb:55:in `each' 
from /home/barnabus/.rvm/gems/ruby-1.9.3-p385/gems/bundler-1.2.4/lib/bundler/runtime.rb:55:in `require' 
from /home/barnabus/.rvm/gems/ruby-1.9.3-p385/gems/bundler-1.2.4/lib/bundler.rb:128:in `require' 
from /home/barnabus/Projects/Ruby/houston/config/application.rb:7:in `<top (required)>' 
from /home/barnabus/.rvm/gems/ruby-1.9.3-p385/gems/railties-3.2.8/lib/rails/commands.rb:53:in `require' 
from /home/barnabus/.rvm/gems/ruby-1.9.3-p385/gems/railties-3.2.8/lib/rails/commands.rb:53:in `block in <top (required)>' 
from /home/barnabus/.rvm/gems/ruby-1.9.3-p385/gems/railties-3.2.8/lib/rails/commands.rb:50:in `tap' 
from /home/barnabus/.rvm/gems/ruby-1.9.3-p385/gems/railties-3.2.8/lib/rails/commands.rb:50:in `<top (required)>' 
from /home/barnabus/Projects/Ruby/houston/script/rails:6:in `require' 
from /home/barnabus/Projects/Ruby/houston/script/rails:6:in `<top (required)>' 
from -e:1:in `load' 
from -e:1:in `<main>' 
Process finished with exit code 1 

我从来没有见过这个错误,我真的不知道在哪里以及如何继续,因为有太多这是在框架代码发生的事情。

任何帮助,非常感谢。

回答

0

诀窍是看到它是一个正在发展的宝石。所以我去了并卸载了这个宝石。

bundle exec gem uninstall actionpack 

它抱怨依赖关系。

You have requested to uninstall the gem: 
actionpack-3.2.8 
actionmailer-3.2.8 depends on [actionpack (= 3.2.8)] 
railties-3.2.8 depends on [actionpack (= 3.2.8)] 
rails-3.2.8 depends on [actionpack (= 3.2.8)] 
rspec-rails-2.12.2 depends on [actionpack (>= 3.0)] 
simple_form-2.0.4 depends on [actionpack (~> 3.0)] 
If you remove this gems, one or more dependencies will not be met. 
Continue with Uninstall? [Yn] Y 

但这并不重要,因为我们要重新安装它。

Successfully uninstalled actionpack-3.2.8 
ERROR: While executing gem ... (NoMethodError) 
undefined method `delete' for #<Bundler::SpecSet:0x00000002c53b20> 

之后做我不得不重新安装它,这样做,我只是跑

bundle install 

我回到了正轨。

+1

“暴徒生活”?如何添加一些有用的信息? – meagar

+0

@meagar叹了口气,它被改变了。 –