Comments (30)
Same here. If there's a patch/workaround I'll apply it to the Homebrew formula.
from rbenv-bundler.
Reinstalling rbenv-bundler seems to have fixed the issue. @MikeMcQuaid can you confirm?
from rbenv-bundler.
Doesn't seem to for me; I get an infinite loop where it says my Ruby version isn't installed (it is). Wonder if the problem is that I've installed rbenv
and rbenv-bundler
from Homebrew?
from rbenv-bundler.
Actually I can reproduce yours as well - I have both installed using homebrew too. Somehow I thought it worked. I guess not. It actually spins some rehash processes that never terminate. For now I guess best is to disable rbenv bundler off
or uninstall.
from rbenv-bundler.
All, I have some questions:
- Was it working for 0.3.0?
- What happens if you disable Homebrew and install rbenv into
~/.rbenv
and clone in rbenv-bundler? - Are you sure that the previous versions of rbenv and rbenv-bundler have been cleaned thoroughly? I still remember losing 2 hours of my life helping a coworker who thought he had removed the Homebrew-based rbenv, when in reality it left debris in
/usr/local/share
. - Please make sure that you remove all metadata files in
${rbenv_bundler_root}/share/rbenv/bundler
.
from rbenv-bundler.
@carsomyr Some answers:
- Yes.
2, 3, 4. I'll give it a try and post back here.
from rbenv-bundler.
Also I've commit access to Homebrew so if rbenv
and rbenv-bundler
are doing anything odd I can fix that.
from rbenv-bundler.
All, I just tried this in a clean Homebrew environment for myself, and everything seems to be in order. I'm closing the issue for now; please make sure that you do item 4.
from rbenv-bundler.
Never mind, I backtrack, as I am getting the error, too.
from rbenv-bundler.
Also, are you guys sure that rbenv rehash
results in processes that never terminate?
from rbenv-bundler.
@carsomyr no, not 100%, let me know if I can add some checks - I only see rehash processes that never terminate when if have rbenv bundler on
, so that's quite positive.
from rbenv-bundler.
@kenips Could you insert a puts
into the control flow of the rehash.rb
script? Does it print endlessly?
from rbenv-bundler.
All, please update to 0.95 and let me how it goes. I believe that the ensure_capable_ruby
problem should be fixed. Not so sure about the infinite looping.
from rbenv-bundler.
Seems fixed here and upgrade the Homebrew formula. Thanks!
from rbenv-bundler.
Closing for now.
from rbenv-bundler.
@carsomyr just installed 1.9.3-p374, seems like it's coming back:
/usr/local/Cellar/rbenv-bundler/0.95/etc/rbenv.d/bundler/rehash.rb:342:in `ensure_capable_ruby': Could not locate a Ruby capable of running this script (RuntimeError)
from /usr/local/Cellar/rbenv-bundler/0.95/etc/rbenv.d/bundler/rehash.rb:409
/usr/local/opt/rbenv/plugins/rbenv-bundler/etc/rbenv.d/bundler/rehash.rb:342:in `ensure_capable_ruby': Could not locate a Ruby capable of running this script (RuntimeError)
from /usr/local/opt/rbenv/plugins/rbenv-bundler/etc/rbenv.d/bundler/rehash.rb:409
/usr/local/Cellar/rbenv-bundler/0.95/etc/rbenv.d/bundler/rehash.rb:342:in `ensure_capable_ruby': Could not locate a Ruby capable of running this script (RuntimeError)
from /usr/local/Cellar/rbenv-bundler/0.95/etc/rbenv.d/bundler/rehash.rb:409
/usr/local/opt/rbenv/plugins/rbenv-bundler/etc/rbenv.d/bundler/rehash.rb:342:in `ensure_capable_ruby': Could not locate a Ruby capable of running this script (RuntimeError)
from /usr/local/opt/rbenv/plugins/rbenv-bundler/etc/rbenv.d/bundler/rehash.rb:409
from rbenv-bundler.
@jugnooken What if you delete the files in ${plugin_root}/share/rbenv/bundler
? Better yet, are you able to dump ruby_profiles.yml
before you proceed? I would like to see its contents.
from rbenv-bundler.
Seems to have fixed it - not sure how ruby_profiles.yml
got into this state but after it regenerates ruby_version
is now matching installed versions.
Before delete:
---
system: !ruby/object:OpenStruct
table:
:ruby_version:
- 1
- 8
- 7
:gem_ruby_engine: ruby
:gem_ruby_version: "1.8"
:gem_dir: !ruby/object:Pathname
path: /Library/Ruby/Gems/1.8
1.9.3-p374: !ruby/object:OpenStruct
table:
:ruby_version:
- 1
- 8
- 7
:gem_ruby_engine: ruby
:gem_ruby_version: "1.8"
:gem_dir: !ruby/object:Pathname
path: /Library/Ruby/Gems/1.8
1.9.3-p362: !ruby/object:OpenStruct
table:
:ruby_version:
- 1
- 8
- 7
:gem_ruby_engine: ruby
:gem_ruby_version: "1.8"
:gem_dir: !ruby/object:Pathname
path: /Library/Ruby/Gems/1.8
After delete:
---
1.9.3-p362: !ruby/object:OpenStruct
table:
:ruby_version:
- 1
- 9
- 3
:gem_dir: !ruby/object:Pathname
path: /usr/local/opt/rbenv/versions/1.9.3-p362/gemsets/3211
:gem_ruby_engine: ruby
:gem_ruby_version: 1.9.1
1.9.3-p374: !ruby/object:OpenStruct
table:
:ruby_version:
- 1
- 9
- 3
:gem_dir: !ruby/object:Pathname
path: /usr/local/opt/rbenv/versions/1.9.3-p374/gemsets/3211
:gem_ruby_engine: ruby
:gem_ruby_version: 1.9.1
system: !ruby/object:OpenStruct
table:
:ruby_version:
- 1
- 8
- 7
:gem_dir: !ruby/object:Pathname
path: /3211
:gem_ruby_engine: ruby
:gem_ruby_version: '1.8'
Do you force regenerate this file somewhere?
from rbenv-bundler.
@jugnooken I am beginning to suspect that it's this line.
from rbenv-bundler.
First in path for me is /usr/local/opt/rbenv/libexec
. Is that what you're expecting?
Before:
/usr/local/opt/rbenv/libexec:
/usr/local/opt/rbenv/plugins/rbenv-bundler/bin:
/usr/local/opt/rbenv/plugins/ruby-build/bin:
/usr/local/opt/rbenv/libexec:
/usr/local/opt/rbenv/plugins/rbenv-bundler/bin:
/usr/local/opt/rbenv/plugins/ruby-build/bin:
...
After:
/usr/local/opt/rbenv/plugins/rbenv-bundler/bin:
/usr/local/opt/rbenv/plugins/ruby-build/bin:
/usr/local/opt/rbenv/libexec:
/usr/local/opt/rbenv/plugins/rbenv-bundler/bin:
/usr/local/opt/rbenv/plugins/ruby-build/bin:
...
from rbenv-bundler.
@jugnooken As it turns out, that line I pointed out earlier is broken: It assumes that the script is running in rbenv-based Ruby, which isn't necessarily the case. As for the corrupted ruby_profiles.yml
file, can you try the following two scenarios.
Scenario 1:
- Delete it.
- Initialize your
PATH
to have${rbenv_root}/bin
at the beginning. - Do not run
eval -- "$(rbenv init -)"
. - Run
rbenv rehash
.
Scenario 2:
- Delete it.
- Ditto 2 above.
- Run
eval -- "$(rbenv init)"
. You should see${rbenv_root}/shims
added to the beginning ofPATH
. - Run
rbenv rehash
.
In scenario 1, you should see a corrupted file. In scenario 2, everything should be OK. Can you confirm? Thanks for your patience. My best guess is that somehow you were missing ${rbenv_root}/shims
on your path when the ruby_profiles.yml
file was being regenerated.
from rbenv-bundler.
You're right. Once loaded without rbenv init
I see same error as before.
from rbenv-bundler.
@jugnooken Ok, I will make the requisite fixes. Please confirm once @MikeMcQuaid propagates the changes into Homebrew. The plugin should work correctly even in absence of rbenv init -
.
from rbenv-bundler.
If you tag as 0.4.1 I'll update the Homebrew formula.
from rbenv-bundler.
@jugnooken @MikeMcQuaid I believe that this issue is fixed, along with another serious bug. See 66463ee and 555f418 for details. The 0.95 tag has been updated.
from rbenv-bundler.
Please don't update tags like that; tags are meant to be static and Homebrew uses your versioned tag as the download source. When you update the tag you break the Homebrew formula for any new users and any existing users will not receive the upgrade. I'd be grateful if you can tag 0.96 (or 0.95.1) for this reason (even if it's identical to the updated 0.95). Thanks.
from rbenv-bundler.
@MikeMcQuaid Point taken! The next releases will have minor version numbers. Thanks for complaining. For now, just update the formula to reflect the latest 0.95.
from rbenv-bundler.
Already done, thanks.
from rbenv-bundler.
@carsomyr I have the current version of this installed via homebrew and having the same problem. I tried what you suggested some posts earlier. Still having the same problem. Any advice?
from rbenv-bundler.
@bjoernhaeuser Try wiping out the metadata directory located at ~/.rbenv/plugins/bundler/share/rbenv/bundler
and rehashing.
from rbenv-bundler.
Related Issues (20)
- Please deprecate this whole project HOT 15
- Slow Shell Start Up HOT 7
- rbenv rehash #=> ruby: no such file to load -- rubygems (LoadError) HOT 19
- Bundle command search in all rubies installations in 2 environments HOT 2
- rake rbenv: bundle: command not found HOT 2
- Please make a new release. HOT 1
- Getting Bundler error message "Could not find rake-10.1.1 in any of the sources" for multiple commands HOT 6
- Unfortunately not working with rbenv 0.4.0 (command not found) HOT 1
- Unfortunately not working with rbenv 0.4.0 HOT 7
- error with "rbenv rehash" HOT 6
- support for md5 checksum on NetBSD
- md5 hash calculation in ./etc/rbenv.d/bundler/includes.sh HOT 1
- Issue created by mistake
- Schema / Groups HOT 1
- casuses rehash to crash if no Gemfile HOT 1
- Issue with psych/ostruct under Ruby 2.3 HOT 2
- Problem with binstubs when Bundler gem from local git repo
- Is this project in active maintenance? HOT 1
- Doesn't work after upgrading to Ruby 3.1 HOT 2
- RBENV-doctor warning: "rbenv-bundler is considerd harmful" HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from rbenv-bundler.