# HG changeset patch # User Pierre-Yves David # Date 1695157769 -7200 # Node ID 2734347480513065abee328a3c931fd328e844aa # Parent 4ea606568f618984ea8bfe39a2696a8691de7b51 revlog: document the `get_streams` method A small docstring does not hurt. diff -r 4ea606568f61 -r 273434748051 mercurial/revlog.py --- a/mercurial/revlog.py Tue Sep 19 22:52:54 2023 +0200 +++ b/mercurial/revlog.py Tue Sep 19 23:09:29 2023 +0200 @@ -517,6 +517,22 @@ return b'' def get_streams(self, max_linkrev, force_inline=False): + """return a list of streams that represent this revlog + + This is used by stream-clone to do bytes to bytes copies of a repository. + + This streams data for all revisions that refer to a changelog revision up + to `max_linkrev`. + + If `force_inline` is set, it enforces that the stream will represent an inline revlog. + + It returns is a list of three-tuple: + + [ + (filename, bytes_stream, stream_size), + … + ] + """ n = len(self) index = self.index while n > 0: