“参数个数错误(2个为1)(ArgumentError)”的问题

时间:2011-06-17 23:25:30

标签: mysql ruby-on-rails ruby

我正在尝试初始化我的本地rails服务器,但我无法, 因为当我写“rails server”时,请告诉我这条消息:

=> Booting WEBrick 
=> Rails 3.0.3 application starting in development on http://0.0.0.0:3000 
=> Call with -d to detach 
=> Ctrl-C to shutdown server 
Exiting 
/home/distriker/Documentos/public_html/auth/mysql2/ruby/1.8/gems/ 
activesupport-3.0.3/lib/active_support/dependencies.rb:239:in 
`require': wrong number of arguments (2 for 1) (ArgumentError) 
from /home/distriker/Documentos/public_html/auth/mysql2/ruby/1.8/gems/ 
activesupport-3.0.3/lib/active_support/dependencies.rb:239:in 
`require' 
from /home/distriker/Documentos/public_html/auth/mysql2/ruby/1.8/gems/ 
activesupport-3.0.3/lib/active_support/dependencies.rb:225:in 
`load_dependency' 
from /home/distriker/Documentos/public_html/auth/mysql2/ruby/1.8/gems/ 
activesupport-3.0.3/lib/active_support/dependencies.rb:596:in 
`new_constants_in' 
from /home/distriker/Documentos/public_html/auth/mysql2/ruby/1.8/gems/ 
activesupport-3.0.3/lib/active_support/dependencies.rb:225:in 
`load_dependency' 
from /home/distriker/Documentos/public_html/auth/mysql2/ruby/1.8/gems/ 
activesupport-3.0.3/lib/active_support/dependencies.rb:239:in 
`require' 
from /home/distriker/Documentos/public_html/auth/config.ru:6 
from /home/distriker/Documentos/public_html/auth/mysql2/ruby/1.8/gems/ 
rack-1.2.3/lib/rack/builder.rb:46:in `instance_eval' 
from /home/distriker/Documentos/public_html/auth/mysql2/ruby/1.8/gems/ 
rack-1.2.3/lib/rack/builder.rb:46:in `initialize' 
from /home/distriker/Documentos/public_html/auth/config.ru:1:in `new' 
from /home/distriker/Documentos/public_html/auth/config.ru:1 

问候,Iván

1 个答案:

答案 0 :(得分:1)

这似乎是“/home/distriker/Documentos/public_html/auth/mysql2/ruby/1.8/gems/ activesupport-3.0.3 / lib / active_support / dependencies.rb”第239行中的错误。它正在调用:

require 'one/thing', 'another/thing'

配置中的某些内容可能导致它执行此操作。

[题外话] 英语帮助:)

  1. “我还没能”=> “我无法”
  2. “奖励,Iván”=> “问候,Iván”
  3. 希望你不介意。 [/题外话]

    编辑|我可能先检查一下这行:“/ home /distriker/Documentos/public_html/auth/config.ru:6”