refactor(signals): affects() dedicated channel + delete stashedOptimisticReads (arch audit tier-1)#2923
Conversation
…sticReads Tier-1 architecture consolidations from the growth audit — each retires a mechanism family rather than shrinking one. affects() off the async status rails: - a mark is now a refcount + pull-computed coverage walk at verdict time; Loading interaction is a boundary-only visual notification - marks never touch _statusFlags/_error/_pendingSources/_asyncReporters, so the five carve-out families (value-transparency, transaction- inertness, error-inferiority, settle-release, quiet-reask immunity) are deleted as unrepresentable, not maintained - per-read affects collection + per-recompute mark bookkeeping leave the core read/recompute hot paths - rulings (Ryan): marks invisible to all completion/settlement accounting by construction (never block or end their own transaction); ambient marks verdict-only, release at flush end; serialize only with a resumable transaction; hydration capture takes real committed values (value-transparency) since mark state carries no status delete stashedOptimisticReads: - forced a committed-view effect re-run on transaction backgrounding, masking an active override from stale tracked reads (A17 violation) and un-rendering co-written optimistic flags mid-window; engaged 0x in the suite. queue stash + _gatedSubs retained (distinct reveal actions); spec comment records why they can't merge. Full 56,904->56,129 min / 21,201->20,897 gz; floor 18,238->17,850 / 7,453->7,284. 1077 tests pass (1073 prior + S3 reveal pin, S4 queue-stash guard for a pre-existing coverage hole, deterministic recompute-count isolation guard for the propagation/Sierpinski property). Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
|
Bugbot is not enabled for your account, so this pull request was not reviewed. Enable Bugbot in the Cursor dashboard to get automatic reviews on future PRs. |
🦋 Changeset detectedLatest commit: 1035c9c The changes in this PR will be included in the next version bump. This PR includes changesets to release 9 packages
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
size-limit report 📦
|
Coverage Report for CI Build 29783820848Warning No base build found for commit Coverage: 75.328%Details
Uncovered ChangesNo uncovered changes found. Coverage RegressionsRequires a base build to compare against. How to fix this → Coverage Stats
💛 - Coveralls |
Merging this PR will regress 1 benchmark
|
| Benchmark | BASE |
HEAD |
Efficiency | |
|---|---|---|---|---|
| ❌ | merge |
266.5 µs | 369.6 µs | -27.9% |
| ⚡ | merge |
165.2 µs | 73.5 µs | ×2.2 |
| ⚡ | reconcile: deep tree, 10 of ~12k paths subscribed |
6.4 ms | 3.3 ms | +92.3% |
| ⚡ | updateSignals:update1to1 |
54.4 ms | 51.5 ms | +5.56% |
Tip
Investigate this regression by commenting @codspeedbot fix this regression on this PR, or directly use the CodSpeed MCP with your agent.
Comparing arch/tier1-affects-reveal (1035c9c) with next (2bf022e)
CodSpeed: net strongly positive; the one regression is a shared-VM artifact⚡ 3 improved · ❌ 1 regressed · ✅ 117 untouched
Attribution (two isolation probe PRs, now closed)
Why merge-mixed is a measurement artifact, not a cost
Acknowledging |
The two Tier-1 architecture consolidations that survived design-spike measurement (spikes 1 and 3 were declined — pull-verdicts is spec-pinned by the #2831/lane-held wake schedule and measured size-neutral; store node-authority costs +585 min). Each of these retires a mechanism family, not a line.
affects() off the async status rails
A mark becomes a refcount on the marked node(s) plus a pull-computed coverage walk at verdict time; Loading interaction survives as a boundary-only visual notification. Because marks never touch
_statusFlags/_error/_pendingSources/_asyncReporters, the five carve-out families that existed only to un-teach the async rails everything a mark does — value-transparency, transaction-inertness, error-inferiority, settle-release, quiet-reask immunity — are deleted as unrepresentable rather than maintained. The per-read affects collection and per-recompute mark bookkeeping also leave the coreread/recomputehot paths (a small simplification of the paths Sierpinski exercises).Designer rulings encoded as the channel's structural contract: marks are invisible to all completion/settlement accounting by construction — a mark can never block or legitimize ending its own transaction (the action holding the window is the real work); ambient marks (no transaction) are verdict-only and release at flush end; a mark serializes only inside a resumable transaction. Hydration capture now takes marked-covered nodes' real committed values (they carry no status), consistent with value-transparency.
delete
stashedOptimisticReadsIt forced a committed-view effect re-run when a transaction backgrounded — masking an active override from stale tracked reads (against A17's "do not mask the override from any read path") and un-rendering co-written optimistic flags mid-window — while engaging zero times across all prior tests. The queue stash and
_gatedSubsreplay are retained: they cover transaction-held reveal and silent-revert re-ask respectively, which are irreducibly distinct reveal actions; a spec comment records why they cannot physically merge (the design-spike negative result).Tests
1077 pass (1073 prior, unchanged, + 4 new pins):
propagation:*benches measure by time; this asserts it by count, noise-free).CodSpeed is the arbiter on hot-path shape — the coverage walk is O(upstream reachability) per marked-node verdict (was O(pendingSources)); flagged for the perf run. Every prior spike round taught that local wall-clock can't resolve these deltas, so the benches decide.
🤖 Generated with Claude Code