Skip to content

feat: Complete typed WebUI cutover and delete the legacy interpolated r… - #4645

Merged
Sinity merged 4 commits into
masterfrom
feature/packet/polylogue-pnzf2
Sep 4, 2026
Merged

Sinity merged 4 commits into
masterfrom
feature/packet/polylogue-pnzf2

Conversation

@Sinity

@Sinity Sinity commented Sep 4, 2026

Copy link
Copy Markdown
Owner

Summary

The daemon now serves the typed WebUI from the root and canonical deep-link routes, with manifest-governed assets under /assets. The twelve interpolated web-shell modules and shell-only structural tests were removed. Attachment, paste, workspace, topology, and semantic data continue through typed daemon projections and existing JSON APIs.

Problem

The repository exposed two browser readers and retained /app compatibility routes. The legacy reader duplicated HTML, JavaScript, and attachment/paste shaping logic, while route contracts and packaged assets still described the retired mount.

Solution

Canonicalized browser route contracts and links, moved shared attachment and paste envelopes to webui_data.py, regenerated the packaged Vite assets, and removed the legacy shell modules and tests that only certified their implementation shape. Updated the capability matrix, daemon architecture documentation, and surviving HTTP/data-contract tests.

Verification

npm run check passed with 11 Vitest files and 31 tests, 8 client-contract tests, typecheck, lint, production build, and design-system builds. uv run devtools verify --quick passed all listed checks. uv run devtools verify oracle-integrity reported 0 integrity failures. Focused daemon, route, auth, topology, thread, attachment, and maintenance tests passed. uv run devtools verify refused affected verification because the checkout has SQLite sidecars without its owned database.

Residual risk

Managed Playwright, visual/performance, deployment browser smoke, and affected verification were not run in this lane. The full corpus remains a merge-boundary responsibility.

@Sinity
Sinity enabled auto-merge (squash) September 4, 2026 01:19
@coderabbitai

coderabbitai Bot commented Sep 4, 2026 •

Copy link
Copy Markdown

Important

  • 🔍 Trigger review

This repository does not receive automatic reviews because it has fewer than 10 stars.

⚙️ Run configuration

Configuration used: Organization UI

Review profile: ASSERTIVE

Plan: Team

Run ID: b24aa9aa-5569-4632-8f11-710dd89504a4


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Sep 4, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-09-04T01:29:22.641743Z b5f5c72 PR opened
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@Sinity
Sinity force-pushed the feature/packet/polylogue-pnzf2 branch from b5f5c72 to 686fe74 Compare September 4, 2026 01:21
@Sinity
Sinity merged commit 0612cf7 into master Sep 4, 2026
3 of 4 checks passed
@Sinity
Sinity deleted the feature/packet/polylogue-pnzf2 branch September 4, 2026 01:26

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: b5f5c72556

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread polylogue/daemon/webui.py Resolved
Comment thread polylogue/daemon/webui.py Resolved
Comment thread polylogue/daemon/webui_data.py Resolved
Comment thread polylogue/daemon/http.py Resolved
Comment thread polylogue/daemon/web_shell_realtime.py Resolved
Comment thread polylogue/daemon/http.py Resolved
Comment thread polylogue/daemon/webui.py Resolved
Sinity added a commit that referenced this pull request Sep 14, 2026
Triage of the daemon/async share of the 58 corpus failures. **21 of 23
fixed**
across 17 commits — and it uncovered **silent production data loss**
that would
have crippled the from-scratch rebuild.

## The finding that matters

The brief framed the four `test_daemon_resilience` failures as "grouping
or
daemon lifecycle". Raising the module timeout — a 300s wait under a 120s
ceiling
could **never** complete — unmasked the real diagnostics. On an **idle**
machine
`sigkill_recovery` reported *byte-identically* the same "20 messages" as
the
corpus run, proving load was not the cause.

**The daemon ingested one session per root and stopped.**

`FileIntakeAdapter.discover` advanced its cursor past the entire
discovered page
while the dispatcher consumed only its head, and the walk only moves
forward.
Compounding it, adapters charge `estimated_cost` in **bytes** while the
service
budget was `64` — a *count*.

Every session after the lexicographically-first was retained on disk and
never
archived. Introduced by `#4913`, which made the dispatcher the sole
discovery
authority and disabled the watcher's own catch-up.

This is not a test defect. The fresh-start ruling is *"move the six
database
files aside, start the daemon fresh, let ordinary convergence rebuild
everything
from the actual sources"* — so the rebuild **is** this code path.
Building on the
previous head would have produced an archive containing roughly one
session per
source root and reported success.

## Classification of all 23

**PRODUCT-BUG (8)** — the discovery/budget loss above (resilience ×3 +
`large_session_file`); workload probe ×2 (the adapter treated "file
exists" as
"tier bootstrapped", and `inspect` opened a DB to answer an empty
question); MCP
clamp (the CLI clamps `limit=-1`, MCP refused it — the declared clamp
was applied
to the routing probe but not the typed request); daemon SIGTERM
forensics (the
signal handler wrote without the process-wide lease,
`UnleasedWriteError`
swallowed → `(None, 'signal')`).

**STALE-TEST (8)** — the insight cluster ×4 (still calling the facade
#5030
retired); visual ×2, red since #4645's WebUI cutover because
`tests/visual/` is
not in the fast gate; `daemon_status` (`(0 sessions, 1 message)` is
unreachable by
construction post-#5027); demo seed.

**ORDER-DEPENDENT (3)** — `test_daemon_cli.py`. Passed alone *and*
across
`tests/unit/daemon`; the corpus receipt showed a `MagicMock` and a
shut-down
adapter leaking through the process-global `_SHARED_COMPUTE_ADAPTER`.
`reset_daemon_compute_adapter()` already existed and **nothing called
it**.
Verified red→green with a deterministic two-file reproducer.

**TEST-INFRA (3)** — `live_read_amplification` (double drifted from a
keyword-only signature); `resume` (rename debris from #4614, `insights`
vs
`analysis`); `write_path_state_machine`.

**Root verb (1)** — `verification-export` regrew the surface `985e0f9d9`
folded.
The verb was wrong, not the test.

## Two left unfixed, deliberately

- **`test_demo_seed_verify`** — Codex declares `parent_dispatch`
structurally
absent, so `mapping_state:resolved` is unreachable for that fixture
(confirmed
by counterfactual: forcing the origin gate only changes the refusal
reason). A
Claude Code delegation fixture was started; each step revealed another
required
  piece, so it was **reverted cleanly** rather than left half-built.
- **`test_installed_package_smoke`** — diagnosed precisely, then **both
commits
reverted** after three fixes each broke a different legitimate caller.
The third
was rejected by `devtools gate layering`'s own ratchet. That the
architecture
refuses the CLI-layer catch says this needs a deliberate owner decision,
not a
  triage patch. Full rationale is in the revert commit.

## Verification

```
2,976 passed, 0 failed      devtools verify --quick   exit 0, 15/15 gates
```

## Residuals recorded in commits

A pre-existing `_assert_resolved_link` property failure (replayed
against base —
fails there too, no delete involved); an unleased-writer bug in the
daemon
health/cursor-lag path; a whale-pass deadlock against the daemon's own
ownership
flock; and a note that two reds in `tests/unit/sources/` assert FTS
convergence
debt which the inline repair here makes obsolete.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

https://claude.ai/code/session_01DYUNBGoE652b3nfmq3CtqK

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

* **New Features**
  * Updated the verification export command to use `verify export`.
  * Newly ingested sessions become searchable immediately.
  * Improved intake processing so skipped items can be rediscovered.

* **Bug Fixes**
  * Out-of-range session list limits are now handled safely.
  * Improved daemon lifecycle signaling under write-lease enforcement.
* Clearer errors are provided when source databases are missing required
data.
  * Intake processing now uses a byte-based default budget.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->

---------

Co-authored-by: Claude Opus 5 (1M context) <[email protected]>
@Sinity

Sinity commented Sep 29, 2026

Copy link
Copy Markdown
Owner Author

Closing out open Codex review threads on this PR (evidence checked against master at ef10e59):

Resolving the fixed, stale and refuted threads; tracked threads stay open.

@Sinity

Sinity commented Sep 29, 2026

Copy link
Copy Markdown
Owner Author

Closing out open Codex review threads on this PR (evidence checked against master at 64a9bd0):

  • P1 polylogue/daemon/http.py:1865: Fixed on master (checked at 64a9bd0): _check_shell_bootstrap_access now admits only a credentialed request and otherwise returns the sign-in page or a 401 (polylogue/daemon/http.py:2195-2208). The /p and /a handlers run only after it passes (polylogue/daemon/http.py:2045-2055).

Resolving every thread listed; confirmed defects are fixed under the named bead.

@Sinity

Sinity commented Sep 29, 2026

Copy link
Copy Markdown
Owner Author

Closing out open Codex review threads on this PR (evidence checked against master at 0914f89):

Resolving every thread listed; confirmed defects are fixed under the named bead.

@Sinity

Sinity commented Sep 29, 2026

Copy link
Copy Markdown
Owner Author

Closing out open Codex review threads on this PR (evidence checked against master at c0dda6f):

Resolving every thread listed; confirmed defects are fixed under the named bead.

@Sinity

Sinity commented Sep 30, 2026

Copy link
Copy Markdown
Owner Author

Historical Codex triage: evidence checked at 5ebcfe5. This records that source revision; it does not claim a fresh review of current master.

  • 64.F021 / P1: fixed-already at the checked revision: The current workspace route calls render_compare_page at polylogue/daemon/http.py:2396. That renderer emits separate left/right message cells at polylogue/daemon/webui.py:2059-2060, while _scalar_projection reduces mappings and sequences to counts at lines 1863-1866 instead of repeating nested session representations.

Only the rows listed above are dispositioned. Held findings remain open.

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