Skip to content

fix: render scalar catalog titles and canonicalize rg lineage paths (#51) (#52) - #53

Merged
RichardHightower merged 2 commits into
mainfrom
fix/scalar-title-and-rg-paths
Aug 31, 2026
Merged

fix: render scalar catalog titles and canonicalize rg lineage paths (#51) (#52)#53
RichardHightower merged 2 commits into
mainfrom
fix/scalar-title-and-rg-paths

Conversation

@RichardHightower

Copy link
Copy Markdown
Contributor

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 with title: 421 aborted refresh_catalog_index() with AttributeError. 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.stem sent 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() derived src with path.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 reported reverse_index: rg.

resolve_knowledge_root() returns an absolute --bundle verbatim, so this was reachable from the CLI:

--rg     reverse_index=rg   nodes=['/tables/root.md']
--no-rg  reverse_index=scan nodes=['/tables/caller.md', '/tables/root.md']

is_concept_path() on the line above already resolved both operands, so the boundary was inconsistent within one loop body.

Verification

test_dekc.py 36 pass, test_retrieval_ladder.py 14 pass, test_isolation.py passes. Both new tests are red when the two script files are stashed:

ERROR: test_yaml_scalar_titles_render_as_text (title='integer')
FAIL:  test_yaml_scalar_titles_render_as_text (title='boolean')
FAIL:  test_yaml_scalar_titles_render_as_text (title='zero')
FAIL:  test_lineage_pack_survives_a_symlink_aliased_bundle

🤖 Generated with Claude Code

https://claude.ai/code/session_01TZ1sCoZonCJw2oPbPcPioW

RichardHightower and others added 2 commits August 31, 2026 13:43
) (#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
@RichardHightower
RichardHightower merged commit e7c2f7d into main Aug 31, 2026
1 check passed
@RichardHightower
RichardHightower deleted the fix/scalar-title-and-rg-paths branch August 31, 2026 18:47
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.

rg-backed lineage pack drops matches when the bundle path uses a symlink alias Catalog refresh crashes when a concept title is a YAML integer

1 participant