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

cannot load such file -- /Users/jedrek/.rvm/rubies/ruby-2.7.7/lib/ruby/gems/2.7.0/gems/bundler-2.4.19/exe/bundle (LoadError) #7005

Open
jedrekdomanski opened this issue Sep 26, 2023 · 3 comments · May be fixed by #7588
Labels

Comments

@jedrekdomanski
Copy link

jedrekdomanski commented Sep 26, 2023

Describe the problem as clearly as you can

On clean ruby 2.7.7 installed by RVM a default bundler v. 2.1.4 gem is installed. I need more recent version of the gem so I install it by running gem install bundler:2.4.19 --default. Then I try to install the gems bundle isntall and I get an error

cannot load such file -- /Users/jedrek/.rvm/rubies/ruby-2.7.7/lib/ruby/gems/2.7.0/gems/bundler-2.4.19/exe/bundle (LoadError)

I check the bundler versions and it looks like I have two versions installed both set as default gem. How can two gems be set as default? Why is the old one not unset as default automatically?

gem info bundler

*** LOCAL GEMS ***

bundler (2.4.19, 2.1.4)
    Authors: André Arko, Samuel Giddins, Colby Swandale, Hiroshi
    Shibata, David Rodríguez, Grey Baker, Stephanie Morillo, Chris
    Morris, James Wen, Tim Moore, André Medeiros, Jessica Lynn Suttles,
    Terence Lee, Carl Lerche, Yehuda Katz
    Homepage: https://bundler.io
    License: MIT
    Installed at (2.4.19, default): /Users/jedrek/.rvm/rubies/ruby-2.7.7/lib/ruby/gems/2.7.0
                 (2.1.4, default): /Users/jedrek/.rvm/rubies/ruby-2.7.7/lib/ruby/gems/2.7.0

Did you try upgrading RubyGems?

Yes, but it failed

gem update --system
ERROR:  While executing gem ... (Gem::RemoteFetcher::FetchError)
    bad response Forbidden 403 (https://jedrekdomanski:REDACTED@rubygems.pkg.github.com/REDACTED/specs.4.8.gz)

Post steps to reproduce the problem

Which command did you run?

What were you expecting to happen?

What actually happened?

Run gem env and paste the output below

@hsbt
Copy link
Member

hsbt commented Sep 27, 2023

I need more recent version of the gem so I install it by running gem install bundler:2.4.19 --default

You don't need to add --default option for your use-case. Use just gem install bundler for recent stable version.

@duckinator
Copy link
Member

@jedrekdomanski did you ever get this sorted out?

Also, FYI, all Ruby versions before v3.0 are considered end-of-life/unmaintained. (I know sometimes people have to use old versions anyway, but I wanted to make sure you were at least aware of it.)

@jedrekdomanski
Copy link
Author

I did not find any solution and I keep using the default version that comes with Ruby.

@hsbt hsbt linked a pull request Apr 18, 2024 that will close this issue
4 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants