Mercurial > public > mercurial-scm > hg
diff mercurial/bundlecaches.py @ 52957:961900fbd67c stable
bundles: filter out unsupported requirements for non-packed1 format
stream bundle specs specify requirements, but we were ignoring this when
selecting which bundle to apply, causing spurious clone failures.
author | Julien Cristau <jcristau@mozilla.com> |
---|---|
date | Tue, 18 Feb 2025 10:33:30 +0100 |
parents | aa7f4a45d8fa |
children | 42f78c859dd1 89ab2459f62a |
line wrap: on
line diff
--- a/mercurial/bundlecaches.py Tue Feb 11 22:14:35 2025 -0500 +++ b/mercurial/bundlecaches.py Tue Feb 18 10:33:30 2025 +0100 @@ -318,10 +318,10 @@ % compression ) - # The specification for packed1 can optionally declare the data formats + # The specification for stream bundles can optionally declare the data formats # required to apply it. If we see this metadata, compare against what the # repo supports and error if the bundle isn't compatible. - if version == b'packed1' and b'requirements' in params: + if b'requirements' in params: requirements = set(cast(bytes, params[b'requirements']).split(b',')) missingreqs = requirements - requirementsmod.STREAM_FIXED_REQUIREMENTS if missingreqs: