# HG changeset patch # User Pierre-Yves David # Date 1565201510 -7200 # Node ID aeb2be20b33b0cb1e46dd085d0cf153f5e9b119f # Parent 7a89b044eea4699a02212d661fea5d2337a2cde8 rawdata: update callers in storageutils We update callers incrementally because this help bisecting failures. This was useful during development, so we expect it might be useful again in the future. diff -r 7a89b044eea4 -r aeb2be20b33b mercurial/utils/storageutil.py --- a/mercurial/utils/storageutil.py Wed Aug 07 20:11:35 2019 +0200 +++ b/mercurial/utils/storageutil.py Wed Aug 07 20:11:50 2019 +0200 @@ -304,9 +304,9 @@ ``rawsizefn`` (optional) Callable receiving a revision number and returning the length of the - ``store.revision(rev, raw=True)``. + ``store.rawdata(rev)``. - If not defined, ``len(store.revision(rev, raw=True))`` will be called. + If not defined, ``len(store.rawdata(rev))`` will be called. ``revdifffn`` (optional) Callable receiving a pair of revision numbers that returns a delta @@ -422,7 +422,7 @@ if revisiondata: if store.iscensored(baserev) or store.iscensored(rev): try: - revision = store.revision(node, raw=True) + revision = store.rawdata(node) except error.CensoredNodeError as e: revision = e.tombstone @@ -430,19 +430,18 @@ if rawsizefn: baserevisionsize = rawsizefn(baserev) else: - baserevisionsize = len(store.revision(baserev, - raw=True)) + baserevisionsize = len(store.rawdata(baserev)) elif (baserev == nullrev and deltamode != repository.CG_DELTAMODE_PREV): - revision = store.revision(node, raw=True) + revision = store.rawdata(node) available.add(rev) else: if revdifffn: delta = revdifffn(baserev, rev) else: - delta = mdiff.textdiff(store.revision(baserev, raw=True), - store.revision(rev, raw=True)) + delta = mdiff.textdiff(store.rawdata(baserev), + store.rawdata(rev)) available.add(rev)