docs: describe the readiness gate that exists, not the one that was deleted - #414
Merged
Conversation
…eleted Five header comments cited `tryFireImpl` and `SubscriberEntry`. Neither has existed since the handler-side draft machinery was removed: `BridgeHandler` has no `set<>`, no draft, no `entries`, and `git grep -w` finds both names only in the comments citing them. The mechanism was deleted, but the *gate* was not — it moved. The readiness check that `tryFireImpl` performed now runs in `morph::flows::FlowSession::set<>` (forms/flows.hpp:267), which fires a step only once `ActionValidator<A>::ready` passes, and the comment directly above it says so. So these citations are repointed rather than deleted, keeping the explanation they carried: - core/bridge.hpp — the request/reply validator gate's reactive counterpart. - core/registry.hpp (Doxygen, published API) — `ValidationError`'s "two execution sites, two client-side gates" arithmetic still holds with the gate named correctly. - core/registry.hpp — the same pair of gates, in the server dispatch path. Two sites needed no successor. flows.hpp attributed "exactly one `SubscriberEntry` per action type" to bridge.md's "Subscription semantics", which says the opposite axis — `subscribe<R>` is keyed on the result type, not on an action — so the false attribution goes and the real constraint is named: the slot is one element of `FlowSession`'s own `std::tuple<Steps...>`. tests/test_coverage_gaps.cpp carried a bare section marker for a coverage gap in a deleted function, with no test under it and a line range (498-499) that is now mid-doc-comment on `attachHandlerAsync`; it is removed. Comment-only: every changed line is a comment. Refs #355 Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_0154xzWuBMPveLcdeUgydifb
Two wording fixes from the simplify gate, both comment-only: - bridge.hpp named `ActionValidator<A>::ready`, borrowing flows.hpp's template parameter into a file whose own parameter is `Action` — and the same comment says `ActionValidator<Action>::ready` four lines below. - registry.hpp's reflowed Doxygen paragraph wrapped one line wider than the rest of its block. Refs #355 Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_0154xzWuBMPveLcdeUgydifb
The code-review gate caught an inaccuracy in text this branch authored. `std::tuple<Steps...>` does not give one slot per action type — it gives one element per step position, so a duplicated `Steps` yields two elements and nothing "collides on that single slot". What a duplicate actually breaks is type-keyed access: `_drafts` is reached as `std::get<A>(_drafts)` (flows.hpp:257, 258, 393), and `std::get<T>` is ill-formed when `T` occurs more than once — which is exactly what the `AllDistinct<Steps...>` static_assert enforces. docs/spec/forms/workflows_navigation.md:315 already gives this reason. Refs #355 Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_0154xzWuBMPveLcdeUgydifb
This was referenced Sep 2, 2026
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What this is
Five header comments cited
tryFireImplandSubscriberEntry. Neither name exists anywhere in the tree —git grep -wfinds them only in the comments citing them.The archaeology
The handler-side draft machinery
tryFireImplbelonged to was deleted. TodayBridgeHandlerhas noset<>(onlysetDefaultSession/setExecuteDeadline/setPrincipal), no draft, noentries, and noSubscriberState.But the gate was not deleted — it moved. The readiness check
tryFireImplperformed now runs inmorph::flows::FlowSession::set<>:and the comment five lines above it says so in as many words: "The readiness gate that used to live in the handler's draft machinery lives here now."
So these citations are repointed rather than deleted, which keeps the explanation each was carrying.
ValidationError's "two execution sites reached without passing a client-side gate" arithmetic inregistry.hppis still exactly true — it was only naming the wrong gate.The five sites
core/bridge.hpp:2317FlowSession::set<>core/registry.hpp:126ValidationError's gate pair, renamedcore/registry.hpp:413forms/flows.hpp:189SubscriberEntry+ a false attribution (below)tests/test_coverage_gaps.cpp:575Two sites needed no successor name:
flows.hpp:189attributed "exactly oneSubscriberEntryper action type" todocs/spec/core/bridge.md's "Subscription semantics". That section says the opposite axis — "subscribe<R>(cb)is keyed on the result/state type, not on an action" — and its cardinality rule is "one callback per(handler, R)". The false attribution goes; the real constraint behind theAllDistinct<Steps...>assert is named instead: one slot ofFlowSession's ownstd::tuple<Steps...> _drafts.tests/test_coverage_gaps.cpp:575was a bare section marker with no test under it, for a coverage gap in a deleted function. Its cited rangebridge.hpp:498-499is now mid-doc-comment onattachHandlerAsync, so the line numbers were stale too. Removed.Verification
Comment-only: every changed line is a comment (
git diff -U0filtered for non-comment lines returns nothing).scripts/check_spec_citations.sh— exit 0, "Prose lint OK: every pinned fact is still cited; no banned terminology found; every cited path resolves; every cited section exists" (720 references, 60 cited sections)scripts/check_deprecated_markers.sh,check_test_type_names.sh,check_journal_stamps.sh— exit 0clang-debugbuild under-Weverything(Clang 22.1.8, 29 flags, strict) — cleanctest— full suiteRefs #355
🤖 Generated with Claude Code
https://claude.ai/code/session_0154xzWuBMPveLcdeUgydifb