Skip to content

Commit

Permalink
Added missing request timeout
Browse files Browse the repository at this point in the history
Line 114. Best practice to declare timeout on all requests.
  • Loading branch information
salewis38 authored Sep 21, 2023
1 parent 2ee02ca commit 974e2e1
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion palm_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,7 @@ def get_latest_data(self):
}

try:
resp = requests.request('GET', url, headers=headers)
resp = requests.request('GET', url, headers=headers, timeout=10)
except requests.exceptions.RequestException as error:
logger.error(error)
return
Expand Down

0 comments on commit 974e2e1

Please sign in to comment.