pulkit created this revision. Herald added a subscriber: mercurial-devel. Herald added a reviewer: hg-reviewers.
REVISION SUMMARY Passing canonical=True to cbor.dump() will help in writing the data deterministically. This will sort all the sets and dicts before writing to the file. Thanks indygreg for recommending to use it. REPOSITORY rHG Mercurial REVISION DETAIL https://phab.mercurial-scm.org/D3578 AFFECTED FILES mercurial/state.py CHANGE DETAILS diff --git a/mercurial/state.py b/mercurial/state.py --- a/mercurial/state.py +++ b/mercurial/state.py @@ -57,7 +57,7 @@ we use third-party library cbor to serialize data to write in the file. """ with self._repo.vfs(self.fname, 'wb', atomictemp=True) as fp: - cbor.dump(self.opts, fp) + cbor.dump(self.opts, fp, canonical=True) def _read(self): """reads the state file and returns a dictionary which contain To: pulkit, #hg-reviewers Cc: mercurial-devel _______________________________________________ Mercurial-devel mailing list Mercurial-devel@mercurial-scm.org https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel