【发布时间】:2015-03-07 21:11:36
【问题描述】:
在将include CarrierWave::MiniMagick 添加到我的image_uploader.rb 文件并取消注释image_uploader.rb 内的process: resize to fit => [200,300] 行之后,每当我尝试在我的应用中创建新列表时,我都会收到以下错误消息:
"Errno::ENOENT in ListingsController#create" with the explanation of "No such file or directory - identify".
似乎错误发生在“创建”操作内第 20 行的 'app/controllers/listings_controller.rb' 目录中。
错误页面上提取源的描述显示如下:
self.pid = Process.spawn({'LANG' => self.lang}, command, log_opts)
作为引发错误的行。
在这两个提到的更改之前,新的列表将毫无问题地创建(除了附加的图像太大,因此是我的最新更改)。我正在使用 Cloud9 IDE 开发此应用程序,Puma 作为我的 Web 服务器,Heroku 作为(预期的)未来生产级应用程序主机。
【问题讨论】:
-
原来我的 Cloud9 IDE 工作站中没有安装 ImageMagick;运行“sudo apt-get update”,然后运行“sudo apt-get install ImageMagick”来修复这个错误。
标签: ruby-on-rails ruby imagemagick-convert minimagick