diff options
| author | David RodrÃguez <deivid.rodriguez@riseup.net> | 2025-02-11 14:03:02 +0100 |
|---|---|---|
| committer | Hiroshi SHIBATA <hsbt@ruby-lang.org> | 2025-02-14 16:13:27 +0900 |
| commit | e59c90118e893fae3f37ca629291f37e26de48f4 (patch) | |
| tree | a9722228cce6c1c25919ca7af2a8ef1a4ff457cc /lib | |
| parent | e11401f799aa9343362a37157de6fbfc1836674d (diff) | |
[rubygems/rubygems] Raise error when lockfile is missing deps in frozen mode
And avoid installing any gems.
https://github.com/rubygems/rubygems/commit/c12700c7e4
Diffstat (limited to 'lib')
| -rw-r--r-- | lib/bundler/definition.rb | 2 | ||||
| -rw-r--r-- | lib/bundler/errors.rb | 4 |
2 files changed, 6 insertions, 0 deletions
diff --git a/lib/bundler/definition.rb b/lib/bundler/definition.rb index 35f2919918..da5c344354 100644 --- a/lib/bundler/definition.rb +++ b/lib/bundler/definition.rb @@ -638,6 +638,8 @@ module Bundler specs = begin resolve.materialize(dependencies) rescue IncorrectLockfileDependencies => e + raise if Bundler.frozen_bundle? + spec = e.spec raise "Infinite loop while fixing lockfile dependencies" if incorrect_spec == spec diff --git a/lib/bundler/errors.rb b/lib/bundler/errors.rb index 3fa90c5eb8..9d3d89ffeb 100644 --- a/lib/bundler/errors.rb +++ b/lib/bundler/errors.rb @@ -254,6 +254,10 @@ module Bundler @spec = spec end + def message + "Bundler found incorrect dependencies in the lockfile for #{spec.full_name}" + end + status_code(41) end end |
