错误要求:无法加载此类文件 - mongomapper(LoadError)并且不知道从哪里开始

时间:2012-04-07 00:17:23

标签: ruby rubygems mongomapper

启动sinatra应用程序后,收到以下错误消息:

/home/matt/.rvm/gems/ruby-1.9.3-p125/gems/backports-2.5.1/lib/backports/tools.rb:310:in `require': cannot load such file -- mongomapper (LoadError)
    from /home/matt/.rvm/gems/ruby-1.9.3-p125/gems/backports-2.5.1/lib/backports/tools.rb:310:in `require_with_backports'
    from /home/matt/handle-phone-call/app.rb:10:in `<top (required)>'
    from /home/matt/.rvm/rubies/ruby-1.9.3-p125/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:in `require'
    from /home/matt/.rvm/rubies/ruby-1.9.3-p125/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:in `require'
    from /home/matt/handle-phone-call/config.ru:2:in `block in <main>'
    from /home/matt/.rvm/gems/ruby-1.9.3-p125/gems/rack-1.4.1/lib/rack/builder.rb:51:in `instance_eval'
    from /home/matt/.rvm/gems/ruby-1.9.3-p125/gems/rack-1.4.1/lib/rack/builder.rb:51:in `initialize'
    from /home/matt/handle-phone-call/config.ru:1:in `new'
    from /home/matt/handle-phone-call/config.ru:1:in `<main>'
    from /home/matt/.rvm/gems/ruby-1.9.3-p125/gems/rack-1.4.1/lib/rack/builder.rb:40:in `eval'
    from /home/matt/.rvm/gems/ruby-1.9.3-p125/gems/rack-1.4.1/lib/rack/builder.rb:40:in `parse_file'
    from /home/matt/.rvm/gems/ruby-1.9.3-p125/gems/rack-1.4.1/lib/rack/server.rb:200:in `app'
    from /home/matt/.rvm/gems/ruby-1.9.3-p125/gems/rack-1.4.1/lib/rack/server.rb:301:in `wrapped_app'
    from /home/matt/.rvm/gems/ruby-1.9.3-p125/gems/rack-1.4.1/lib/rack/server.rb:252:in `start'
    from /home/matt/.rvm/gems/ruby-1.9.3-p125/gems/rack-1.4.1/lib/rack/server.rb:137:in `start'
    from /home/matt/.rvm/gems/ruby-1.9.3-p125/gems/rack-1.4.1/bin/rackup:4:in `<top (required)>'
    from /home/matt/.rvm/gems/ruby-1.9.3-p125/bin/rackup:19:in `load'
    from /home/matt/.rvm/gems/ruby-1.9.3-p125/bin/rackup:19:in `<main>'

有什么想法吗?我对从哪里开始一无所知。

1 个答案:

答案 0 :(得分:1)

您应该要求mongo_mapper,而不是mongomapper