ruby-on-rails - 使用 Rails : syck has been removed, psych

标签 ruby-on-rails ruby psych syck

我在我的 rails 项目的 capistrano 部署期间收到此消息:

syck has been removed, psych is used instead

版本:

gem 'rails', '=3.2.13'
ruby 2.0.0p247

据我所知,ruby 使用原生 yamler“Psych”。

Gemfile 中没有任何 yamler。

在我的 boot.rb 中:

require 'yaml'
YAML::ENGINE.yamler = 'psych'

可能是什么问题?

最佳答案

这可能意味着 yamler 被分配到某处的 gem 中。您可以在此处查看消息是如何生成的:https://github.com/ruby/ruby/blob/8a896179ada36b4fc0f50d75500c801a3097924a/lib/yaml.rb

如果调用 yamler = 'syck',则会产生警告。

我搜索了我的 gems,发现我有一个旧版本的 newrelic_rpm,它有以下导致问题的行: YAML::ENGINE.yamler = 'syck' 如果已定义?(YAML::ENGINE)

更新 newrelic gem 为我解决了这个问题。祝你好运。

关于ruby-on-rails - 使用 Rails : syck has been removed, psych,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/19247212/

相关文章:

ruby-on-rails - 我怎样才能干这个代码?

ruby-on-rails - 无法使用 shoulda 匹配器获得唯一性验证测试通过

r - 如何在 R 中创建并行分析屏幕?

r - Z 标准化使得 PC1 和 PC2 在此 PCA 分析中完全相同 : Why?

ruby-on-rails - Faker gem : possible to seed with stylized text?

ruby-on-rails - Rails 3 : “:method => :post” doesn't work… seems to be 'GET' when it should 'POST'

ruby - Vagrant 提供者特定变量

ruby-on-rails - Rspec should_receive 在一个没有行为的实例上

ruby - Sinatra cookie 未按预期运行

windows - 错误: Error installing psych: ERROR: Failed to build gem native extension