Skip to content

Commit 8c346c2

Browse files
authored
Merge pull request #125 from superannotateai/develop
Develop
2 parents 0bf1cdc + 5a2dccb commit 8c346c2

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

43 files changed

+626
-620
lines changed

pytest.ini

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
[pytest]
2-
timeout = 300
2+
timeout = 600
33
timeout_method=thread

superannotate/api.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
import json
33
import logging
44
import sys
5+
import time
56
from pathlib import Path
67

78
import requests
@@ -137,7 +138,6 @@ def send_request(self, req_type, path, params=None, json_req=None):
137138
for key, value in params.items():
138139
if isinstance(value, str):
139140
params[key] = value.replace("\\", "\\\\")
140-
141141
req = requests.Request(
142142
method=req_type, url=url, json=json_req, params=params
143143
)
@@ -153,11 +153,11 @@ def _create_session(self):
153153
total=5,
154154
read=5,
155155
connect=5,
156-
backoff_factor=0.3,
156+
backoff_factor=2,
157157
# use on any request type
158158
method_whitelist=False,
159159
# force retry on those status responses
160-
status_forcelist=(501, 502, 503, 504, 505, 506, 507, 508, 510, 511),
160+
status_forcelist=(501, 502, 503, 504, 505, 506, 507, 508, 510, 511, 403, 400),
161161
raise_on_status=False
162162
)
163163
adapter = requests.adapters.HTTPAdapter(

0 commit comments

Comments
 (0)