diff --git a/lib/bundler/definition.rb b/lib/bundler/definition.rb index ac3792938659..0eee193d6c68 100644 --- a/lib/bundler/definition.rb +++ b/lib/bundler/definition.rb @@ -743,7 +743,9 @@ def materialize(dependencies) loop do break if incomplete_specs.empty? - Bundler.ui.debug("The lockfile does not have all gems needed for the current platform though, Bundler will still re-resolve dependencies") + Bundler.ui.debug("The lockfile does not have all gems needed for the current platform (#{Bundler.local_platform}) though, " \ + "Bundler will still re-resolve dependencies. The following locked gems have no variant for it: " \ + "#{incomplete_specs.map(&:full_name).join(", ")}") sources.remote! reresolve_without(incomplete_specs) specs = resolve.materialize(dependencies) diff --git a/spec/runtime/platform_spec.rb b/spec/runtime/platform_spec.rb index 6d967589562d..136d0e51d6e2 100644 --- a/spec/runtime/platform_spec.rb +++ b/spec/runtime/platform_spec.rb @@ -433,7 +433,8 @@ gem "requires_platform_specific" G - expect(out).to include("lockfile does not have all gems needed for the current platform") + expect(out).to include("lockfile does not have all gems needed for the current platform (x64-mingw-ucrt)") + expect(out).to include("no variant for it: platform_specific-1.0-x86-mingw32") expect(the_bundle).to include_gem "platform_specific 1.0 x64-mingw-ucrt" end end