Skip to content

Fix blank page when a startup request fails - #3549

Draft
Ekhorn wants to merge 1 commit into
mainfrom
bugfix/blank-page-on-startup-failure
Draft

Ekhorn wants to merge 1 commit into
mainfrom
bugfix/blank-page-on-startup-failure

Conversation

@Ekhorn

@Ekhorn Ekhorn commented Nov 6, 2026

Copy link
Copy Markdown
Contributor

Description

Relates to #3526

The manager could stay on a blank page when a request failed during startup, for example while the backend restarts. It stayed blank after the backend was back, until a reload:

  • The app config fetch had no catch, so on a network error OrApp was never added to the page.
  • loadManagerInfo parsed the response inside the XHR load listener. An HTML error page, such as a proxy's 503, threw there, so Manager.init never settled.

A backend restart triggers this more often than expected. The UI files only carry Last-Modified, so a new tab loads index.html and the bundle from the browser cache and starts the app while the API is still down.

Both cases were reproduced in Chromium on a staging server running main, by failing these requests in the browser.

Reproduction

  1. In Chrome DevTools, open Request conditions, enable blocking and throttling, and add the full URL https://<host>/api/master/configuration/manager.
  2. Reload. Without this PR the page stays blank, and the console only shows Failed to fetch. With it, the login page loads.

Changelog

  • Fall back to the default app config when the manager app's config fetch fails
  • Reject in loadManagerInfo when the info response isn't JSON, so initialization continues
  • Add app tests that fail each request and expect the login page

Checklist

  • 1. Acceptance criteria of the linked issue(s) are met
  • 2. Tests are written and all tests pass
  • 3. Changes are manually tested by you and the reviewer
  • 4. Documentation is written or updated

A network error on the manager app config fetch left OrApp off the page,
and an info response that isn't JSON left Manager.init waiting forever.
Fall back to the default config, and reject on a response that isn't JSON.
@Ekhorn Ekhorn self-assigned this Nov 6, 2026
@Ekhorn Ekhorn added the Bug Error or issue in the system label Nov 6, 2026
@sonarqubecloud

sonarqubecloud Bot commented Nov 6, 2026

Copy link
Copy Markdown

@Ekhorn

Ekhorn commented Nov 6, 2026 •

Copy link
Copy Markdown
Contributor Author

We discussed we want to show a loading spinner after an initial request failure or when it takes several seconds to load. If it fails we want exponential backoff and after ~30-60s we want to show something like "could not load app, try again later".

This branch has not been deployed

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

Labels

Bug Error or issue in the system

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant