GitPython icon indicating copy to clipboard operation
GitPython copied to clipboard

Archive call has the wrong ostream types

Open rakishii13 opened this issue 3 years ago • 1 comments

Hi, over here, https://github.com/gitpython-developers/GitPython/blob/main/git/repo/base.py#L1151 why is this Union[TextIO, BinaryIO] instead of IO[bytes]? As sending a temporaryfile or any file, is not in Union[TextIO, BinaryIO] and it is in IO[bytes]

rakishii13 avatar May 11 '22 16:05 rakishii13

It would help to post the underlying problem as well. Is type checking failing where it shouldn't? The runtime shouldn't be affected by the typing at all.

That said, if the typing gets better if the type is changed to something else, a PR is certainly welcome.

Byron avatar May 11 '22 23:05 Byron