# HG changeset patch # User Pierre-Yves David # Date 1565190888 -7200 # Node ID 389233789952842d7529d4c409c9ea22882c295c # Parent 0a4303c77637d2421ea26ea9832e4cbc054eaf67 revlog: split a `_revisiondata` method to file `revision` job We are about to introduce more public method to access revision data (eg: `rawdata`). revset subclass tend to recursively call `revision` which will create all kind of issue with the coming series. To avoid them we introduce an explicit difference between the internal call and the public all. This will be useful for later work anyway (so the subclass issue is just moving it earlier in the series). I am not sure if the subclass are actually doing something sensible. However, I am certain I don't want to be rabbit holed into figuring it out right now. diff -r 0a4303c77637 -r 389233789952 mercurial/revlog.py --- a/mercurial/revlog.py Wed Jul 24 18:32:36 2019 +0530 +++ b/mercurial/revlog.py Wed Aug 07 17:14:48 2019 +0200 @@ -1651,6 +1651,9 @@ treated as raw data when applying flag transforms. 'raw' should be set to True when generating changegroups or in debug commands. """ + return self._revisiondata(nodeorrev, _df, raw=raw) + + def _revisiondata(self, nodeorrev, _df=None, raw=False): if isinstance(nodeorrev, int): rev = nodeorrev node = self.node(rev)