Spaces:
Sleeping
Sleeping
OnlyBiggg
commited on
Commit
·
35ddb1d
1
Parent(s):
7360f4e
fix: retry get appi
Browse files
common/external/external_api.py
CHANGED
|
@@ -26,6 +26,7 @@ class API():
|
|
| 26 |
|
| 27 |
except httpx.HTTPStatusError as http_err:
|
| 28 |
## RETRY FOR 403 ERROR
|
|
|
|
| 29 |
if http_err.response.status_code == 403 or http_err.response.status_code == 401:
|
| 30 |
headers.pop("Authorization", None)
|
| 31 |
|
|
|
|
| 26 |
|
| 27 |
except httpx.HTTPStatusError as http_err:
|
| 28 |
## RETRY FOR 403 ERROR
|
| 29 |
+
print('Lỗi: ',http_err.response.status_code)
|
| 30 |
if http_err.response.status_code == 403 or http_err.response.status_code == 401:
|
| 31 |
headers.pop("Authorization", None)
|
| 32 |
|