Skip to content

Commit d8ff979

Browse files
committed
fix an issue on initial sync that doesn't know to include intermediate gems
1 parent 0def57b commit d8ff979

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

lib/bundler/multilock.rb

+8
Original file line numberDiff line numberDiff line change
@@ -512,6 +512,14 @@ def write_lockfile(lockfile_definition,
512512
previous_ui_level = Bundler.ui.level
513513
Bundler.ui.level = "warn"
514514
begin
515+
# force a remote resolution if intermediate gems are missing
516+
if definition.instance_variable_get(:@locked_spec_with_missing_deps) ||
517+
definition.instance_variable_get(:@locked_spec_with_invalid_deps) ||
518+
definition.instance_variable_get(:@missing_lockfile_dep) ||
519+
definition.instance_variable_get(:@invalid_lockfile_dep)
520+
raise SolveFailure
521+
end
522+
515523
# this is a horrible hack, to fix what I consider to be a Bundler bug.
516524
# basically, if you have multiple platform specific gems in your
517525
# lockfile, and that gem gets unlocked, Bundler will only search

0 commit comments

Comments
 (0)