-
-
Notifications
You must be signed in to change notification settings - Fork 12.4k
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
rbenv 1.2.0 #86043
rbenv 1.2.0 #86043
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This isn't necessary -- the failure is because the test
block assumes that the bottles have been built with the workaround, but they haven't.
Formula/rbenv.rb
Outdated
@@ -58,7 +56,6 @@ def install | |||
|
|||
# Test rehash. | |||
system "rbenv", "rehash" | |||
refute_match "Cellar", (rbenv_root/"shims/foo").read |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We can just comment this out for now and CI jobs will pass.
@carlocab See my comment above about bottles. Let's say that we rebuild the rbenv bottle—wouldn't it be dangerous to hardcode the local |
Keg relocation will take care of that. See https://github.com/Homebrew/brew/blob/3.2.13/Library/Homebrew/keg_relocate.rb. |
@carlocab Ah, thanks for explaining! Then this doesn't have to be reverted. As for the failing test; could we just keep the original test and bump up the revision of the formula to force re-bottling? |
Yeah this should have received new bottles IMO. I get the argument that the issue will only happen on the next version bump, but equally it is affecting people setting up their environments now for when the bump happens in the future so we're just increasing the number of people affected by delaying it. |
8731c4e
to
ca859a3
Compare
I've modified this PR to upgrade to rbenv 1.2.0 which isn't susceptible to the rehash problem across Homebrew upgrades. rbenv/rbenv#1350 Please re-review! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @mislav!
🤖 A scheduled task has triggered a merge. |
Oops. Forgot to remove the |
The workaround was meant to hardcode the path to
rbenv
executable to prevent rbenv itself detecting the path to its executable and finding it under/usr/local/Cellar/rbenv/VERSION/libexec/...
, which is a path we cannot rely on in the long term due to Homebrew's automatic cleanup.However, the workaround is brittle:
opt_bin/"rbenv"
makes it into a bottle, it's not guaranteed to match theopt/bin
path on someone else's system. Such bottles would not be portable.Reverts #75996 /cc @steinybot
I might try to come up with a permanent solution for this from within rbenv itself.