Skip to content

fix(oauth): resolve Kiro login flow before blocking on manual paste#232

Merged
lidge-jun merged 1 commit into
lidge-jun:devfrom
Wibias:codex/fix-kiro-login-hang
Jul 22, 2026
Merged

fix(oauth): resolve Kiro login flow before blocking on manual paste#232
lidge-jun merged 1 commit into
lidge-jun:devfrom
Wibias:codex/fix-kiro-login-hang

Conversation

@Wibias

@Wibias Wibias commented Jul 21, 2026

Copy link
Copy Markdown
Contributor

Problem

Clicking "Login" on Kiro in the Accounts tab does nothing visible. The button changes to "Cancel" but no instructions, paste field, or browser window appears. The user is stuck with no way to complete the login.

Root cause

loginKiro() in src/oauth/kiro.ts is an import-first flow: it tries kiro-cli SQLite, then KIRO_ACCESS_TOKEN env, then falls back to ctrl.onManualCodeInput() which blocks waiting for a pasted token. But it never calls ctrl.onAuth() before blocking, so startLoginFlow() never resolves, the HTTP response is never sent, and the GUI's fetch hangs indefinitely.

The GUI sets busy state before the fetch (showing the Cancel button), but since the response never arrives, loginInfo is never populated and the paste-input field never renders.

Fix

Call ctrl.onAuth() with instructions immediately before blocking on ctrl.onManualCodeInput(). This resolves the login flow, sends the HTTP response with instructions, and the GUI renders the paste-input field so the user can enter their Kiro access token.

Verification

  • bun x tsc --noEmit passes
  • The fix is a 9-line addition to src/oauth/kiro.ts

loginKiro() called ctrl.onManualCodeInput() without first calling
ctrl.onAuth(), so startLoginFlow() never resolved and the HTTP response
never reached the GUI. The dashboard showed a Cancel button but no
instructions or paste field, leaving the user stuck.

Call ctrl.onAuth() with instructions immediately before blocking on
manual code input, so the server responds and the GUI renders the
paste-input field.
@Wibias
Wibias force-pushed the codex/fix-kiro-login-hang branch from d907092 to cec8c1a Compare July 21, 2026 22:58
@lidge-jun
lidge-jun merged commit b99bc41 into lidge-jun:dev Jul 22, 2026
7 checks passed
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