Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Gem Load Error ruby2_keywords v0.0.3 #1240

Closed
silviusimeria opened this issue Jan 19, 2021 · 5 comments · Fixed by #1241
Closed

Gem Load Error ruby2_keywords v0.0.3 #1240

silviusimeria opened this issue Jan 19, 2021 · 5 comments · Fixed by #1241

Comments

@silviusimeria
Copy link

Basic Info

  • Faraday Version: 1.3.0
  • Ruby Version: 2.4.1

Issue description

Please provide a description of the issue you're experiencing.

  • I believe the new release on ruby2_keywords v0.0.3 breaks something and it not locked to v0.0.2 in the gemspec of faraday 1.3.0
  • ruby/ruby2_keywords@v0.0.2...v0.0.3
  • locking ruby2_keywords to v0.0.2 fixed the issue

Please also provide the exception message/stacktrace or any other useful detail.

.rvm/rubies/ruby-2.4.1/lib/ruby/site_ruby/2.4.0/bundler/runtime.rb:84:in `rescue in block (2 levels) in require': There was an error while trying to load the gem 'faraday'.
Gem Load Error is: wrong number of arguments (given 2, expected 1)
Backtrace for gem load error is:
/gems/ruby-2.4.1@myproject/gems/ruby2_keywords-0.0.3/lib/ruby2_keywords.rb:2:in `private_method_defined?'
/gems/ruby-2.4.1@myproject/gems/ruby2_keywords-0.0.3/lib/ruby2_keywords.rb:2:in `<class:Module>'
/gems/ruby-2.4.1@myproject/gems/ruby2_keywords-0.0.3/lib/ruby2_keywords.rb:1:in `<top (required)>'
/gems/ruby-2.4.1@myproject/gems/activesupport-5.1.4/lib/active_support/dependencies.rb:292:in `require'
/gems/ruby-2.4.1@myproject/gems/activesupport-5.1.4/lib/active_support/dependencies.rb:292:in `block in require'
/gems/ruby-2.4.1@myproject/gems/activesupport-5.1.4/lib/active_support/dependencies.rb:258:in `load_dependency'
/gems/ruby-2.4.1@myproject/gems/activesupport-5.1.4/lib/active_support/dependencies.rb:292:in `require'
/gems/ruby-2.4.1@myproject/gems/faraday-1.3.0/lib/faraday/rack_builder.rb:3:in `<top (required)>'
/gems/ruby-2.4.1@myproject/gems/activesupport-5.1.4/lib/active_support/dependencies.rb:292:in `require'
/gems/ruby-2.4.1@myproject/gems/activesupport-5.1.4/lib/active_support/dependencies.rb:292:in `block in require'
/gems/ruby-2.4.1@myproject/gems/activesupport-5.1.4/lib/active_support/dependencies.rb:258:in `load_dependency'
/gems/ruby-2.4.1@myproject/gems/activesupport-5.1.4/lib/active_support/dependencies.rb:292:in `require'
/gems/ruby-2.4.1@myproject/gems/faraday-1.3.0/lib/faraday.rb:20:in `<top (required)>'
/rubies/ruby-2.4.1/lib/ruby/site_ruby/2.4.0/bundler/runtime.rb:81:in `require'
/rubies/ruby-2.4.1/lib/ruby/site_ruby/2.4.0/bundler/runtime.rb:81:in `block (2 levels) in require'
/rubies/ruby-2.4.1/lib/ruby/site_ruby/2.4.0/bundler/runtime.rb:76:in `each'
/rubies/ruby-2.4.1/lib/ruby/site_ruby/2.4.0/bundler/runtime.rb:76:in `block in require'
/rubies/ruby-2.4.1/lib/ruby/site_ruby/2.4.0/bundler/runtime.rb:65:in `each'
/rubies/ruby-2.4.1/lib/ruby/site_ruby/2.4.0/bundler/runtime.rb:65:in `require'
/rubies/ruby-2.4.1/lib/ruby/site_ruby/2.4.0/bundler.rb:114:in `require'
/Users/asdf123/myproject/config/application.rb:9:in `<top (required)>'
/gems/ruby-2.4.1@myproject/gems/spring-2.0.2/lib/spring/application.rb:92:in `require'
/gems/ruby-2.4.1@myproject/gems/spring-2.0.2/lib/spring/application.rb:92:in `preload'
/gems/ruby-2.4.1@myproject/gems/spring-2.0.2/lib/spring/application.rb:153:in `serve'
/gems/ruby-2.4.1@myproject/gems/spring-2.0.2/lib/spring/application.rb:141:in `block in run'
/gems/ruby-2.4.1@myproject/gems/spring-2.0.2/lib/spring/application.rb:135:in `loop'
/gems/ruby-2.4.1@myproject/gems/spring-2.0.2/lib/spring/application.rb:135:in `run'
/gems/ruby-2.4.1@myproject/gems/spring-2.0.2/lib/spring/application/boot.rb:19:in `<top (required)>'
/rubies/ruby-2.4.1/lib/ruby/site_ruby/2.4.0/rubygems/core_ext/kernel_require.rb:59:in `require'
/rubies/ruby-2.4.1/lib/ruby/site_ruby/2.4.0/rubygems/core_ext/kernel_require.rb:59:in `require'
-e:1:in `<main>'
Bundler Error Backtrace:
 (Bundler::GemRequireError)
	from /rubies/ruby-2.4.1/lib/ruby/site_ruby/2.4.0/bundler/runtime.rb:80:in `block (2 levels) in require'
from /rubies/ruby-2.4.1/lib/ruby/site_ruby/2.4.0/bundler/runtime.rb:76:in `each'
	from /rubies/ruby-2.4.1/lib/ruby/site_ruby/2.4.0/bundler/runtime.rb:76:in `block in require'
	from /rubies/ruby-2.4.1/lib/ruby/site_ruby/2.4.0/bundler/runtime.rb:65:in `each'
from /rubies/ruby-2.4.1/lib/ruby/site_ruby/2.4.0/bundler/runtime.rb:65:in `require'
	from /rubies/ruby-2.4.1/lib/ruby/site_ruby/2.4.0/bundler.rb:114:in `require'
	from /Users/asdf123/myptoject/config/application.rb:9:in `<top (required)>'
from /gems/ruby-2.4.1@myproject/gems/spring-2.0.2/lib/spring/application.rb:92:in `require'
	from /gems/ruby-2.4.1@myproject/gems/spring-2.0.2/lib/spring/application.rb:92:in `preload'
	from /gems/ruby-2.4.1@myproject/gems/spring-2.0.2/lib/spring/application.rb:153:in `serve'
from /gems/ruby-2.4.1@myproject/gems/spring-2.0.2/lib/spring/application.rb:141:in `block in run'
	from /gems/ruby-2.4.1@myproject/gems/spring-2.0.2/lib/spring/application.rb:135:in `loop'
	from /gems/ruby-2.4.1@myproject/gems/spring-2.0.2/lib/spring/application.rb:135:in `run'
from /gems/ruby-2.4.1@myproject/gems/spring-2.0.2/lib/spring/application/boot.rb:19:in `<top (required)>'
	from /rubies/ruby-2.4.1/lib/ruby/site_ruby/2.4.0/rubygems/core_ext/kernel_require.rb:59:in `require'
	from /rubies/ruby-2.4.1/lib/ruby/site_ruby/2.4.0/rubygems/core_ext/kernel_require.rb:59:in `require'
from -e:1:in `<main>'

Steps to reproduce

Just upgrade, bundled and then tried to run the project:
  faraday (1.3.0)
      faraday-net_http (~> 1.0)
      multipart-post (>= 1.2, < 3)
      ruby2_keywords
  faraday_middleware (1.0.0)
      faraday (~> 1.0)
  ruby2_keywords (0.0.3)
@olleolleolle
Copy link
Member

olleolleolle commented Jan 19, 2021

This affects Ruby 2.5 and before.

Ruby 2.5 support not given by 0.0.3: ruby/ruby2_keywords#9 - it uses the 2-argument version of a method, the 2nd argument was introduced in 2.6.

@iMacTia
Copy link
Member

iMacTia commented Jan 19, 2021

Thanks for raising this @silviusimeria, I found a related issue in ruby2_keyword: ruby/ruby2_keywords#9

It seems you're not the only one affected and there already people working on a fix!
I'd give it a few hours to see how things pan out, if they fix the issue and push a v0.0.4, then we can avoid an extra release with just the version lock 😃

For now, should this be an issue for anyone, please lock the ruby2_keyword in your Gemfile as a temporary fix until we decide what to do here 👍

@jgillard
Copy link

v0.0.4 has been released: ruby/ruby2_keywords#10 (comment)

@iMacTia
Copy link
Member

iMacTia commented Jan 19, 2021

@silviusimeria the fix states compatibility with Ruby 2.5, but I see you're on Ruby 2.4, could you double-check and confirm if this is working for you as well now?

@silviusimeria
Copy link
Author

Seems to be working with 2.4 as well.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants