Skip to content
This repository was archived by the owner on Dec 20, 2021. It is now read-only.

Commit 2325c10

Browse files
committed
Also catch ChunkedEncodingError (triggers from retries)
1 parent 719cd85 commit 2325c10

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

vrcpy/request.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -87,7 +87,8 @@ async def call(self, path, method="GET", headers={}, params={}, json={}, no_auth
8787
try:
8888
resp = await self._call_wrap(path, method, headers, params, json, no_auth, verify)
8989
break
90-
except requests.exceptions.ConnectionError as e: # Gosh darnit VRC team, why've you done this!
90+
# Gosh darnit VRC team, why've you done this!
91+
except (requests.exceptions.ConnectionError, requests.exceptions.ChunkedEncodingError) as e:
9192
if tri == (retries or self.call_retries):
9293
raise requests.exceptions.ConnectionError(
9394
str(e) + " ({} retries)".format(retries))
@@ -209,7 +210,8 @@ def call(self, path, method="GET", headers={}, params={}, json={}, no_auth=False
209210
try:
210211
resp = self._call_wrap(path, method, headers, params, json, no_auth, verify)
211212
break
212-
except requests.exceptions.ConnectionError as e: # Gosh darnit VRC team, why've you done this!
213+
# Gosh darnit VRC team, why've you done this!
214+
except (requests.exceptions.ConnectionError, requests.exceptions.ChunkedEncodingError) as e:
213215
if tri == (retries or self.call_retries):
214216
raise requests.exceptions.ConnectionError(
215217
str(e) + " ({} retries)".format(retries))

0 commit comments

Comments
 (0)