[英]Ruby not loading CSV from stdlib
I'm not really sure why this isn't working and I am stuck finding a solution. 我不确定为什么这不起作用,我找不到解决方案。 Very simply, I am running a little script that does require 'CSV'
, which has been working fine on my Mac with 1.9.3-p327, but has not been working from the server on p374. 非常简单,我正在运行一个require 'CSV'
的小脚本,它在我的Mac上运行良好,使用1.9.3-p327,但是没有在p374上从服务器上运行。
The error I get is 我得到的错误是
/home/deployer/.rbenv/versions/1.9.3-p374/lib/ruby/1.9.1/rubygems/custom_require.rb:36:in
require': cannot load such file -- CSV (LoadError)<br> from /home/deployer/.rbenv/versions/1.9.3-p374/lib/ruby/1.9.1/rubygems/custom_require.rb:36:in
require' /home/deployer/.rbenv/versions/1.9.3-p374/lib/ruby/1.9.1/rubygems/custom_require.rb:36:inrequire': cannot load such file -- CSV (LoadError)<br> from /home/deployer/.rbenv/versions/1.9.3-p374/lib/ruby/1.9.1/rubygems/custom_require.rb:36:in
require'
The case is important. 这个案子很重要。 CSV
is not defined yet csv
should be. 尚未定义CSV
而csv
应该是。
require 'csv'
I don't have a Mac at hand but it probably works because your FS (HSF+) is case insensitive whereas the server is sensitive. 我手头没有Mac,但它可能有效,因为你的FS(HSF +)不区分大小写,而服务器是敏感的。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.