Rails服务器无法以rubymine中的退出代码1启动

时间:2012-10-12 18:27:18

标签: ruby-on-rails-3 webserver rubymine webrick

我昨天使用我的服务器没问题。今天回来时启动服务器时出错

runnerw.exe C:\Ruby187\bin\ruby.exe -e $stdout.sync=true;$stderr.sync=true;load($0=ARGV.shift) "C:/Users/Stefan/RubymineProjects/gallery/gallery-app/script/rails" server -b 127.0.0.1 -p 3000 -e development
=> Booting WEBrick
=> Rails 3.2.8 application starting in development on http://127.0.0.1:3000
=> Call with -d to detach
=> Ctrl-C to shutdown server
Exiting
C:/Ruby187/lib/ruby/gems/1.8/gems/actionpack-3.2.8/lib/action_dispatch/routing/route_set.rb:278:in `eval_block': C:/Ruby187/lib/ruby/gems/1.8/gems/actionpack-3.2.8/lib/action_dispatch/routing/mapper.rb:1508: syntax error, unexpected kEND, expecting $end (SyntaxError)
    from C:/Ruby187/lib/ruby/gems/1.8/gems/actionpack-3.2.8/lib/action_dispatch/routing/route_set.rb:297:in `clear!'
    from C:/Ruby187/lib/ruby/gems/1.8/gems/actionpack-3.2.8/lib/action_dispatch/routing/route_set.rb:297:in `each'
    from C:/Ruby187/lib/ruby/gems/1.8/gems/actionpack-3.2.8/lib/action_dispatch/routing/route_set.rb:297:in `clear!'
    from C:/Ruby187/lib/ruby/gems/1.8/gems/railties-3.2.8/lib/rails/application/routes_reloader.rb:35:in `clear!'
    from C:/Ruby187/lib/ruby/gems/1.8/gems/railties-3.2.8/lib/rails/application/routes_reloader.rb:33:in `each'
    from C:/Ruby187/lib/ruby/gems/1.8/gems/railties-3.2.8/lib/rails/application/routes_reloader.rb:33:in `clear!'
    from C:/Ruby187/lib/ruby/gems/1.8/gems/railties-3.2.8/lib/rails/application/routes_reloader.rb:15:in `reload!'
    from C:/Ruby187/lib/ruby/gems/1.8/gems/railties-3.2.8/lib/rails/application/routes_reloader.rb:26:in `updater'
    from C:/Ruby187/lib/ruby/gems/1.8/gems/activesupport-3.2.8/lib/active_support/file_update_checker.rb:78:in `call'
    from C:/Ruby187/lib/ruby/gems/1.8/gems/activesupport-3.2.8/lib/active_support/file_update_checker.rb:78:in `execute'
    from C:/Ruby187/lib/ruby/gems/1.8/gems/railties-3.2.8/lib/rails/application/routes_reloader.rb:27:in `updater'
    from C:0:in `execute_if_updated'
    from C:/Ruby187/lib/ruby/gems/1.8/gems/railties-3.2.8/lib/rails/application/finisher.rb:66
    from C:/Ruby187/lib/ruby/gems/1.8/gems/railties-3.2.8/lib/rails/initializable.rb:30:in `instance_exec'
    from C:/Ruby187/lib/ruby/gems/1.8/gems/railties-3.2.8/lib/rails/initializable.rb:30:in `run'
    from C:/Ruby187/lib/ruby/gems/1.8/gems/railties-3.2.8/lib/rails/initializable.rb:55:in `run_initializers'
    from C:/Ruby187/lib/ruby/gems/1.8/gems/railties-3.2.8/lib/rails/initializable.rb:54:in `each'
    from C:/Ruby187/lib/ruby/gems/1.8/gems/railties-3.2.8/lib/rails/initializable.rb:54:in `run_initializers'
    from C:/Ruby187/lib/ruby/gems/1.8/gems/railties-3.2.8/lib/rails/application.rb:136:in `initialize!'
    from C:/Ruby187/lib/ruby/gems/1.8/gems/railties-3.2.8/lib/rails/railtie/configurable.rb:30:in `send'
    from C:/Ruby187/lib/ruby/gems/1.8/gems/railties-3.2.8/lib/rails/railtie/configurable.rb:30:in `method_missing'
    from C:/Users/Stefan/RubymineProjects/gallery/gallery-app/config/environment.rb:5
    from C:/Users/Stefan/RubymineProjects/gallery/gallery-app/config.ru:4:in `require'
    from C:/Users/Stefan/RubymineProjects/gallery/gallery-app/config.ru:4
    from C:/Ruby187/lib/ruby/gems/1.8/gems/rack-1.4.1/lib/rack/builder.rb:51:in `instance_eval'
    from C:/Ruby187/lib/ruby/gems/1.8/gems/rack-1.4.1/lib/rack/builder.rb:51:in `initialize'
    from C:/Users/Stefan/RubymineProjects/gallery/gallery-app/config.ru:1:in `new'
    from C:/Users/Stefan/RubymineProjects/gallery/gallery-app/config.ru:1

Process finished with exit code 1

不确定是什么导致这种情况,令我感到困惑的是为什么它现在才决定弹出。

1 个答案:

答案 0 :(得分:0)

我能够通过重新安装actionpack gem来解决这个问题。它必定已经腐败,或者我在昨晚和今天之间意外地改变了它。