Project

General

Profile

Actions

Bug #16043

closed

There was an error while trying to load the gem 'arvados'.Gem Load Error is: can't modify frozen String

Added by Ward Vandewege almost 5 years ago. Updated almost 5 years ago.

Status:
Closed
Priority:
Normal
Assigned To:
-
Category:
Workbench
Target version:
Story points:
-

Related issues 2 (0 open2 closed)

Related to Arvados - Bug #13920: arvados-cli fails with ruby versions >= 2.3.7ResolvedLucas Di Pentima07/26/2018Actions
Related to Arvados - Bug #17738: [ruby] sudden gem load errors on ubuntu 18.04 (ruby 2.5.1)ResolvedWard Vandewege05/27/2021Actions
Actions #1

Updated by Ward Vandewege almost 5 years ago

  • Category set to Workbench
  • Subject changed from There was an error while trying to load the gem 'arvados'. Gem Load Error is: can't modify frozen String to There was an error while trying to load the gem 'arvados'.Gem Load Error is: can't modify frozen String

I seems that under ruby 2.5, Workbench can't start anymore due to the backtrace below.

The error is at line 9 in sdk/ruby/lib/arvados/google_api_client.rb:

require 'google/api_client'
# Monkeypatch google-api-client gem to avoid sending newline characters
# on headers to make ruby-2.3.7+ happy.
# See: https://dev.arvados.org/issues/13920
Google::APIClient::ENV::OS_VERSION.strip!

I guess that OS_VERSION string is frozen now, and modifications are not allowed.

There was an error while trying to load the gem 'arvados'.
Gem Load Error is: can't modify frozen String
Backtrace for gem load error is:
/var/www/arvados-workbench/current/vendor/cache/arvados-dd9f2403f43b/sdk/ruby/lib/arvados/google_api_client.rb:9:in `strip!'
/var/www/arvados-workbench/current/vendor/cache/arvados-dd9f2403f43b/sdk/ruby/lib/arvados/google_api_client.rb:9:in `<top (required)>'
/var/www/arvados-workbench/current/vendor/cache/arvados-dd9f2403f43b/sdk/ruby/lib/arvados.rb:11:in `require'
/var/www/arvados-workbench/current/vendor/cache/arvados-dd9f2403f43b/sdk/ruby/lib/arvados.rb:11:in `<top (required)>'
/usr/lib/ruby/vendor_ruby/bundler/runtime.rb:81:in `require'
/usr/lib/ruby/vendor_ruby/bundler/runtime.rb:81:in `block (2 levels) in require'
/usr/lib/ruby/vendor_ruby/bundler/runtime.rb:76:in `each'
/usr/lib/ruby/vendor_ruby/bundler/runtime.rb:76:in `block in require'
/usr/lib/ruby/vendor_ruby/bundler/runtime.rb:65:in `each'
/usr/lib/ruby/vendor_ruby/bundler/runtime.rb:65:in `require'
/usr/lib/ruby/vendor_ruby/bundler.rb:114:in `require'
/var/www/arvados-workbench/current/config/application.rb:20:in `<top (required)>'
/var/www/arvados-workbench/current/config/environment.rb:6:in `require_relative'
/var/www/arvados-workbench/current/config/environment.rb:6:in `<top (required)>'
config.ru:7:in `require'
config.ru:7:in `block in <main>'
/var/www/arvados-workbench/shared/vendor_bundle/ruby/2.5.0/gems/rack-2.0.7/lib/rack/builder.rb:55:in `instance_eval'
/var/www/arvados-workbench/shared/vendor_bundle/ruby/2.5.0/gems/rack-2.0.7/lib/rack/builder.rb:55:in `initialize'
config.ru:1:in `new'
config.ru:1:in `<main>'
/usr/share/passenger/helper-scripts/rack-preloader.rb:101:in `eval'
/usr/share/passenger/helper-scripts/rack-preloader.rb:101:in `preload_app'
/usr/share/passenger/helper-scripts/rack-preloader.rb:189:in `block in <module:App>'
/usr/lib/ruby/vendor_ruby/phusion_passenger/loader_shared_helpers.rb:380:in `run_block_and_record_step_progress'
/usr/share/passenger/helper-scripts/rack-preloader.rb:188:in `<module:App>'
/usr/share/passenger/helper-scripts/rack-preloader.rb:30:in `<module:PhusionPassenger>'
/usr/share/passenger/helper-scripts/rack-preloader.rb:29:in `<main>'
Bundler Error Backtrace:
 (Bundler::GemRequireError)
  /usr/lib/ruby/vendor_ruby/bundler/runtime.rb:84:in `rescue in block (2 levels) in require'
  /usr/lib/ruby/vendor_ruby/bundler/runtime.rb:80:in `block (2 levels) in require'
  /usr/lib/ruby/vendor_ruby/bundler/runtime.rb:76:in `each'
  /usr/lib/ruby/vendor_ruby/bundler/runtime.rb:76:in `block in require'
  /usr/lib/ruby/vendor_ruby/bundler/runtime.rb:65:in `each'
  /usr/lib/ruby/vendor_ruby/bundler/runtime.rb:65:in `require'
  /usr/lib/ruby/vendor_ruby/bundler.rb:114:in `require'
  /var/www/arvados-workbench/current/config/application.rb:20:in `<top (required)>'
  /var/www/arvados-workbench/current/config/environment.rb:6:in `require_relative'
  /var/www/arvados-workbench/current/config/environment.rb:6:in `<top (required)>'
  config.ru:7:in `require'
  config.ru:7:in `block in <main>'
  /var/www/arvados-workbench/shared/vendor_bundle/ruby/2.5.0/gems/rack-2.0.7/lib/rack/builder.rb:55:in `instance_eval'
  /var/www/arvados-workbench/shared/vendor_bundle/ruby/2.5.0/gems/rack-2.0.7/lib/rack/builder.rb:55:in `initialize'
  config.ru:1:in `new'
  config.ru:1:in `<main>'
  /usr/share/passenger/helper-scripts/rack-preloader.rb:101:in `eval'
  /usr/share/passenger/helper-scripts/rack-preloader.rb:101:in `preload_app'
  /usr/share/passenger/helper-scripts/rack-preloader.rb:189:in `block in <module:App>'
  /usr/lib/ruby/vendor_ruby/phusion_passenger/loader_shared_helpers.rb:380:in `run_block_and_record_step_progress'
  /usr/share/passenger/helper-scripts/rack-preloader.rb:188:in `<module:App>'
  /usr/share/passenger/helper-scripts/rack-preloader.rb:30:in `<module:PhusionPassenger>'
  /usr/share/passenger/helper-scripts/rack-preloader.rb:29:in `<main>'
Actions #2

Updated by Ward Vandewege almost 5 years ago

  • Related to Bug #13920: arvados-cli fails with ruby versions >= 2.3.7 added
Actions #3

Updated by Ward Vandewege almost 5 years ago

Hmmm. I upgraded workbench.ce8i5 to the latest bleeding edge and I'm not seeing this error anymore. Maybe it was fixed already?

Actions #4

Updated by Peter Amstutz almost 5 years ago

  • Status changed from New to Closed
Actions #5

Updated by Ward Vandewege over 3 years ago

  • Related to Bug #17738: [ruby] sudden gem load errors on ubuntu 18.04 (ruby 2.5.1) added
Actions

Also available in: Atom PDF