Skip to content

rewrite(phase6): batch 7 — CANEP/LINEP/ISELED catalog re-derivation - #160

Merged
SoundMatt merged 1 commit into
rewrite/v3-from-c-rcpfrom
phase6/canep-linep-iseled
Aug 22, 2026
Merged

rewrite(phase6): batch 7 — CANEP/LINEP/ISELED catalog re-derivation#160
SoundMatt merged 1 commit into
rewrite/v3-from-c-rcpfrom
phase6/canep-linep-iseled

Conversation

@SoundMatt

Copy link
Copy Markdown
Owner

Part of the v3.0.0 ground-up rewrite (#129, ROADMAP.md Phase 17). Phase 6 (requirement catalog), batch 7 of 13.

This batch: CANEP (42 c-RCP entries) / LINEP (34) / ISELED (42)

  • 98 new catalog entries. iseled.hpp/test_iseled.cpp were already fully tagged from an earlier untracked rewrite pass — zero changes needed there.
  • Same id-collision pattern as batch 6/rewrite(phase6): batch 6 — E2E/LIFECYCLE catalog re-derivation #159: cpp's pre-existing low ids (CANEP-001..009, LINEP-006, ISELED-001..007) collide with unrelated c-RCP requirements of the same number — 17 filed to .fusa-reqs-pending.json as id-collision gaps.
  • 3 c-RCP-retired ids correctly skipped (near-duplicates in c-RCP's own history).
  • Real test-coverage gaps found and closed: CanErrc/LinErrc message distinctness, several reject-taxonomy paths (bad_msg_type/bad_frame_format/bad_arbitration_id) that were never actually exercised despite adjacent coverage, a regression test for a wire-bit fix that round-trip tests alone can't catch. Two initially-incorrect test constructions caught and fixed before finalizing.
  • REQ-CANEP-029 included honestly as status: not-implemented — a real, tracked spec gap in c-RCP's own catalog, not force-fit as done.

Verification

Independently re-verified (the porting agent itself also ran the real cpfusa trace tool: 681/681 annotated+tested, 100%): semantic id-keyed diff confirms zero pre-existing entries modified, exactly 98 new ids matching the per-prefix breakdown exactly, zero duplicate ids. Confirmed no new entry carries severity: cybersecurity. Spot-checked the REQ-CANEP-001 id-collision claim directly against both catalogs' content — confirmed real. Confirmed all six touched files are pure additions (zero deleted lines). Full tree rebuilt from scratch: 0 errors, 0 warnings, 58/58 ctest suites pass.

🤖 Generated with Claude Code

Part of the v3.0.0 ground-up rewrite (cpp-RCP #129, ROADMAP.md Phase 17),
branch rewrite/v3-from-c-rcp. Phase 6 (requirement catalog), batch 7 of 13.

## Scope

can.hpp's REQ-CANEP-* (c-RCP: 42 entries), lin.hpp's REQ-LINEP-* (34),
iseled.hpp's REQ-ISELED-* (42) -- 118 c-RCP entries total. Base bus/
frame-layer REQ-CAN-*/REQ-LIN-* prefixes explicitly out of scope.

## Major finding: can.hpp/lin.hpp/iseled.hpp were already far ahead of the catalog

An earlier, untracked rewrite pass had already brought these three
files close to c-RCP's real design -- most of the 118 requirements
were already genuinely implemented and tested; the gap was almost
entirely in the catalog/tags, not the code. iseled.hpp/test_iseled.cpp
already carried complete file-level tags for essentially the whole
c-RCP id range -- zero changes needed to either file. can.hpp/lin.hpp
only had tags for their old, pre-rewrite low-numbered ids and needed
33/33 new tags respectively.

## Id-collision pattern (same class as batch 6/#159)

cpp's pre-existing low ids (CANEP 001-009, LINEP 006, ISELED 001-007)
were numbered independently before this rewrite's "reuse c-RCP's exact
id" convention took hold, and collide with c-RCP's own same-numbered
but content-unrelated requirements (verified directly: cpp's
REQ-CANEP-001 is "CAN's ep_type id is 0x0B"; c-RCP's is
"rcp_ep_can_frame_format_valid() accepts exactly the six FrameFormat
values Table 57 defines" -- unrelated content, same id). Filed as 17
id-collision gaps to .fusa-reqs-pending.json (CANEP-001..009 x9,
LINEP-006 x1, ISELED-001..007 x7) rather than corrupting catalog id
uniqueness, for a future renumbering-cleanup batch.

## New catalog entries (98)

- CANEP: 33 (010-028, 030-042; 029 included as an honest
  status:not-implemented spec-gap entry, matching c-RCP's own tracked
  defect -- not force-fit as implemented)
- LINEP: 31 (007-039, excluding collision 006 and retired 023/026)
- ISELED: 34 (008-027, 029-042, excluding collisions 001-007 and
  retired 028)

## Retired, no action (3)

REQ-LINEP-023/026, REQ-ISELED-028 -- c-RCP itself retired these as
near-duplicates; correctly not ported.

## Real test-coverage gaps found and closed (new TEST_CASEs added)

can.hpp: CanErrc message distinctness; CanFunctionalConfig zero-init;
full reject-taxonomy completions for decode_frame_request/
decode_frame_response/decode_frame_response_fragment/
decode_reassembled_frame_response (bad_msg_type/bad_frame_format/
bad_arbitration_id were previously never exercised, only wrong_bus/
short_frame/wrong_op/bad_evt were); a dedicated regression test for
the ep_clear_req_storage wire-bit-4 fix (a wrong-but-self-consistent
bit that round-trip tests alone can't catch); explicit byte-level
right-alignment assertion; remote-frame-absence documentation test.
lin.hpp: LinErrc message distinctness; decode_command_request
bad_evt/bad_msg_type paths that were named in an existing test's title
but never actually exercised; LinReconfigErrc message non-emptiness.
Two initially-incorrect test constructions were caught and fixed
before finalizing (a structurally-unreachable bad_msg_type-via-ACF_GBB
path, a byte-index mislabel in the right-alignment test).

## Verification

Independently re-verified (not just the porting agent's own report,
which itself ran the real cpfusa v0.18.0 trace tool and reported
Total 681/Annotated 681/Tested 681, 100% both metrics, secTested
holding at 72): semantic id-keyed diff confirms zero pre-existing
catalog entries modified/deleted, exactly 98 new ids matching the
report's per-prefix breakdown exactly (CANEP 33, LINEP 31, ISELED 34),
zero duplicate ids anywhere in the catalog. Confirmed no new entry
carries severity:cybersecurity -- sec-tested count holds exactly at
72/681. Directly spot-checked the CANEP-001 id-collision claim against
both catalogs' actual content -- confirmed real. Confirmed
can.hpp/lin.hpp diffs are pure additions (zero deleted lines across
all six touched files) -- tags and new tests only, no existing
behavior touched. Full tree rebuilt from scratch: 0 errors, 0
warnings, 58/58 ctest suites pass (100%).

.fusa-reqs.json: 583 -> 681 entries (+98, 5663 -> 6806 lines).
.fusa-reqs-pending.json: 31 -> 48 entries (+17, 310 -> 517 lines).
include/rcp/can.hpp: +33 lines (tags only). include/rcp/lin.hpp: +33
lines (tags only). tests/test_can.cpp: +335 lines. tests/test_lin.cpp:
+101 lines. include/rcp/iseled.hpp, tests/test_iseled.cpp: unchanged.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Signed-off-by: Matt <47545907+SoundMatt@users.noreply.github.com>
@SoundMatt
SoundMatt merged commit 6ebeb85 into rewrite/v3-from-c-rcp Aug 22, 2026
22 checks passed
@SoundMatt
SoundMatt deleted the phase6/canep-linep-iseled branch August 22, 2026 12:51
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