Skip to content

Commit 6a9b9a5

Browse files
committed
contest: collector: skip remotes on transient fetch errors
We are seeing DNS resolution errors on Intel CI, let's skip bad remotes, the errors look transient. While at it add a timeout to the fetch. Signed-off-by: Jakub Kicinski <kuba@kernel.org>
1 parent 08fe205 commit 6a9b9a5

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

contest/results-collector.py

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -292,7 +292,12 @@ def fetch_remote_run(fetcher, remote, run_info, remote_state):
292292

293293
def fetch_remote(fetcher, remote, seen):
294294
print("Fetching remote", remote['url'])
295-
r = requests.get(remote['url'])
295+
try:
296+
r = requests.get(remote['url'], timeout=30)
297+
except requests.exceptions.RequestException as e:
298+
print(f'WARN: Failed to fetch manifest from "{remote["name"]}": {e}')
299+
return
300+
296301
try:
297302
manifest = json.loads(r.content.decode('utf-8'))
298303
except json.decoder.JSONDecodeError:

0 commit comments

Comments
 (0)