Skip to content

Computed Issue status, status grouping and filters #29

Description

@lukemaj

Parent

#25

Outcome

Every Issue shows one computed status, and the Issues view groups and filters by it.

Acceptance criteria

Non-goals

  • Status labels or any GitHub writes; an "Approved" state from GitHub reviews; agents outside T3.

Blocked by

Required proof

  • Table-driven unit tests for every status row and the precedence between rows.
  • Live gh test for trusted vs untrusted review marks on a real commit.
  • Integrated web pass with before/after screenshots for the final PR.
  • Targeted lint and typecheck; scripts/fork-check.sh; independent review of the exact head.

Activity

  1. lukemaj commented on Sep 25, 2026

    @lukemaj
    ContributorAuthor

    Handoff: PR #36 (not merged)

    Delivered

    • Status. issueStatusOf (apps/web/src/components/issues/issueStatus.logic.ts) is a pure function that follows the Issues in Chromeria: an Issues view with computed status, linked to threads #25 table, first match wins. It writes nothing to GitHub.
    • GitHub read. The per-page GraphQL read from Browse Issues: list, filters, parent tree and side panel #27 now also returns viewer, open blockers (issueDependenciesSummary.blockedBy) and closing PRs. Each closing PR comes with state, draft, head SHA and the review/independent mark on its head. A mark counts only when the query's viewer posted it. The read makes no per-Issue calls. Cost is 3 points per 100 rows, up from 2.
    • Working now. A linked thread counts as working when it or any descendant child thread works (Sidebar: show a parent thread as working while its child threads work #31 helper).
    • Linked threads. They come from Link Issues to threads and start a thread from an Issue #28's batched threadsForIssues: at most 100 rows per read, one read per server, and only to servers that advertise issueLinks.
    • View:
      • Grouped by status, with Done and Not planned collapsed. Group by parent stays available.
      • Status and Linked filters.
      • Rows show linked threads; a click opens the thread.
      • Start thread is on rows and in the side panel, with title, URL and body.
      • Clicking a linked Issue in a thread's panel opens the Issues side panel, through the new issue route search parameter.
    • Docs. User docs updated. New feature map block issues-status, whose sharedFiles are the route and docs/user/source-control.md.

    Commands and results

    • apps/server: T3CODE_ISSUES_LIVE=1 T3_LIVE_GITHUB=1 vp test run src/issues/IssueService.live.test.ts src/issues/issueStatus.live.test.ts src/issueLinks/IssueLinks.live.test.ts: 10 passed, 1 skipped (Browse Issues: list, filters, parent tree and side panel #27's write test, which needs its fixture).
    • apps/server: vp test run src/issues/ src/issueLinks/: 45 passed, 11 skipped (the live suites).
    • apps/web: vp test run src/components/issues/ src/components/SidebarChildActivity.logic.test.ts src/components/CommandPalette.logic.test.ts: 105 passed. This includes the table tests for every row and each precedence pair, and a "no review status without marks" sweep.
    • packages/shared childThreadActivity.test.ts: 8 passed. packages/contracts issueLinks.test.ts: 5 passed.
    • tsc --noEmit -p tsconfig.json: server, web, contracts, shared and client-runtime all have 0 errors.
    • vp lint on changed files: 0 errors, no new warnings. vp fmt --check: clean. vp run knip:check: pass. scripts/fork-check.sh: OK (13 features).

    Decisions and deviations

    • An open draft PR counts as "PR open", so it can show Waiting for review. The table has no draft rule.
    • "Task branch" means a linked thread whose branch names the Issue. Branches pushed outside T3 are not seen.
    • GitHub keeps only the newest status per context. A later untrusted review/independent therefore hides a trusted one until the trusted account posts again.
    • A row's Start thread reads the Issue body on demand with one issues.detail call.
    • The side panel has no list of linked threads; rows show them.

    Unverified

    • No integrated web-client pass, so no before/after screenshots.
    • No independent review of this head.
    • Fork CI not yet observed.
  2. lukemaj commented on Sep 25, 2026

    @lukemaj
    ContributorAuthor

    Handoff update: review fixes on PR #36 (not merged)

    Review items

    1. PRs into non-default branches. Status now uses closing PRs plus the PRs of the Issue's linked threads, deduped by repository and number.
    2. Multi-environment. Thread lookups go to every server with issueLinks, and the answers are merged. A mark is trusted when its creator is the viewer of any server that listed the Issue. The server returns the creator and its own viewer.
    3. Merged PRs. They are still ignored while the Issue is open; a test documents this.
    4. Draft PRs. An open draft with nobody working reads as Paused, and with a working thread as In progress. The function, tests and user docs are updated.
    5. Performance. The view subscribes to a derived atom holding only the sorted working-thread keys.
    6. Start thread. A row's button shows a spinner while the detail read runs and ignores repeat clicks.
    7. Mixed marks. Explicit tests cover pending > success > failure.

    The status table moved to packages/contracts/src/issueStatus.ts, so the live suite checks it as well.

    Commands and results

    • apps/server: T3CODE_ISSUES_LIVE=1 T3_LIVE_GITHUB=1 vp test run src/issues/ src/issueLinks/: 55 passed, 1 skipped (Browse Issues: list, filters, parent tree and side panel #27's write test, which needs its fixture). No test-fixture/* branches remain.
    • apps/server: vp test run src/server.test.ts: 197/197. src/auth/RpcAuthorization.test.ts: pass. One subscribeServerConfig case failed once while running in parallel with that file; it passed alone and in the full file.
    • packages/contracts: vp test run src/issueStatus.test.ts src/issueLinks.test.ts: 45 passed.
    • apps/web: vp test run src/components/issues/ src/components/SidebarChildActivity.logic.test.ts src/components/CommandPalette.logic.test.ts: 81 passed.
    • packages/shared: childThreadActivity.test.ts: 8 passed.
    • tsc --noEmit -p tsconfig.json in server, web, contracts, shared and client-runtime: 0 errors.
    • vp lint on changed files: clean. vp fmt --check: clean. vp run knip:check: pass. scripts/fork-check.sh: OK.

    Deviations

    • This server's thread-linked PRs are read whether or not their thread links to an Issue on the page, capped at 50 per host, newest first.
    • The other deviations are unchanged: task branch means a linked thread's branch; the mark-suppression limit; the side panel lists no threads.

    Unverified

    • No real-client pass or screenshots.
    • No re-review of this head.
    • Fork CI not observed.
  3. lukemaj commented on Sep 25, 2026

    @lukemaj
    ContributorAuthor

    Handoff update: re-review fixes on PR #36 (not merged)

    Re-review items

    1. Candidate selection. Thread-linked PR candidates now come only from threads that link to an Issue on the host: a stored non-dismissed row in fork_thread_issue_links, or a branch that issueNumberFromBranch parses. The new IssueLinks.pullRequestsOfIssueThreads selects them.
      • No snapshot-state pre-filter: the same GraphQL read returns GitHub's real state.
      • The cap of 50 per host (newest first) stays and logs a warning when it truncates.
      • A CI test covers inclusion, exclusion and dedupe.
    2. Repository filter. A server with no matching search still reads its candidates and viewer in an aliases-only request, only when it has candidates. The live test covers it.
    3. Start thread. While one row starts a thread, every row's Start button is disabled.

    Commands and results

    • apps/server: T3CODE_ISSUES_LIVE=1 T3_LIVE_GITHUB=1 vp test run src/issues/ src/issueLinks/: 56 passed, 1 skipped (Browse Issues: list, filters, parent tree and side panel #27's write test, which needs its fixture). No test-fixture/* branches remain.
    • apps/server: src/server.test.ts 197/197. src/auth/RpcAuthorization.test.ts and src/mcp/McpHttpServer.test.ts 24/24.
    • packages/contracts: issueStatus.test.ts and issueLinks.test.ts 45 passed. apps/web issues, SidebarChildActivity and CommandPalette logic: 81 passed. packages/shared childThreadActivity.test.ts: 8 passed.
    • tsc --noEmit -p tsconfig.json in server, web, contracts, shared and client-runtime: 0 errors.
    • Lint on changed files: clean. vp fmt --check: clean. vp run knip:check: pass. scripts/fork-check.sh: OK.

    Unverified

    • No real-client pass or screenshots.
    • No re-review of this head.
    • Fork CI not observed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions