[Bug]: Mobile Codex sign-out drops the warning when remote revocation is unconfirmed

Aperta Adatta ai principianti
#47,418 0 commenti 0 reazioni 0 assegnatari Vedi su GitHub

I maintainer di solito rispondono entro 1 giorno

@maxwellyoung ci sta già lavorando.

Dal 3/12/2026.

  • #47981 di @maxwellyoung — aperta

Valutazione

Difficoltà
2/5
Tempo stimato
1-3 ore
Idoneità per principianti
82/100
Tipo di issue
Bug
Chiarezza
Specificata chiaramente
Stato di attività
Attiva
Stack tecnologico
react-native, typescript

Direzione di ricerca

Inizia in apps/mobile/src/features/settings/SettingsProviderAccountsRouteScreen.tsx, soprattutto nel selettore dello stato intorno alle righe 263–271, e confronta la gestione dello stato inattivo con l’avviso Codex sul Web in apps/web/src/components/settings/CodexSetupSection.tsx. Aggiungi o aggiorna i test del componente per la disconnessione ordinaria e la disconnessione con un avviso di inattività; il lavoro è terminato quando l’avviso è visibile dopo la disconnessione locale e la normale disconnessione riuscita continua a mostrare lo stato normale.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

Summary

At be0e8a5f1658a9e40fa1ebdd41c8b413fa0492d1, a successful local Codex sign-out can carry a warning that the user still needs to disconnect the app in ChatGPT Settings. The shared auth flow preserves that warning in its idle state. Mobile provider settings discard it when choosing the status text. Web Codex settings recognize and display it. apps/server/src/provider/CodexChatGptAuth.ts:899-904 packages/provider-core/src/server/providerAuthFlow.ts:491-510 apps/web/src/components/settings/CodexSetupSection.tsx:842-847 apps/web/src/components/settings/CodexSetupSection.tsx:1105-1108

Relevant Code

The mobile command handler returns success as soon as the command succeeds. The status selector only uses the server message when the flow is active, failed or cancelled. apps/mobile/src/features/settings/SettingsProviderAccountsRouteScreen.tsx:200-217

Source excerpt apps/mobile/src/features/settings/SettingsProviderAccountsRouteScreen.tsx:263-271

  const status =
    active || state?.phase === "failed" || state?.phase === "cancelled"
      ? state.message
      : !provider.enabled
        ? gt("Turned off")
        : signedIn
          ? gt("Signed in")
          : isDiscovering
            ? gt("Discovering sign-in methods…")

The web screen already identifies the same idle-state warning.

Source excerpt apps/web/src/components/settings/CodexSetupSection.tsx:842-848

  const logoutWarning =
    auth?.phase === "idle" && auth.message?.startsWith("Signed out locally.") ? auth.message : null;

  if (presentation === "onboarding") {
    const setupError =
      logoutWarning ??
      error ??
Minimal Reproduction
  1. In a component test, supply the mobile Codex account screen with an enabled, installed provider and a signed-out account. Have the logout fixture return the server’s idle state carrying “Signed out locally. Remote revocation could not be confirmed. Disconnect the app in ChatGPT Settings.”
  2. Complete the sign-out action and read the status text. This fixture requires no provider account or network call.
  3. Expected: The screen shows the local sign-out confirmation and the instruction to disconnect the app.
  4. Actual from source inspection: The command succeeds and the status selector falls through to the ordinary provider status. The revocation instruction is absent.
Suggested Fix

Preserve the idle logout warning in mobile provider settings, using the same condition as the web Codex screen or a shared predicate. Cover both an ordinary successful logout and a successful local logout that carries the warning.


Pinned source review and scope: audit snapshot.

Lingua principale
TypeScript
Stelle
24.8k
Fork
6.4k
Merge medio
2h 25m
PR unite (30g)
519

Preparare l'ambiente

Apri in Codespaces

Avvia il container di sviluppo del progetto nel browser, con il tuo account GitHub.

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di pingdotgg/t3code

Tutte le issue di pingdotgg/t3code

Issue simili

Altre issue su TypeScript

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.