changeset 42845:f75f47b3ea41

revlog: deprecate the use of `revision(..., raw=True)` We have an official `rawdata` function now.
author Pierre-Yves David <pierre-yves.david@octobus.net>
date Mon, 02 Sep 2019 16:28:43 +0200
parents 2c74337e6483
children 01d3ce3281cf
files mercurial/revlog.py
diffstat 1 files changed, 4 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/mercurial/revlog.py	Wed Aug 28 16:01:16 2019 +0200
+++ b/mercurial/revlog.py	Mon Sep 02 16:28:43 2019 +0200
@@ -1610,6 +1610,10 @@
         treated as raw data when applying flag transforms. 'raw' should be set
         to True when generating changegroups or in debug commands.
         """
+        if raw:
+            msg = ('revlog.revision(..., raw=True) is deprecated, '
+                   'use revlog.rawdata(...)')
+            util.nouideprecwarn(msg, '5.2', stacklevel=2)
         return self._revisiondata(nodeorrev, _df, raw=raw)
 
     def _revisiondata(self, nodeorrev, _df=None, raw=False):