Closed by commit rHG14e374d4c9ee: linelog: be more careful about types before looking for _target attribute (authored by durin42). This revision was automatically updated to reflect the committed changes.
REPOSITORY rHG Mercurial CHANGES SINCE LAST UPDATE https://phab.mercurial-scm.org/D7271?vs=17641&id=17688 CHANGES SINCE LAST ACTION https://phab.mercurial-scm.org/D7271/new/ REVISION DETAIL https://phab.mercurial-scm.org/D7271 AFFECTED FILES mercurial/linelog.py CHANGE DETAILS diff --git a/mercurial/linelog.py b/mercurial/linelog.py --- a/mercurial/linelog.py +++ b/mercurial/linelog.py @@ -278,8 +278,14 @@ fakejge = _decodeone(buf, 0) if isinstance(fakejge, _jump): maxrev = 0 + elif isinstance(fakejge, (_jge, _jl)): + maxrev = fakejge._cmprev else: - maxrev = fakejge._cmprev + raise LineLogError( + 'Expected one of _jump, _jge, or _jl. Got %s.' + % type(fakejge).__name__ + ) + assert isinstance(fakejge, (_jump, _jge, _jl)) # help pytype numentries = fakejge._target if expected != numentries: raise LineLogError( To: durin42, #hg-reviewers, indygreg Cc: indygreg, mercurial-devel _______________________________________________ Mercurial-devel mailing list Mercurial-devel@mercurial-scm.org https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel