[Updated] D12366: pycompat: add return type annotations
Alphare (Raphaël Gomès)
phabricator at mercurial-scm.org
Mon Mar 14 10:15:07 UTC 2022
This revision now requires changes to proceed.
Alphare added inline comments.
Alphare requested changes to this revision.
INLINE COMMENTS
> profiling.py:275
> if self._output == b'blackbox':
> + # We always use io.BytesIO if self._output == b"blackbox". But
> + # pytype doesn't realize this and thinks we're attempting to
I think we should instead add an `assert` that `self._fp` is the right type, which would satisfy Pytype without disabling it and be more regression-proof.
REPOSITORY
rHG Mercurial
CHANGES SINCE LAST ACTION
https://phab.mercurial-scm.org/D12366/new/
REVISION DETAIL
https://phab.mercurial-scm.org/D12366
To: indygreg, #hg-reviewers, Alphare
Cc: Alphare, mercurial-patches
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mercurial-scm.org/pipermail/mercurial-patches/attachments/20220314/8bd741f5/attachment-0002.html>
More information about the Mercurial-patches
mailing list