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

Fix some cases of running bundler on a path including brackets #3854

Merged
merged 4 commits into from Oct 1, 2020

Conversation

deivid-rodriguez
Copy link
Member

@deivid-rodriguez deivid-rodriguez commented Jul 24, 2020

Description:

I used a a monkey patch of Gem::Util.glob_files_in_dir that supports brackets. Something like this will be built in once https://bugs.ruby-lang.org/issues/8258 is implemented, although to base: option of Dir.glob already handles this fine. So once ruby 2.5 is the minimum support ruby, the monkeypatch can be dropped.

Fixes #3841.

Tasks:

  • Describe the problem / feature
  • Write tests
  • Write code to solve the problem
  • Get code review from coworkers / friends

I will abide by the code of conduct.

The test passes on 9.2.9.0, breaks on 9.2.10, and passes again on
9.2.11.1.

Crash is like the following:

```
LoadError: no such file to load -- bundler/shared_helpers
  require at org/jruby/RubyKernel.java:974
  require at uri:classloader:/META-INF/jruby.home/lib/ruby/stdlib/rubygems/core_ext/kernel_require.rb:54
   <main> at uri:classloader:/META-INF/init.rb:21
  require at org/jruby/RubyKernel.java:974
  require at uri:classloader:/META-INF/jruby.home/lib/ruby/stdlib/rubygems/core_ext/kernel_require.rb:54
   <main> at <script>:2
ERROR: org.jruby.embed.EvalFailedException: (LoadError) no such file to load -- bundler/shared_helpers
```

It happens against the current default branch, and I don't know why it
happens.

Whatever it was, it seems fixed in jruby-9.2.11.1, so let's forget about
it.
@deivid-rodriguez deivid-rodriguez merged commit 9860c26 into master Oct 1, 2020
@deivid-rodriguez deivid-rodriguez deleted the brackets branch October 1, 2020 11:02
deivid-rodriguez added a commit that referenced this pull request Oct 5, 2020
Fix some cases of running `bundler` on a path including brackets

(cherry picked from commit 9860c26)
deivid-rodriguez added a commit that referenced this pull request Oct 5, 2020
Fix some cases of running `bundler` on a path including brackets

(cherry picked from commit 9860c26)
deivid-rodriguez added a commit that referenced this pull request Oct 5, 2020
Fix some cases of running `bundler` on a path including brackets

(cherry picked from commit 9860c26)
deivid-rodriguez added a commit that referenced this pull request Oct 6, 2020
Fix some cases of running `bundler` on a path including brackets

(cherry picked from commit 9860c26)
deivid-rodriguez added a commit that referenced this pull request Oct 6, 2020
Fix some cases of running `bundler` on a path including brackets

(cherry picked from commit 9860c26)
deivid-rodriguez added a commit that referenced this pull request Oct 6, 2020
Fix some cases of running `bundler` on a path including brackets

(cherry picked from commit 9860c26)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Error when a parent directory name contains an opening bracket
2 participants