Skip to content

feat: compile Router match projection in Strong mode - #2102

Merged
domgan-oai merged 1 commit into
octanejs:mainfrom
openai-oss-forks:feat/strong-router-match-lifecycle
Oct 15, 2026
Merged

domgan-oai merged 1 commit into
octanejs:mainfrom
openai-oss-forks:feat/strong-router-match-lifecycle

Conversation

@domgan-oai

@domgan-oai domgan-oai commented Oct 15, 2026 •

Copy link
Copy Markdown
Contributor

Summary

The website’s compiled Router entry reached one compatibility module that mixed match projection with live navigation and error side effects. Compile the match tree and shared default error UI in Strong mode, keeping provider/transition and pending/error/scroll lifecycles in explicit compatibility owners. The route hierarchy, synchronous onCatch, rethrow to parent, and match-identity recovery remain intact. Related to #2059; this does not close it.

Validation

  • pnpm format:check (repository-wide; changed files passed format:files:check)

  • pnpm typecheck (repository-wide; Router source/public API and website source programs passed)

  • pnpm test (repository-wide; root Vitest config needs unrelated dependencies absent from the scoped local install)

  • targeted tests: 106 Router conformance, 10 SSR, and 3 React differential cases passed. The added lifecycle cases passed unchanged against main 9bceb816a; disabling error reset/reporting made the relevant negative controls fail. pnpm sync passed.

  • Actual website development and production browser comparison against the same main SHA: decoder → catalog/filter → another decoder, direct invalid-code 404, authored recovery link → interactive homepage, Back/Forward, and Docs navigation matched. Only the two deliberate direct entries requested documents; other navigation and recovery were client-side. The normal production build passed; server-rendered decoder content and hydration transport matched, and the hydrated controls worked.

  • perf-review: binding-source scan found 0 candidates. Per-match projection (compiled/Matches.tsrx:23,54,62,101) retains the existing store selectors and hierarchy; provider acknowledgement (compiled/RouterProvider.tsrx:49) is unchanged. The live transaction read moved into the existing pending owner (compiled/MatchLifecycle.tsrx:20), without a wrapper, new task, DOM read/write, hot-record field, or new per-item allocation. Focused production Vite integration emitted componentSlotVoid at all 10 detected relocated component call sites. Complete website public JavaScript: 615 files, 19,405,558 → 19,405,775 raw bytes (+217), 4,355,712 → 4,355,894 summed per-file level-9 gzip bytes (+182); this is not an initial-route payload or speed measurement. Browser latency and a standalone core-compiler fixture were not measured.

  • concise-code: binding source +222/−188 lines (core runtime +0/−0). Three new internal source modules separate shared Strong error UI, Strong match projection, and the two compatibility ownership layers; the compiled public entry retains its exports. Keeping everything in one file cannot mark projection Strong; moving synchronous reporting into an effect changes callback/rethrow timing; another wrapper would add a component boundary. Independent final review found no actionable complexity issue.

  • Current-head CI: all 27 jobs passed (54,426 general tests passed, 2 skipped; 105 website; 620 Chromium), including parity, examples, publication, lint/types, and bundle checks. Benchmark: all 64 work counters, 93 bundle values, and 120 reachability values unchanged; all 20 timings had no resolved verdict. Bugbot passed with no inline findings.

Risk / follow-ups

The dependency frontier remains open: the original Router compiled/Matches.tsrx boundary becomes compiled/RouterProvider.tsrx and compiled/MatchLifecycle.tsrx; Router linkBinding.ts and Three web/events.ts remain. All 98 authored website modules analyze with zero Strong diagnostics and no ReactCompat boundary, but this does not establish whole-package compliance or descriptor-free output.

The website’s invalid-code entry is a direct request because it has no authored link to an invalid code; the recovery and subsequent navigation are client-side. The same existing Lynx teardown diagnostics appeared on main and candidate. A separate fixture navigating from a healthy route into the global uncaught-error boundary left router.navigate() unresolved after five seconds on both revisions; initial global fallback and its details toggle work. Pristine upstream Router parity remains recorded-unverified. Local dependency setup used a frozen offline scoped install after the configured dependency firewall blocked an unrelated package; no registry bypass was used.

Provenance

  • An agent produced this diff (agent-authored)

Codex task · host com-79386


View with [code]smith Autofix with [code]smith
Need help on this PR? Tag @codesmith-bot with what you need.


Note

Cursor Bugbot is generating a summary for commit 0d3284b. Configure here.

@github-actions github-actions Bot added agent-authored Diff or issue body substantially produced by an AI agent feat PR: new feature or capability labels Oct 15, 2026
@domgan-oai
domgan-oai marked this pull request as ready for review October 15, 2026 19:45
@github-actions

Copy link
Copy Markdown
Contributor

Benchmark report

🟢 No byte growth, no added work, and no timing changes beyond ±3%.

Compares 9bceb816a, the merge commit's first parent with a17623b4e on the same runner. Any increase in a js-framework work counter fails this check; byte changes are a report. Wall time is a report: base and head samples alternate in one browser, and an operation is called slower or faster only when the 95% confidence interval of its ratio excludes ±3%. Workflow run

js-framework: 1k/10k row operations

All 20 timed operations (20 without a verdict)
target operation base ms head ms head/base 95% CI
octane-tsrx run 5.808 6.950 +2.5% −2.8% … +6.5% ⚪ within noise
octane-tsrx replace 10.325 11.992 −2.7% −15.8% … +6.5% ⚪ within noise
octane-tsrx add 4.250 4.225 +3.5% −4.9% … +74.1% ⚪ within noise
octane-tsrx update 0.151 0.157 +0.7% −4.8% … +6.2% ⚪ within noise
octane-tsrx select 0.010 0.010 +1.0% −0.8% … +11.4% ⚪ within noise
octane-tsrx swap 0.033 0.027 −2.9% −30.9% … +6.1% ⚪ within noise
octane-tsrx remove 0.021 0.021 +3.2% +0.9% … +12.1% ⚪ within noise
octane-tsrx runlots 36.175 35.158 +2.3% −7.4% … +5.5% ⚪ within noise
octane-tsrx select_lots 0.009 0.010 −2.1% −3.8% … +4.6% ⚪ within noise
octane-tsrx clear 49.558 57.442 +1.2% −1.9% … +10.7% ⚪ within noise
octane-jsx run 11.125 9.958 +8.9% −9.9% … +26.1% ⚪ within noise
octane-jsx replace 19.683 16.442 −5.5% −22.1% … +5.0% ⚪ within noise
octane-jsx add 9.217 8.833 +4.0% −0.9% … +10.1% ⚪ within noise
octane-jsx update 0.766 0.573 −10.7% −33.9% … +14.8% ⚪ within noise
octane-jsx select 0.296 0.259 −1.5% −23.6% … +6.6% ⚪ within noise
octane-jsx swap 0.301 0.281 −1.3% −10.0% … +1.2% ⚪ within noise
octane-jsx remove 0.295 0.310 +4.6% −3.4% … +31.9% ⚪ within noise
octane-jsx runlots 68.375 66.483 +5.1% −1.0% … +22.8% ⚪ within noise
octane-jsx select_lots 4.846 5.929 +1.5% −16.8% … +28.2% ⚪ within noise
octane-jsx clear 87.883 76.650 −11.7% −32.2% … +8.1% ⚪ within noise

All 64 work counters are unchanged.

Application bundle size (bytes)

No changes across 93 measured values.

Public-import reachability bundles (bytes)

No changes across 120 measured values.

@domgan-oai
domgan-oai merged commit 91dae8d into octanejs:main Oct 15, 2026
54 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

agent-authored Diff or issue body substantially produced by an AI agent feat PR: new feature or capability

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant