Ruby 1.9.2-p290 通过 rbenv 产生来自 psych-1.2.1 的警告:VERSION 和 LIBYAML_VERSION
当我运行 ruby 时,我收到以下警告:
~/.gem/gems/psych-1.2.1/lib/psych.rb:93: warning: already initialized constant VERSION
~/.gem/gems/psych-1.2.1/lib/psych.rb:96: warning: already initialized constant LIBYAML_VERSION
我尝试过谷歌搜索,但似乎找到了一个解决方案,这让我认为它特定于我的系统。有办法解决这个问题吗?
When I running ruby I get the following warnings:
~/.gem/gems/psych-1.2.1/lib/psych.rb:93: warning: already initialized constant VERSION
~/.gem/gems/psych-1.2.1/lib/psych.rb:96: warning: already initialized constant LIBYAML_VERSION
I've tried googling around but can seem to find a solution which makes me think it's specific to my system. Is there a way to fix this?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
这个问题似乎源于Bundler.setup中bundler调用psych。我使用的解决方法:
在我之前的代码中
This problem seems to originate in psych being called by bundler in Bundler.setup. The work-around I used:
In my code before
有两种方法。
->第一
然后运行
->第二
gem在控制台
There are two ways.
->First
in your Gemfile file and then run
-> Second
at console