When OIDC configuration is changed and re-initialized at runtime, the UI doesn't reflect the new state — users see stale OIDC buttons or missing login options, requiring a hard browser refresh.
Root Cause
The GetLoginOptions API response was cached in a OnceLock, computed once at server startup and never updated. The OIDC client itself uses ArcSwap for dynamic updates, but the login options endpoint returned the stale cached snapshot.
Fix
Backend: Replace the static OnceLock cache with a function that reads the current OIDC client state on each request. The oidc_client().load().is_some() check now reflects the live ArcSwap value.
Frontend: Add a 30-second polling interval to the login options query so the login page automatically picks up server-side changes without requiring a hard refresh.
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.
## 📋 Pull Request Information
**Original PR:** https://github.com/moghtech/komodo/pull/1182
**Author:** [@litlmike](https://github.com/litlmike)
**Created:** 2/8/2026
**Status:** ❌ Closed
**Base:** `main` ← **Head:** `fix-issue-1022`
---
### 📝 Commits (1)
- [`0eaf8b5`](https://github.com/moghtech/komodo/commit/0eaf8b5f01e50d3887ce92991acaf98e7da91381) fix: refresh login options when OIDC client is re-initialized
### 📊 Changes
**2 files changed** (+12 additions, -16 deletions)
<details>
<summary>View changed files</summary>
📝 `bin/core/src/api/auth.rs` (+11 -16)
📝 `frontend/src/lib/hooks.ts` (+1 -0)
</details>
### 📄 Description
## Problem
When OIDC configuration is changed and re-initialized at runtime, the UI doesn't reflect the new state — users see stale OIDC buttons or missing login options, requiring a hard browser refresh.
## Root Cause
The `GetLoginOptions` API response was cached in a `OnceLock`, computed once at server startup and never updated. The OIDC client itself uses `ArcSwap` for dynamic updates, but the login options endpoint returned the stale cached snapshot.
## Fix
**Backend:** Replace the static `OnceLock` cache with a function that reads the current OIDC client state on each request. The `oidc_client().load().is_some()` check now reflects the live `ArcSwap` value.
**Frontend:** Add a 30-second polling interval to the login options query so the login page automatically picks up server-side changes without requiring a hard refresh.
Fixes #1022
---
<sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
📋 Pull Request Information
Original PR: https://github.com/moghtech/komodo/pull/1182
Author: @litlmike
Created: 2/8/2026
Status: ❌ Closed
Base:
main← Head:fix-issue-1022📝 Commits (1)
0eaf8b5fix: refresh login options when OIDC client is re-initialized📊 Changes
2 files changed (+12 additions, -16 deletions)
View changed files
📝
bin/core/src/api/auth.rs(+11 -16)📝
frontend/src/lib/hooks.ts(+1 -0)📄 Description
Problem
When OIDC configuration is changed and re-initialized at runtime, the UI doesn't reflect the new state — users see stale OIDC buttons or missing login options, requiring a hard browser refresh.
Root Cause
The
GetLoginOptionsAPI response was cached in aOnceLock, computed once at server startup and never updated. The OIDC client itself usesArcSwapfor dynamic updates, but the login options endpoint returned the stale cached snapshot.Fix
Backend: Replace the static
OnceLockcache with a function that reads the current OIDC client state on each request. Theoidc_client().load().is_some()check now reflects the liveArcSwapvalue.Frontend: Add a 30-second polling interval to the login options query so the login page automatically picks up server-side changes without requiring a hard refresh.
Fixes #1022
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.