Project

General

Profile

Bug #16337

kernel_gem.rb:68 - ThreadError

Added by MSP-Greg (Greg L) 5 months ago. Updated about 1 month ago.

Status:
Third Party's Issue
Priority:
Normal
Target version:
-
ruby -v:
ruby 2.7.0p0 (2019-12-25 revision 647ee6f091) [x86_64-linux]
[ruby-core:95768]

Description

Found with ruby-loco CLI tests

See: https://ci.appveyor.com/project/MSP-Greg/ruby-loco/builds/28731823#L2922

> rake --version
Traceback (most recent call last):
  10: from bin/rake:23:in `<main>'
   9: from lib/ruby/2.7.0/rubygems.rb:301:in `activate_bin_path'
   8: from lib/ruby/2.7.0/rubygems.rb:301:in `synchronize'
   7: from lib/ruby/2.7.0/rubygems.rb:303:in `block in activate_bin_path'
   6: from lib/ruby/2.7.0/rubygems.rb:240:in `finish_resolve'
   5: from lib/ruby/2.7.0/rubygems/request_set.rb:435:in `resolve_current'
   4: from lib/ruby/2.7.0/rubygems/request_set.rb:435:in `new'
   3: from lib/ruby/2.7.0/rubygems/resolver/set.rb:24:in `initialize'
   2: from lib/ruby/2.7.0/rubygems/core_ext/kernel_require.rb:69:in `require'
   1: from lib/ruby/2.7.0/rubygems/core_ext/kernel_gem.rb:68:in `gem'
kernel_gem.rb:68:in `synchronize': deadlock; recursive locking (ThreadError)

Updated by znz (Kazuhiro NISHIYAMA) 5 months ago

rm $(gem env gemdir)/specifications/default/uri-0.10.0.gemspec is workaround.
But I don't know why.

#2

Updated by hsbt (Hiroshi SHIBATA) 5 months ago

  • Status changed from Open to Closed

Applied in changeset git|fdfad905227a0e2e4c224d87181041fb75d5082e.


Revert "Promote uri to default gems"

This reverts commit c5b4d2a2592942766dc2789f46105b91eba7026a.

This commit affects with activation feature of RubyGems.
[Bug #16337][ruby-core:95768]

Updated by jkohen (Javier Kohen) 3 months ago

  • ruby -v changed from ruby 2.7.0dev (2019-11-09T02:08:24Z master 352887b731) [x64-mingw32] to ruby 2.7.0p0 (2019-12-25 revision 647ee6f091) [x86_64-linux]
  • Status changed from Closed to Open

I'm still seeing this on 2.7.0p0, even though it looks like it should have been fixed based on comment #2. The workaround in comment #1 still helps.

$ /opt/google-fluentd/embedded/bin/ruby --version
ruby 2.7.0p0 (2019-12-25 revision 647ee6f091) [x86_64-linux]
$ /opt/google-fluentd/embedded/bin/ruby /opt/google-fluentd/embedded/bin/rake --version
Traceback (most recent call last):
        10: from /opt/google-fluentd/embedded/bin/rake:23:in `<main>'
         9: from /opt/google-fluentd/embedded/lib/ruby/site_ruby/2.7.0/rubygems.rb:303:in `activate_bin_path'
         8: from /opt/google-fluentd/embedded/lib/ruby/site_ruby/2.7.0/rubygems.rb:303:in `synchronize'
         7: from /opt/google-fluentd/embedded/lib/ruby/site_ruby/2.7.0/rubygems.rb:305:in `block in activate_bin_path'
         6: from /opt/google-fluentd/embedded/lib/ruby/site_ruby/2.7.0/rubygems.rb:242:in `finish_resolve'
         5: from /opt/google-fluentd/embedded/lib/ruby/site_ruby/2.7.0/rubygems/request_set.rb:435:in `resolve_current'
         4: from /opt/google-fluentd/embedded/lib/ruby/site_ruby/2.7.0/rubygems/request_set.rb:435:in `new'
         3: from /opt/google-fluentd/embedded/lib/ruby/site_ruby/2.7.0/rubygems/resolver/set.rb:24:in `initialize'
         2: from /opt/google-fluentd/embedded/lib/ruby/site_ruby/2.7.0/rubygems/core_ext/kernel_require.rb:42:in `require'
         1: from /opt/google-fluentd/embedded/lib/ruby/site_ruby/2.7.0/rubygems/core_ext/kernel_gem.rb:67:in `gem'
/opt/google-fluentd/embedded/lib/ruby/site_ruby/2.7.0/rubygems/core_ext/kernel_gem.rb:67:in `synchronize': deadlock; recursive locking (ThreadError)
$ rm /opt/google-fluentd/embedded/lib/ruby/gems/2.7.0/specifications/default/uri-0.10.0.gemspec
$ /opt/google-fluentd/embedded/bin/ruby /opt/google-fluentd/embedded/bin/rake --version
rake, version 12.3.2

Updated by hsbt (Hiroshi SHIBATA) about 1 month ago

  • Assignee set to hsbt (Hiroshi SHIBATA)
  • Status changed from Open to Third Party's Issue

I couldn't reproduce it with my environment. Can you ask the maintainer of google-fluentd at first?

Updated by deivid (David Rodríguez) about 1 month ago

I guess this is because you're not using the latest rubygems. Could you run gem env version and check that you have a rubygems version older than 3.1?

You need to request upgrading rubygems to google-fluentd, maybe here: https://github.com/GoogleCloudPlatform/google-fluentd/blob/269ade4d609cd9ae59819bcdfe8977a52727ec72/config/projects/google-fluentd.rb#L19, although it would seem that they're using ruby 2.6 and you're on 2.7, so not sure.

Also available in: Atom PDF