diff options
author | David RodrÃguez <deivid.rodriguez@riseup.net> | 2019-12-05 19:03:20 +0100 |
---|---|---|
committer | Hiroshi SHIBATA <hsbt@ruby-lang.org> | 2021-07-27 09:25:56 +0900 |
commit | 88e46cf6b83e2ca701cf122756fef9bc2550e845 (patch) | |
tree | 7ae3b612120e82cf36d78ce691bd8c7463a31bc7 /lib/rubygems.rb | |
parent | 6bcedabfdde74a21b8e1c93ec639afbb9698474b (diff) | |
download | ruby-88e46cf6b83e2ca701cf122756fef9bc2550e845.tar.gz |
[rubygems/rubygems] Remove all `syck` traces from `rubygems`
After reading [this blog
post](https://blog.rubygems.org/2011/08/31/shaving-the-yaml-yak.html),
published almost 10 years ago already, my understanding is that this
problem could come up in two ways:
* Rubygems.org serving corrupted gemspecs". As far as I understand this
was fixed in rubygems.org a lot time ago, since
https://github.com/rubygems/rubygems.org/pull/331.
* Clients having a ten years old gemspec cache with some of these bad
gemspecs. In this case, there's no easy solution but I think ten years
is enough and rebuilding the cache should do the trick.
So, I think it's time we remove this.
https://github.com/rubygems/rubygems/commit/afcb15d556
Diffstat (limited to 'lib/rubygems.rb')
-rw-r--r-- | lib/rubygems.rb | 10 |
1 files changed, 0 insertions, 10 deletions
diff --git a/lib/rubygems.rb b/lib/rubygems.rb index 1c5a25fd7f..60a599e380 100644 --- a/lib/rubygems.rb +++ b/lib/rubygems.rb @@ -628,12 +628,6 @@ An Array (#{env.inspect}) was passed in from #{caller[3]} rescue ::LoadError # If we can't load psych, that's fine, go on. else - # If 'yaml' has already been required, then we have to - # be sure to switch it over to the newly loaded psych. - if defined?(YAML::ENGINE) && YAML::ENGINE.yamler != "psych" - YAML::ENGINE.yamler = "psych" - end - require 'rubygems/psych_additions' require 'rubygems/psych_tree' end @@ -641,10 +635,6 @@ An Array (#{env.inspect}) was passed in from #{caller[3]} require 'yaml' require 'rubygems/safe_yaml' - # Now that we're sure some kind of yaml library is loaded, pull - # in our hack to deal with Syck's DefaultKey ugliness. - require 'rubygems/syck_hack' - @yaml_loaded = true end |