W dniu pon, 06.11.2017 o godzinie 08∶44 -0800, użytkownik Zac Medico napisał: > On 11/06/2017 07:27 AM, Michał Górny wrote: > > @@ -148,15 +147,21 @@ class Manifest(object): > > self.pkgdir = _unicode_decode(pkgdir).rstrip(os.sep) + os.sep > > self.fhashdict = {} > > self.hashes = set() > > + self.required_hashes = set() > > > > if hashes is None: > > hashes = MANIFEST2_HASH_DEFAULTS > > + if required_hashes is None: > > + required_hashes = hashes > > > > self.hashes.update(hashes) > > self.hashes.difference_update(hashname for hashname in \ > > list(self.hashes) if hashname not in > > get_valid_checksum_keys()) > > self.hashes.add("size") > > - self.hashes.add(MANIFEST2_REQUIRED_HASH) > > + > > + self.required_hashes.update(required_hashes) > > + self.required_hashes.intersection_update(self.hashes) > > + > > Requiring that presence of digests for all manifest-hashes can be > problematic, because when we extend manifest-hashes it means that nobody > can regenerate a particular manifest without fetching *all* distfiles > referenced in the Manifest. It's much more friendly if we generate the > missing digests when the distfiles happen to be available in DISTDIR, > which is how the portage currently behaves.
This doesn't change. The intersection only strips away hashes that are not in 'self.hashes'. -- Best regards, Michał Górny