Skip to content

fix: preserve complete README_AI sections when truncating - #179

Merged
dreamlx merged 1 commit into
masterfrom
fix/readme-truncation-boundary
Aug 18, 2026
Merged

fix: preserve complete README_AI sections when truncating#179
dreamlx merged 1 commit into
masterfrom
fix/readme-truncation-boundary

Conversation

@dreamlx

@dreamlx dreamlx commented Aug 18, 2026

Copy link
Copy Markdown
Owner

Closes #178

Summary

  • retain the 10KB navigation budget, including the truncation notice
  • truncate at complete Markdown heading boundaries (## through ######), so detailed ### file symbol lists are never cut mid-item
  • replace the misleading per-module README hint with a source-reading next step
  • cover detailed-section regression and strict byte-budget behavior

Verification

  • pytest tests/writers/test_utils.py tests/test_smart_writer.py -q — 37 passed
  • ruff check src/ tests/ — passed
  • full suite with current source in a clean test worktree — 1788 passed, 13 skipped

Note: running the full suite from this developer checkout is contaminated by its ignored .codeindex.yaml (it enables extra languages and invalidates four default-language tests); the clean-worktree run avoids changing that user-local config.

@dreamlx
dreamlx merged commit f089f98 into master Aug 18, 2026
8 checks passed
@dreamlx
dreamlx deleted the fix/readme-truncation-boundary branch August 18, 2026 08:10
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.

fix: truncate detailed README_AI at complete file-section boundaries

1 participant