Skip to content

Commit

Permalink
feat: add timeout to security issue
Browse files Browse the repository at this point in the history
  • Loading branch information
Lucas Brito committed Nov 13, 2023
1 parent 8a09762 commit 105e147
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/auxiliary.py
Original file line number Diff line number Diff line change
Expand Up @@ -628,7 +628,7 @@ def get_image_from_url(url: str) -> np.ndarray:
np.ndarray: image.
"""
try:
response = requests.get(url)
response = requests.get(url, timeout=60)
except Exception as error:
raise ConnectionError(
'you need to be connected to some internet network to download the EAST model.'
Expand Down

0 comments on commit 105e147

Please sign in to comment.