Skip to content
This repository was archived by the owner on Jun 5, 2025. It is now read-only.

Commit a261db7

Browse files
committed
fix(version endpoint): add timeout to request to github API
1 parent 59ad0a7 commit a261db7

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/codegate/dashboard/dashboard.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ def fetch_latest_version() -> str:
3232
"Accept": "application/vnd.github+json",
3333
"X-GitHub-Api-Version": "2022-11-28"
3434
}
35-
response = requests.get(url, headers=headers)
35+
response = requests.get(url, headers=headers, timeout=5)
3636
response.raise_for_status()
3737
data = response.json()
3838
return data.get("tag_name", "unknown")

0 commit comments

Comments
 (0)