generated from rochacbruno/python-project-template
-
-
Notifications
You must be signed in to change notification settings - Fork 3
Open
Description
Problem
All HTTP requests in base.py are missing timeout parameters. This can cause the application to hang indefinitely if the Baserow API doesn't respond.
Affected code:
requests.get()inget_fields()(line ~85)requests.get()in_get_rows_data()(line ~145)requests.post()in_create_row()(line ~165)requests.post()in_create_rows()(line ~182)requests.patch()in_update_row()(line ~204)requests.patch()in_update_rows()(line ~221)requests.delete()in_delete_row()(line ~235)
Solution
Add timeout parameter to all requests calls:
resp = requests.get(url, headers=..., timeout=30)Best Practice
Always set timeouts on external HTTP requests to prevent hanging connections.
Ich sehe alles. Oliver.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels