diff options
author | David RodrÃguez <[email protected]> | 2024-10-02 17:50:53 +0200 |
---|---|---|
committer | git <[email protected]> | 2024-11-06 13:16:57 +0000 |
commit | 54f6b787e34c517932def7a6e52c7958281129dd (patch) | |
tree | 73f791395a402967e8f454009dc729bb48e85232 /lib/bundler/lazy_specification.rb | |
parent | a4938e5bc03440ed6db87d20f9c923817af60b62 (diff) |
[rubygems/rubygems] Automatically fix lockfile when the API reveals missing deps
https://github.com/rubygems/rubygems/commit/92196ccfdb
Diffstat (limited to 'lib/bundler/lazy_specification.rb')
-rw-r--r-- | lib/bundler/lazy_specification.rb | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/lib/bundler/lazy_specification.rb b/lib/bundler/lazy_specification.rb index 170305ed15..42d68787b0 100644 --- a/lib/bundler/lazy_specification.rb +++ b/lib/bundler/lazy_specification.rb @@ -136,8 +136,12 @@ module Bundler end if search.nil? && fallback_to_non_installable search = candidates.last - elsif search && search.full_name == full_name && (search.is_a?(RemoteSpecification) || search.instance_of?(EndpointSpecification)) - search.dependencies = dependencies + elsif search && search.full_name == full_name + if search.is_a?(StubSpecification) + search.dependencies = dependencies + elsif !source.is_a?(Source::Path) && search.runtime_dependencies.sort != dependencies.sort + raise IncorrectLockfileDependencies.new(self) + end end search end |