Skip to content

Set a timeout for release branch metadata requests - #838

Open
pablogsal wants to merge 2 commits into
python:mainfrom
pablogsal:fix-dashboard-branch-timeout
Open

pablogsal wants to merge 2 commits into
python:mainfrom
pablogsal:fix-dashboard-branch-timeout

Conversation

@pablogsal

@pablogsal pablogsal commented Nov 20, 2026 •

Copy link
Copy Markdown
Member

The dashboard fetches release data without a timeout, which I found during review of the failed refresh below. Limit the request to two seconds and reuse the previous branch data if it fails. Return 503 when no branch data exists yet so the caller can retry.

[20/Nov/2026:13:50:26 +0000] "HEAD /plugins/wsgi_dashboards/release_status/index.html?refresh=true HTTP/1.1" 499 0

@pablogsal

Copy link
Copy Markdown
Member Author

CC @zware

Comment thread master/custom/release_dashboard.py Outdated

def _refresh_branch_info(self):
with urllib.request.urlopen(BRANCHES_URL) as file:
with urllib.request.urlopen(BRANCHES_URL, timeout=10) as file:

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This seems excessive; I'd be surprised if a real request with no external issues took more than 1s :). What happens if we hit timeout?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants