Skip to content

Add shared-schema TypeScript Console, API and CLI slice - #1844

Merged
JacobStephens2 merged 3 commits into
issue-1831from
issue-1839
Nov 6, 2026
Merged

JacobStephens2 merged 3 commits into
issue-1831from
issue-1839

Conversation

@JacobStephens2

@JacobStephens2 JacobStephens2 commented Nov 6, 2026 •

Copy link
Copy Markdown
Owner

Summary

console/schema.ts → runtime schemas + inferred TypeScript types
  ├── status --json / dismiss <id> [--undo] --json
  ├── GET /api/v1/status / POST /api/v1/dismiss
  ├── generated OpenAPI / console openapi
  └── embedded typed Console client → inline Dismissal and Undo

console/routes.ts → HTTP dispatch + page/CLI/scope pairing + parity test

Adds the isolated full-stack TypeScript prototype slice under Spec #1831. The diff also includes #1836's inherited Ticket prototype and affected-test routing. The Console uses separate seeded prototype state and one local bearer token; the README documents its limits and setup.

Closes #1839

Evidence

Execution evidence

  • Before: PATH="$HOME/.bun/bin:$PATH" bun test --cwd prototypes/typescript tests/console.test.ts failed the new compiled status --json test: expected empty stderr, received Invalid URL; 0 pass, 1 fail.
    After: the same command passed 4 pass, 0 fail, 61 expect() calls, including HTTP/CLI parity, required scopes, OpenAPI route parity and Playwright.

  • Final prototype validation after the review fix: PATH="$HOME/.bun/bin:$PATH" scripts/affected-tests a6b37d45 passed tsc --noEmit and all 20 Bun tests (163 assertions, 35.25s for the test command).

  • PATH="$HOME/.bun/bin:$PATH" scripts/affected-tests issue-1831: typecheck and all 20 prototype tests passed. The initial Rust run compiled in 5m 04s, passed 1,657 unit tests, then failed the existing settlement::historical_review_and_reclosed_origin_regressions fixture with ModuleNotFoundError: No module named 'tomllib' under default Python 3.9. The corrected affected-test run, with Python 3.12 first on PATH and RUST_TEST_THREADS=3, passed typecheck, all 20 prototype tests, all 1,657 Rust unit tests and the previously failing issue-origin suite (18 passed). Once CI passed on this exact head, the overlapping local integration run was intentionally stopped and the successful CI reused, as docs/testing.md directs. The initial cold local Rust attempt took 882.97s, compilation included, before the Python environment failure.

  • python3 -m unittest discover -s scripts -p 'test_*.py' with Python 3.12 first on PATH: Ran 37 tests in 19.882s, OK. The default Python 3.9 failed three existing release-generator checks because it lacks tomllib; rerunning under 3.12 passed.

  • CI run 42292544695: SUCCESS on a59a9bfdae0eb239fcc37c7089572ea4c7e472a3. Full Rust suite, formatting, Clippy, release-generator, site and Console checks passed; the conditional ARM job was skipped.

Test seams: compiled CLI JSON output and durable Dismissal/Undo; authenticated HTTP routes and generated OpenAPI parity; rendered Inbox interactions in Playwright. The executable tests remove Bun from PATH.

Visual evidence

Before captures show the browser's connection-refused page: the unpatched prototype had no Console listener. After captures show the same Inbox flow after Dismissal, reload and Undo, with synthetic status rows.

Desktop · 1440×900

Before
After

Mobile · 390×844

Before
After

Review coverage

Independent thirdshift-code-review axes used issue-1831 (305923a8) as the fixed point. Standards raised one P3 test-setup duplication finding, fixed by the shared tests/binary.ts helper and confirmed in follow-up. Spec raised zero findings. Both axes read all 24 changed files; no changed file was left unread and no generated output was excluded. Session reports are standards.md, spec.md, and summary.json in .thirdshift-review-WJU00q/ ({"standards":1,"spec":0}).

Unaddressed findings

Standards

None. The sole finding was addressed in a59a9bf.

Spec

None.

Security

None.

Security review outcome

No unaddressed introduced findings.

CI notes

  • site-test, run 42298212753 exceeded its existing 10-minute job limit after APT fetched 17.4 MB in 9m05s (31.9 kB/s), leaving about 35 seconds for tests; no assertion failed before cancellation. The entire site/ tree and .github/workflows/ci.yml are identical to issue-1831 at 0415c236 (tree ef0ca08966ebba0618b2c675c61b28f2b5d2a61b, workflow blob b82bef2f84c8dd01a41d7e789b3a6fa557111d92). Local npm test --prefix site passed all 67 tests (87.10s); PATH="$HOME/.bun/bin:$PATH" scripts/affected-tests origin/issue-1831 passed typechecking and all 40 prototype tests (243 assertions). No source changes or CI re-run requested.

Merge Danger

Door: two-way

Revert the isolated prototype and test-selection changes; production Rust behavior is unchanged.

Blast Radius: prototype

Prototype tests now require Chromium. Console state and tokens are separate from production, with single-writer state and local-only authentication documented in the prototype README.

Built with codex codex-cli 0.160.0 · gpt-6.1-sol · high

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.

1 participant