Skip to content
Snippets Groups Projects
Commit 92e46a06 authored by nimrod's avatar nimrod
Browse files

Set timeout for requests.

So that prospector will be happy.
parent 2270a2d4
No related branches found
No related tags found
No related merge requests found
Pipeline #3086 passed with warnings
......@@ -49,7 +49,10 @@ class CheckURL(Check):
"""Checks validaty of a URL."""
try:
response = requests.request(
self._method, self._url, allow_redirects=False
self._method,
self._url,
allow_redirects=False,
timeout=30,
)
return (
response.status_code in self._valid_codes,
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment