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

Braintree library errors on Ruby 3.4 due to missing dependencies #250

Open
zorab47 opened this issue Jan 31, 2025 · 0 comments
Open

Braintree library errors on Ruby 3.4 due to missing dependencies #250

zorab47 opened this issue Jan 31, 2025 · 0 comments

Comments

@zorab47
Copy link

zorab47 commented Jan 31, 2025

General information

  • SDK/Library version: 4.25
  • Environment: Sandbox and Production
  • Language, language version, and OS: Ruby 3.4.x

Issue description

Related: #247

Loading the braintree Ruby gem errors when loading on Ruby 3.4 due to missing dependencies:

  • base64
  • bigdecimal
❯ ruby -v
ruby 3.4.1 (2024-12-25 revision 48d4efcb85) +PRISM [x86_64-darwin23]

❯ ruby braintree_ruby_dependency_errors.rb
/Users/$HOME/.gem/ruby/3.4.1/gems/braintree-4.25.0/lib/braintree.rb:1: warning: base64 was loaded from the standard library, but is not part of the default gems starting from Ruby 3.4.0.
You can add base64 to your Gemfile or gemspec to silence this warning.
/Users/$HOME/.rubies/ruby-3.4.1/lib/ruby/3.4.0/bundled_gems.rb:82:in 'Kernel.require': cannot load such file -- base64 (LoadError)
        from /Users/$HOME/.rubies/ruby-3.4.1/lib/ruby/3.4.0/bundled_gems.rb:82:in 'block (2 levels) in Kernel#replace_require'
        from /Users/$HOME/.gem/ruby/3.4.1/gems/braintree-4.25.0/lib/braintree.rb:1:in '<top (required)>'
        from /Users/$HOME/.rubies/ruby-3.4.1/lib/ruby/3.4.0/bundled_gems.rb:82:in 'Kernel.require'
        from /Users/$HOME/.rubies/ruby-3.4.1/lib/ruby/3.4.0/bundled_gems.rb:82:in 'block (2 levels) in Kernel#replace_require'
        from braintree_ruby_dependency_errors.rb:8:in '<main>'

You can reproduce by running the following with Ruby 3.4:

require 'bundler/inline'

gemfile do
  source 'https://rubygems.org'
  gem 'braintree', require: false
end

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

No branches or pull requests

1 participant