简体   繁体   English

Rails Webrick强制退出:未初始化的常量WebConsole :: Railtie :: Middleware(NameError)

[英]Rails webrick force-exits: uninitialized constant WebConsole::Railtie::Middleware (NameError)

So I'm a newbie in ruby trying to start up webrick for the first time. 因此,我是ruby的新手,试图首次启动webrick。 I just recently fixed the segmentation fault error with the mysql2, and got hit with this new exit issue. 我最近刚刚用mysql2修复了分段错误,并遇到了这个新的退出问题。 Here's the command line readout: 这是命令行读数:

G:\\Ruby Development\\simple_cms> G:\\ Ruby开发\\ simple_cms>

G:\\Ruby Development\\simple_cms>rails server G:\\ Ruby Development \\ simple_cms> rails服务器

=> Booting WEBrick =>正在启动WEBrick

=> Rails 4.2.1 application starting in development on http://localhost:3000 => Rails 4.2.1应用程序开始在http:// localhost:3000上进行开发

=> Run rails server -h for more startup options =>运行rails server -h获得更多启动选项

=> Ctrl-C to shutdown server => Ctrl-C关闭服务器

Exiting 退出

C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/web-console-2.1.2/lib/web_console/railtie.rb:21:in`block in ': uninitialized constant WebConsole::Railtie::Middleware (NameError) C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/web-console-2.1.2/lib/web_console/railtie.rb:21:in`中的':未初始化的常量WebConsole :: Railtie: :中间件(NameError)

from C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/railties-4.2.1/lib/rails/initializable.rb:30:in `instance_exec' 从C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/railties-4.2.1/lib/rails/initializable.rb:30:在`instance_exec'中

from C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/railties-4.2.1/lib/rails/initializable.rb:55:in `block in run_initializers' 从C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/railties-4.2.1/lib/rails/initializable.rb:55:在`run_initializers'中的块中

from C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/railties-4.2.1/lib/rails/initializable.rb:30:in `run' 从C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/railties-4.2.1/lib/rails/initializable.rb:30:在`run'中

from C:/Ruby22-x64/lib/ruby/2.2.0/tsort.rb:226:in `block in tsort_each' 来自C:/Ruby22-x64/lib/ruby/2.2.0/tsort.rb:226:in`tsort_each'中的block

from C:/Ruby22-x64/lib/ruby/2.2.0/tsort.rb:348:in `block (2 levels) in each_strongly_connected_component' 来自C:/Ruby22-x64/lib/ruby/2.2.0/tsort.rb:348:在each_strongly_connected_component中的'block(2 level)'中

from C:/Ruby22-x64/lib/ruby/2.2.0/tsort.rb:429:in `each_strongly_connected_component_from' 来自C:/Ruby22-x64/lib/ruby/2.2.0/tsort.rb:429:在`each_strongly_connected_component_from'中

from C:/Ruby22-x64/lib/ruby/2.2.0/tsort.rb:347:in `block in each_strongly_connected_component' 来自C:/Ruby22-x64/lib/ruby/2.2.0/tsort.rb:347:in each_strongly_connected_component中的block

from C:/Ruby22-x64/lib/ruby/2.2.0/tsort.rb:345:in `each' 来自C:/Ruby22-x64/lib/ruby/2.2.0/tsort.rb:345:在`each'中

from C:/Ruby22-x64/lib/ruby/2.2.0/tsort.rb:345:in `call' 从C:/Ruby22-x64/lib/ruby/2.2.0/tsort.rb:345:在`call'中

from C:/Ruby22-x64/lib/ruby/2.2.0/tsort.rb:345:in `each_strongly_connected_component' 来自C:/Ruby22-x64/lib/ruby/2.2.0/tsort.rb:345:在`each_strongly_connected_component'中

from C:/Ruby22-x64/lib/ruby/2.2.0/tsort.rb:224:in `tsort_each' 来自C:/Ruby22-x64/lib/ruby/2.2.0/tsort.rb:224:在`tsort_each'中

from C:/Ruby22-x64/lib/ruby/2.2.0/tsort.rb:203:in `tsort_each' 来自C:/Ruby22-x64/lib/ruby/2.2.0/tsort.rb:203:在`tsort_each'中

from C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/railties-4.2.1/lib/rails/initializable.rb:54:in `run_initializers' 从C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/railties-4.2.1/lib/rails/initializable.rb:54:在`run_initializers'中

from C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/railties-4.2.1/lib/rails/application.rb:352:in `initialize!' 从C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/railties-4.2.1/lib/rails/application.rb:352:在'initialize!'中

from G:/Ruby Development/simple_cms/config/environment.rb:5:in `' 来自G:/ Ruby Development / simple_cms / config / environment.rb:5:in'

from G:/Ruby Development/simple_cms/config.ru:3:in `require' 从G:/ Ruby Development / simple_cms / config.ru:3:在'require'中

from G:/Ruby Development/simple_cms/config.ru:3:in `block in ' 来自G:/ Ruby Development / simple_cms / config.ru:3:in在'block in'

from C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/rack-1.6.0/lib/rack/builder.rb:55:in `instance_eval' 从C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/rack-1.6.0/lib/rack/builder.rb:55:在`instance_eval'中

from C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/rack-1.6.0/lib/rack/builder.rb:55:in `initialize' 从C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/rack-1.6.0/lib/rack/builder.rb:55:在'initialize'中

from G:/Ruby Development/simple_cms/config.ru:in `new' 从G:/ Ruby Development / simple_cms / config.ru:在'new'中

from G:/Ruby Development/simple_cms/config.ru:in `' 来自G:/ Ruby Development / simple_cms / config.ru:in'

from C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/rack-1.6.0/lib/rack/builder.rb:49:in `eval' 从C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/rack-1.6.0/lib/rack/builder.rb:49:在`eval'中

from C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/rack-1.6.0/lib/rack/builder.rb:49:in `new_from_string' 从C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/rack-1.6.0/lib/rack/builder.rb:49:在`new_from_string'中

from C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/rack-1.6.0/lib/rack/builder.rb:40:in `parse_file' 从C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/rack-1.6.0/lib/rack/builder.rb:40:在`parse_file'中

from C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/rack-1.6.0/lib/rack/server.rb:299:in `build_app_and_options_from_config' 从C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/rack-1.6.0/lib/rack/server.rb:299:在`build_app_and_options_from_config'中

from C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/rack-1.6.0/lib/rack/server.rb:208:in `app' 从C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/rack-1.6.0/lib/rack/server.rb:208:在'app'中

from C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/railties-4.2.1/lib/rails/commands/server.rb:61:in `app' 从C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/railties-4.2.1/lib/rails/commands/server.rb:61:在'app'中

from C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/rack-1.6.0/lib/rack/server.rb:336:in `wrapped_app' 从C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/rack-1.6.0/lib/rack/server.rb:336:在'wrapped_app'中

from C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/railties-4.2.1/lib/rails/commands/server.rb:139:in `log_to_stdout' 从C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/railties-4.2.1/lib/rails/commands/server.rb:139:在`log_to_stdout'中

from C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/railties-4.2.1/lib/rails/commands/server.rb:78:in `start' 从C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/railties-4.2.1/lib/rails/commands/server.rb:78:在'开始'中

from C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/railties-4.2.1/lib/rails/commands/commands_tasks.rb:80:in `block in server' 从C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/railties-4.2.1/lib/rails/commands/commands_tasks.rb:80:在``服务器中的块''中

from C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/railties-4.2.1/lib/rails/commands/commands_tasks.rb:75:in `tap' 从C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/railties-4.2.1/lib/rails/commands/commands_tasks.rb:75:在'tap'中

from C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/railties-4.2.1/lib/rails/commands/commands_tasks.rb:75:in `server' 从C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/railties-4.2.1/lib/rails/commands/commands_tasks.rb:75:在`server'中

from C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/railties-4.2.1/lib/rails/commands/commands_tasks.rb:39:in `run_command!' 从C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/railties-4.2.1/lib/rails/commands/commands_tasks.rb:39:在`run_command!'中

from C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/railties-4.2.1/lib/rails/commands.rb:17:in `' 从C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/railties-4.2.1/lib/rails/commands.rb:17:in'

from bin/rails:4:in `require' 来自bin / rails:4:in`require'

from bin/rails:4:in `' 来自bin / rails:4:in

From what I understand so far I am loading the server up at least. 从到目前为止的了解来看,我至少正在加载服务器。 so this isn't a part of the segmentation fault, right? 所以这不是细分错误的一部分,对吧?

My gemfile includes web-console 2.1.2. 我的gemfile包含网络控制台2.1.2。 Also, I've ran 'bundle install' just in case. 另外,为了防万一,我还运行了“捆绑安装”程序。 Any insight into this error? 对这个错误有任何见解吗? Let me know if any more information is needed. 让我知道是否需要更多信息。

Rails Version -4.2.1 Ruby Version - 2.2.1p85 Rails版本-4.2.1 Ruby版本-2.2.1p85

There are two rails executables. 有两个Rails可执行文件。 Your PATH is pointing you to the wrong one. 您的路径将您指向错误的路径。 Type 'which rails': you should get "~/bin/rails", a stub that railties puts in your home directory. 键入“ where rails”:您应该得到“〜/ bin / rails”,railties将其存入主目录。 If you get something else, rename the rails executable there and try again. 如果还有其他问题,请在此处重命名rails可执行文件,然后重试。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM