铁轨和魔吉克

发布于 2024-09-29 09:08:39 字数 5098 浏览 6 评论 0原文

我一直在我的 Rails 应用程序上使用 rmagick 做了一些很酷的事情。我尝试使用“rails server”启动我的项目,但收到此错误。我相信我已经安装了 imagemagick 和 rmagick,所以我不知道为什么会看到这个错误。

/Users/devinross14/.gem/ruby/1.8/gems/activesupport-3.0.0/lib/active_support/dependencies.rb:239:in `require': no such file to load -- RMagick (LoadError)
    from /Users/devinross14/.gem/ruby/1.8/gems/activesupport-3.0.0/lib/active_support/dependencies.rb:239:in `require'
    from /Users/devinross14/.gem/ruby/1.8/gems/activesupport-3.0.0/lib/active_support/dependencies.rb:225:in `load_dependency'
    from /Users/devinross14/.gem/ruby/1.8/gems/activesupport-3.0.0/lib/active_support/dependencies.rb:591:in `new_constants_in'
    from /Users/devinross14/.gem/ruby/1.8/gems/activesupport-3.0.0/lib/active_support/dependencies.rb:225:in `load_dependency'
    from /Users/devinross14/.gem/ruby/1.8/gems/activesupport-3.0.0/lib/active_support/dependencies.rb:239:in `require'
    from /Users/devinross14/Documents/Philo/philo/lib/paperclip_processors/cropper.rb:1
    from /Users/devinross14/.gem/ruby/1.8/gems/activesupport-3.0.0/lib/active_support/dependencies.rb:239:in `require'
    from /Users/devinross14/.gem/ruby/1.8/gems/activesupport-3.0.0/lib/active_support/dependencies.rb:239:in `require'
    from /Users/devinross14/.gem/ruby/1.8/gems/activesupport-3.0.0/lib/active_support/dependencies.rb:225:in `load_dependency'
    from /Users/devinross14/.gem/ruby/1.8/gems/activesupport-3.0.0/lib/active_support/dependencies.rb:591:in `new_constants_in'
    from /Users/devinross14/.gem/ruby/1.8/gems/activesupport-3.0.0/lib/active_support/dependencies.rb:225:in `load_dependency'
    from /Users/devinross14/.gem/ruby/1.8/gems/activesupport-3.0.0/lib/active_support/dependencies.rb:239:in `require'
    from /Users/devinross14/Documents/Philo/philo/vendor/plugins/paperclip/lib/paperclip.rb:46
    from /Users/devinross14/Documents/Philo/philo/vendor/plugins/paperclip/lib/paperclip.rb:45:in `each'
    from /Users/devinross14/Documents/Philo/philo/vendor/plugins/paperclip/lib/paperclip.rb:45
    from /Users/devinross14/.gem/ruby/1.8/gems/activesupport-3.0.0/lib/active_support/dependencies.rb:239:in `require'
    from /Users/devinross14/.gem/ruby/1.8/gems/activesupport-3.0.0/lib/active_support/dependencies.rb:239:in `require'
    from /Users/devinross14/.gem/ruby/1.8/gems/activesupport-3.0.0/lib/active_support/dependencies.rb:225:in `load_dependency'
    from /Users/devinross14/.gem/ruby/1.8/gems/activesupport-3.0.0/lib/active_support/dependencies.rb:591:in `new_constants_in'
    from /Users/devinross14/.gem/ruby/1.8/gems/activesupport-3.0.0/lib/active_support/dependencies.rb:225:in `load_dependency'
    from /Users/devinross14/.gem/ruby/1.8/gems/activesupport-3.0.0/lib/active_support/dependencies.rb:239:in `require'
    from /Users/devinross14/Documents/Philo/philo/vendor/plugins/paperclip/lib/paperclip/railtie.rb:1
    from /Users/devinross14/.gem/ruby/1.8/gems/activesupport-3.0.0/lib/active_support/dependencies.rb:239:in `require'
    from /Users/devinross14/.gem/ruby/1.8/gems/activesupport-3.0.0/lib/active_support/dependencies.rb:239:in `require'
    from /Users/devinross14/.gem/ruby/1.8/gems/activesupport-3.0.0/lib/active_support/dependencies.rb:225:in `load_dependency'
    from /Users/devinross14/.gem/ruby/1.8/gems/activesupport-3.0.0/lib/active_support/dependencies.rb:591:in `new_constants_in'
    from /Users/devinross14/.gem/ruby/1.8/gems/activesupport-3.0.0/lib/active_support/dependencies.rb:225:in `load_dependency'
    from /Users/devinross14/.gem/ruby/1.8/gems/activesupport-3.0.0/lib/active_support/dependencies.rb:239:in `require'
    from /Users/devinross14/Documents/Philo/philo/vendor/plugins/paperclip/rails/init.rb:1
    from /Library/Ruby/Gems/1.8/gems/railties-3.0.0/lib/rails/plugin.rb:81
    from /Library/Ruby/Gems/1.8/gems/railties-3.0.0/lib/rails/initializable.rb:25:in `instance_exec'
    from /Library/Ruby/Gems/1.8/gems/railties-3.0.0/lib/rails/initializable.rb:25:in `run'
    from /Library/Ruby/Gems/1.8/gems/railties-3.0.0/lib/rails/initializable.rb:50:in `run_initializers'
    from /Library/Ruby/Gems/1.8/gems/railties-3.0.0/lib/rails/initializable.rb:49:in `each'
    from /Library/Ruby/Gems/1.8/gems/railties-3.0.0/lib/rails/initializable.rb:49:in `run_initializers'
    from /Library/Ruby/Gems/1.8/gems/railties-3.0.0/lib/rails/application.rb:134:in `initialize!'
    from /Library/Ruby/Gems/1.8/gems/railties-3.0.0/lib/rails/application.rb:77:in `send'
    from /Library/Ruby/Gems/1.8/gems/railties-3.0.0/lib/rails/application.rb:77:in `method_missing'
    from /Users/devinross14/Documents/Philo/philo/config/environment.rb:5
    from /Users/devinross14/Documents/Philo/philo/config.ru:3:in `require'
    from /Users/devinross14/Documents/Philo/philo/config.ru:3
    from /Library/Ruby/Gems/1.8/gems/rack-1.2.1/lib/rack/builder.rb:46:in `instance_eval'
    from /Library/Ruby/Gems/1.8/gems/rack-1.2.1/lib/rack/builder.rb:46:in `initialize'
    from /Users/devinross14/Documents/Philo/philo/config.ru:1:in `new'
    from /Users/devinross14/Documents/Philo/philo/config.ru:1

I've been doing some cool stuff with rmagick on my rails app. I tried starting up my project with 'rails server' and I got this error. I believe I have imagemagick and rmagick installed so I don't know why I see this error.

/Users/devinross14/.gem/ruby/1.8/gems/activesupport-3.0.0/lib/active_support/dependencies.rb:239:in `require': no such file to load -- RMagick (LoadError)
    from /Users/devinross14/.gem/ruby/1.8/gems/activesupport-3.0.0/lib/active_support/dependencies.rb:239:in `require'
    from /Users/devinross14/.gem/ruby/1.8/gems/activesupport-3.0.0/lib/active_support/dependencies.rb:225:in `load_dependency'
    from /Users/devinross14/.gem/ruby/1.8/gems/activesupport-3.0.0/lib/active_support/dependencies.rb:591:in `new_constants_in'
    from /Users/devinross14/.gem/ruby/1.8/gems/activesupport-3.0.0/lib/active_support/dependencies.rb:225:in `load_dependency'
    from /Users/devinross14/.gem/ruby/1.8/gems/activesupport-3.0.0/lib/active_support/dependencies.rb:239:in `require'
    from /Users/devinross14/Documents/Philo/philo/lib/paperclip_processors/cropper.rb:1
    from /Users/devinross14/.gem/ruby/1.8/gems/activesupport-3.0.0/lib/active_support/dependencies.rb:239:in `require'
    from /Users/devinross14/.gem/ruby/1.8/gems/activesupport-3.0.0/lib/active_support/dependencies.rb:239:in `require'
    from /Users/devinross14/.gem/ruby/1.8/gems/activesupport-3.0.0/lib/active_support/dependencies.rb:225:in `load_dependency'
    from /Users/devinross14/.gem/ruby/1.8/gems/activesupport-3.0.0/lib/active_support/dependencies.rb:591:in `new_constants_in'
    from /Users/devinross14/.gem/ruby/1.8/gems/activesupport-3.0.0/lib/active_support/dependencies.rb:225:in `load_dependency'
    from /Users/devinross14/.gem/ruby/1.8/gems/activesupport-3.0.0/lib/active_support/dependencies.rb:239:in `require'
    from /Users/devinross14/Documents/Philo/philo/vendor/plugins/paperclip/lib/paperclip.rb:46
    from /Users/devinross14/Documents/Philo/philo/vendor/plugins/paperclip/lib/paperclip.rb:45:in `each'
    from /Users/devinross14/Documents/Philo/philo/vendor/plugins/paperclip/lib/paperclip.rb:45
    from /Users/devinross14/.gem/ruby/1.8/gems/activesupport-3.0.0/lib/active_support/dependencies.rb:239:in `require'
    from /Users/devinross14/.gem/ruby/1.8/gems/activesupport-3.0.0/lib/active_support/dependencies.rb:239:in `require'
    from /Users/devinross14/.gem/ruby/1.8/gems/activesupport-3.0.0/lib/active_support/dependencies.rb:225:in `load_dependency'
    from /Users/devinross14/.gem/ruby/1.8/gems/activesupport-3.0.0/lib/active_support/dependencies.rb:591:in `new_constants_in'
    from /Users/devinross14/.gem/ruby/1.8/gems/activesupport-3.0.0/lib/active_support/dependencies.rb:225:in `load_dependency'
    from /Users/devinross14/.gem/ruby/1.8/gems/activesupport-3.0.0/lib/active_support/dependencies.rb:239:in `require'
    from /Users/devinross14/Documents/Philo/philo/vendor/plugins/paperclip/lib/paperclip/railtie.rb:1
    from /Users/devinross14/.gem/ruby/1.8/gems/activesupport-3.0.0/lib/active_support/dependencies.rb:239:in `require'
    from /Users/devinross14/.gem/ruby/1.8/gems/activesupport-3.0.0/lib/active_support/dependencies.rb:239:in `require'
    from /Users/devinross14/.gem/ruby/1.8/gems/activesupport-3.0.0/lib/active_support/dependencies.rb:225:in `load_dependency'
    from /Users/devinross14/.gem/ruby/1.8/gems/activesupport-3.0.0/lib/active_support/dependencies.rb:591:in `new_constants_in'
    from /Users/devinross14/.gem/ruby/1.8/gems/activesupport-3.0.0/lib/active_support/dependencies.rb:225:in `load_dependency'
    from /Users/devinross14/.gem/ruby/1.8/gems/activesupport-3.0.0/lib/active_support/dependencies.rb:239:in `require'
    from /Users/devinross14/Documents/Philo/philo/vendor/plugins/paperclip/rails/init.rb:1
    from /Library/Ruby/Gems/1.8/gems/railties-3.0.0/lib/rails/plugin.rb:81
    from /Library/Ruby/Gems/1.8/gems/railties-3.0.0/lib/rails/initializable.rb:25:in `instance_exec'
    from /Library/Ruby/Gems/1.8/gems/railties-3.0.0/lib/rails/initializable.rb:25:in `run'
    from /Library/Ruby/Gems/1.8/gems/railties-3.0.0/lib/rails/initializable.rb:50:in `run_initializers'
    from /Library/Ruby/Gems/1.8/gems/railties-3.0.0/lib/rails/initializable.rb:49:in `each'
    from /Library/Ruby/Gems/1.8/gems/railties-3.0.0/lib/rails/initializable.rb:49:in `run_initializers'
    from /Library/Ruby/Gems/1.8/gems/railties-3.0.0/lib/rails/application.rb:134:in `initialize!'
    from /Library/Ruby/Gems/1.8/gems/railties-3.0.0/lib/rails/application.rb:77:in `send'
    from /Library/Ruby/Gems/1.8/gems/railties-3.0.0/lib/rails/application.rb:77:in `method_missing'
    from /Users/devinross14/Documents/Philo/philo/config/environment.rb:5
    from /Users/devinross14/Documents/Philo/philo/config.ru:3:in `require'
    from /Users/devinross14/Documents/Philo/philo/config.ru:3
    from /Library/Ruby/Gems/1.8/gems/rack-1.2.1/lib/rack/builder.rb:46:in `instance_eval'
    from /Library/Ruby/Gems/1.8/gems/rack-1.2.1/lib/rack/builder.rb:46:in `initialize'
    from /Users/devinross14/Documents/Philo/philo/config.ru:1:in `new'
    from /Users/devinross14/Documents/Philo/philo/config.ru:1

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

只是一片海 2024-10-06 09:08:39

在您的环境中尝试一下。rb

config.gem "rmagick", :lib => "RMagick"

Try this in your environment.rb

config.gem "rmagick", :lib => "RMagick"
情丝乱 2024-10-06 09:08:39

您也许应该尝试gem install rmagick?这给了你什么?

You should probably try gem install rmagick? What does that give you?

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文