Skip to content
This repository was archived by the owner on Oct 12, 2022. It is now read-only.

Commit c6d1773

Browse files
Update _sync.py
1 parent d0937c5 commit c6d1773

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

openrobot/api_wrapper/_sync.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -114,7 +114,7 @@ def _request(self, method: str, url: str, **kwargs):
114114
raise TooManyRequests(r, js)
115115

116116
try:
117-
time.sleep(int(resp.headers['Retry-After']))
117+
time.sleep(int(r.headers['Retry-After']))
118118
except KeyError as e:
119119
raise KeyError('Retry-After header is not present.') from e # this probably wont trigger, but either way we still need to handle it, right?
120120

0 commit comments

Comments
 (0)