fix: render scalar catalog titles and canonicalize rg lineage paths (#51) (#52) - #53
Merged
Merged
Conversation
) (#52) Two defects the SAC v0.5.4 fixes exposed in the shared renderer and the shared rg accelerator. #51: `_escape_link_label()` assumed a string, so a concept with `title: 421` aborted catalog refresh after capture had already written concepts. It now normalizes to text at the boundary. `fm_c.get("title") or p.stem` also sent a falsy-but-real title (`0`, `false`) to the file stem, so the catalog showed the wrong label. #52: `rg_list_files()` resolves its hits, but `_inbound_via_rg()` derived `src` with `path.relative_to(bundle)`. A bundle reached through a symlink alias made that raise, and the handler silently dropped a real lineage neighbor while the pack still reported `reverse_index: rg`. `is_concept_path()` on the line above already resolved both operands. `resolve_knowledge_root()` returns an absolute `--bundle` verbatim, so this was reachable from the CLI. Both regression tests are red without the corresponding fix. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01TZ1sCoZonCJw2oPbPcPioW
mkdtemp yields the /var alias on macOS but a plain /tmp path on Linux, so the test skipped itself on CI — the platform it most needs to cover. Create the symlink explicitly and address the bundle through it. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01TZ1sCoZonCJw2oPbPcPioW
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.
Fixes #51. Fixes #52.
Both are the DEKC instances of the two defects fixed in system-architecture-capture v0.5.4.
#51 — scalar catalog titles
_escape_link_label()assumed a string, so a concept withtitle: 421abortedrefresh_catalog_index()withAttributeError. Capture writes concepts before refreshing indexes, so the failure left a partially updated bundle.The call site also fixed the quieter half:
fm_c.get("title") or p.stemsent a falsy-but-real title (0,false) to the file stem, so the catalog showed the wrong label.#52 — rg lineage paths
rg_list_files()resolves the paths it returns._inbound_via_rg()derivedsrcwithpath.relative_to(bundle), which raises when the bundle is addressed through a symlink alias. The handler silently continued, dropping a real lineage neighbor, while the pack still reportedreverse_index: rg.resolve_knowledge_root()returns an absolute--bundleverbatim, so this was reachable from the CLI:is_concept_path()on the line above already resolved both operands, so the boundary was inconsistent within one loop body.Verification
test_dekc.py36 pass,test_retrieval_ladder.py14 pass,test_isolation.pypasses. Both new tests are red when the two script files are stashed:🤖 Generated with Claude Code
https://claude.ai/code/session_01TZ1sCoZonCJw2oPbPcPioW