8.8 KiB
Semantic desktop review — scalars and nested message kind
Status: milestones 1–2 implemented; the bounded MessageKind/TimerExpression
constructor slice is implemented. Full milestone 3, GUI parity, native acceptance
and release acceptance remain outstanding.
Base: d130013. Dedicated build target:
D:/CodexBuilds/Capella2-semantic-desktop-target. Native verification is root-owned.
Scope and decisions
- Add an explicit Review semantics action for existing traced counterparts, with canonical Operational/System comparisons in either application direction. Preserve the existing counterpart creation and prose workflow with clear labels.
- Review one explicitly selected trace per dialog. Display grouped current and historical facts, own/linked drift and incomplete review. Names never infer reference correspondence; provide explicit reference and trace choices.
- Support every applicable scalar leaf through Keep, Take and typed final-value forms. Candidate records contain the complete combined selected result. Identity, alias and layer are protected. The closed core remains the validation boundary.
- State.Kind is a single structural scalar. Occurrence.MessageKind now supports its complete nested group, including TimerExpression. Other constructor switches, keyed membership/order/annotation/binding/attachment decisions and pairing resets belong to milestone 3; show them read-only with an honest explanation.
- Core
6bb2583permits first equal constructor acknowledgment without descendant expansion. The GUI exposes Acknowledge equal kind only when applicable; previously reviewed constructors remain governed by the core's switch rules. - Show exact additional prepared impacts and require explicit acceptance. Apply validates the stored semantic plan and executes its exact command batch through Document, preserving source, baselines and one-step undo/redo. Do not place or reveal diagram objects by mutating the model after preview.
- Retain typed drafts and review choices on invalid input, planning conflicts, stale plans and failed source writeback. Display actionable errors in the dialog.
Milestones and acceptance
- Grouped read-only review, named trace/reference choices, exact comparisons and honest traceability rollups; compact layout usable at 1100 by 700.
- Scalar decisions and typed candidates; immutable initial observations; combined final records; exact impact acceptance; atomic document/source commit. Focused App event/source/history tests, strict Clippy and a dedicated desktop build.
- Nested MessageKind/TimerExpression closure is implemented. Other constructor groups, keyed and ordered facts, reset, complete artifact lifecycle, multi-source review and remaining source/REST parity cases are outstanding.
- Root-owned native review, cross-surface fixtures, package/release acceptance.
Verification
Scalar fixes were verified on SEM 6ad3cb; the nested message-kind slice builds
on scalar commit 5a51a75. Verification uses only the dedicated desktop target
(core behavior remains based on 6bb2583):
$env:CARGO_TARGET_DIR='D:/CodexBuilds/Capella2-semantic-desktop-target'
cargo test --locked -p oa-desktop --quiet
cargo clippy --locked -p oa-desktop --all-targets -- -D warnings
cargo build --locked -p oa-desktop
All 285 desktop tests passed, including 11 original semantic review tests,
5 scalar review regression tests, and 8 nested message-kind tests.
Strict Clippy and the desktop build passed. The existing migration test's header
assertion now follows SCHEMA_VERSION instead of expecting schema 4.
Coverage includes both-direction Keep/Take/Candidate with exact comments and source/model/baseline undo/redo; independent selected trace semantic histories; invalid numeric and protected-property edits; stale-plan and source-writeback rejection; typed reference mapping mixed with candidates; honest partial rollups; equal-kind acknowledgment without implicit descendants; State.Kind candidates; relationship role/bound candidates with retained identity/endpoints; and exact inherited-annotation cleanup approval, cleared when decisions change. Unselected invalid scalar drafts remain retained without contaminating another candidate.
The independent scalar review found three gaps, now corrected:
- Structural scalar edits replace only their authorized subtree. Clearing an invalid selected bound, changing a variant, and adding/removing/reordering a literal retain untouched raw inputs and editor buffers, including invalid inputs belonging to another decision.
- Dependent default, reference and port controls read a noncommitting context composed by the same scalar Keep/Take/Candidate assembler as the request. Raw candidates remain separate. Incomplete inputs use their stored shape only for those controls; request creation and Apply still reject invalid selected input. The Boolean-source/Integer-target default reproduction now offers Boolean literals in both directions. Tests also cover Candidate type, Keep reversion, storage-dependent default controls and mechanism-dependent reference choices.
- Keyed fact headings display live names with stable aliases or deleted UUIDs. Message annotation headings include the complete qualified path and field.
The regression tests exercise App events, the actual default-form helpers and button availability, exact source retention before Apply, and one-step undo.
Bounded constructor slice
Occurrence.MessageKind is a complete closed nested family: Asynchronous, Call, Reply, Create, Delete and Timer. It is available only when both traced counterparts are Exchange occurrences. The only constructor-specific payload is the timer expression. Outer occurrence replacement remains read-only.
- Keep/Take/Candidate use the core's switch and first-equal acknowledgment policy. Taking a replacing group copies the typed MessageKind, including its expression. Taking an initial equal discriminator does not copy an unselected timer value.
- Candidate MessageKind has its own scoped draft. The independent TimerExpression scalar draft survives group decisions; the group timer's exact raw text, editor cursor and selection survive switching away from Timer and back.
- An overlapping kind/timer draft retains both decisions and blocks Apply until explicitly resolved. The dialog offers Replace timer decision with message-kind group and Leave message kind unselected; use timer decision. First equal-kind acknowledgment can coexist with an independent timer decision. Divergent authored candidate values reject; neither candidate silently overwrites the other.
- The kind detail includes baseline/current timer observations and the complete proposed kind. It displays the exact plan-provided acknowledged/retired lists. Exchange, reply-to, lifelines, annotations and pre/postconditions stay separately scoped. Incompatible Timer contracts remain core errors; no dependency or payload is silently removed. Existing additional-impact approval remains in force.
- Group changes compose with scalar choices and execute the exact prepared Document batch. Tests cover both directions, all six kinds, mapped reply correlation, historical retirement, repeated no-switch rejection, invalid combinations, protected scopes, stale preview, source failure, comments and one-step undo/redo.
- The Traceability contextual toolbar now wraps at the available width so +Artifact
remains reachable in the compact layout. This is a single
row.wrap()change inviews.rs; other toolbars are outside this slice.
Root reported native scalar coverage on frozen integrated e7fa061: mixed numeric
Keep/Take/Candidate, invalid default retention/repair, zero additional changes,
atomic Apply, comment/value inspection, Undo/Redo and Save All at 1440×900 and
1100×700. Reverse/type/reference/history/reopen native checks were still continuing
when this slice was implemented. This task launched no native application.
Built executable:
D:/CodexBuilds/Capella2-semantic-desktop-target/debug/arcadia-studio.exe.
The build target is idle. No native application was launched by this task.
Remaining work
Milestone 3 must add the remaining constructor closure/replacement, keyed and ordered decisions, historical pairing reset, complete artifact lifecycle and multi-source review. These facts are currently inspectable, with unsupported writes visibly identified. The reference table supplies explicit mappings for scalar reference Take; it does not claim to complete a reset or establish keyed acknowledgments.
Fresh independent requirements/correctness review and root-owned native checks of the message-kind slice are required before release acceptance. Verify the compact kind picker, timer text/focus retention, overlap choices, exact closure/retirement, mapped Reply, blocked Timer contract, source reopening and toolbar wrapping.