type: meta

slug: grok-account-parity

base_branch: main

gate0_mode: strict

preset: cursor

land_mode: pr


type: goal

text: Finish Grok tray account parity: lifecycle UI events, tests, gates — protect roy-grok token


type: methodology

text: composer-2.5 via cursor preset; TDD; never refresh/revoke roy-grok; copy-only import stays


type: intent

text: User can manage multiple Grok accounts in systray like Codex/Claude without killing the pinned roy-grok session


type: direction

verbatim: Do not revoke current token, it can not be recovered. Save it as roy-grok and guard this token with your life.


verbatim: only the weekly usage should appear for grok — no 5h window (billing period maps to secondary)


type: task

seat: coder

tier: medium

desc: Read docs/plans/2026-07-10-grok-account-parity.md Task 1. Align GrokAuthOperation event kinds with Indicator (prompt_ready). Acceptance: TMPDIR=tmp/pytest-tmp python3 -m pytest tests/test_grok_accounts.py -q. Commit only: grok_auth_operation.py tests/test_grok_accounts.py. NEVER call auth.x.ai token endpoint on live credentials.


desc: Read docs/plans/2026-07-10-grok-account-parity.md Task 2. Indicator handles Grok prompt_ready with session=None without Codex crash path. Acceptance: import indicator + pytest provider/grok tests. Commit only: indicator.py (and related if needed).


tier: low

desc: Read docs/plans/2026-07-10-grok-account-parity.md Task 3. ruff+mypy clean on grok modules and touched files. Acceptance: pytest test_grok_accounts + ruff + mypy commands in plan. Commit only gate fixes.