diff options
author | Simon Sawicki <contact@grub4k.xyz> | 2023-10-15 10:54:38 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-10-15 10:54:38 +0200 |
commit | 4e38e2ae9d7380015349e6aee59c78bb3938befd (patch) | |
tree | df43cdcff861294329182a9268cff87edae375ed /yt_dlp/networking/exceptions.py | |
parent | 8a8b54523addf46dfd50ef599761a81bc22362e6 (diff) |
[rh:requests] Handle both `bytes` and `int` for `IncompleteRead.partial` (Fix 8a8b54523addf46dfd50ef599761a81bc22362e6) (#8348)
Authored by: bashonly, coletdjnz, Grub4K
Diffstat (limited to 'yt_dlp/networking/exceptions.py')
-rw-r--r-- | yt_dlp/networking/exceptions.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/yt_dlp/networking/exceptions.py b/yt_dlp/networking/exceptions.py index f58dc246e..12441901c 100644 --- a/yt_dlp/networking/exceptions.py +++ b/yt_dlp/networking/exceptions.py @@ -75,7 +75,7 @@ class HTTPError(RequestError): class IncompleteRead(TransportError): - def __init__(self, partial: int, expected: int = None, **kwargs): + def __init__(self, partial: int, expected: int | None = None, **kwargs): self.partial = partial self.expected = expected msg = f'{partial} bytes read' |