summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorThe Bundler Bot <bot@bundler.io>2017-10-29 22:41:08 +0000
committerSamuel Giddins <segiddins@segiddins.me>2017-10-30 13:56:08 -0500
commite32e9ab6d77c9d8229526f71da9d4e01a5ba2181 (patch)
treee3644b8fe91d6ea0d3b8c3af5280df47c82bb873
parentefd4dff28750f561e0bea0dcc657ea17998a7bc1 (diff)
downloadbundler-e32e9ab6d77c9d8229526f71da9d4e01a5ba2181.tar.gz
Auto merge of #6133 - bundler:seg-bundler-2-5-default-activation-fix, r=colby-swandale
Ensure that autoloads are resolved in the real working directory Fixes an issue on 2.5.0-dev where using local git overrides would cause an exception because the default bundler had been loaded ### What was the end-user problem that led to this PR? The problem was Bundler was failing 8 specs against ruby trunk. ### What was your diagnosis of the problem? My diagnosis was when the autoload for `URICredentialsFilter` fired in a `chdir` block, the default bundler gem was getting activated. ### What is your fix for the problem, implemented in this PR? My fix eagerly trips that auto-load in the git proxy. ### Why did you choose this fix out of the possible options? I chose this fix because it's a one-liner. (cherry picked from commit ccc5d6130c68c6989a2553f454d2d5d67caff025)
-rw-r--r--lib/bundler/source/git/git_proxy.rb1
1 files changed, 1 insertions, 0 deletions
diff --git a/lib/bundler/source/git/git_proxy.rb b/lib/bundler/source/git/git_proxy.rb
index 30ab5edf0d..c56dda66ea 100644
--- a/lib/bundler/source/git/git_proxy.rb
+++ b/lib/bundler/source/git/git_proxy.rb
@@ -221,6 +221,7 @@ module Bundler
def in_path(&blk)
checkout unless path.exist?
+ _ = URICredentialsFilter # load it before we chdir
SharedHelpers.chdir(path, &blk)
end