Summary
Excerpt range normalization overwrites the requested range after applying context, line 0 is misdiagnosed as a missing start, and reading to EOF requires knowing the exact line count because overshoot is always fatal.
Audit IDs: Q-13, Q-32, and R-13. Reproduced with locally built cdidx v1.40.3 at 404db09489c305f17d94f37026e00564d3ac527a.
Existing issue relationship
No exact existing issue was found.
Expected behavior and PR scope
Preserve requested versus effective ranges, validate one-based inputs accurately, and add an explicit EOF and/or clamp mode without changing strict numeric defaults. These belong to one excerpt range parser/response PR.
Implementation guide for Codex 5.6 sol xhigh
- Model requested start/end, context expansion, effective clamped range, and total lines as separate values.
- Return a one-based invalid-range error for zero/negative inputs.
- Support a documented
--end eof, --all, or explicit clamp flag; do not silently clamp strict numeric requests.
- Cover empty/one-line/newline/non-newline files, context at boundaries, overshoot, inline
file:line, Unicode, and JSON recovery metadata.
- Add focused regression/contract tests, run the full net8.0 and net9.0 suite, and add the required bilingual
changelog.d/unreleased/ fragment.
Acceptance criteria
- Requested 18–22 with context 2 reports requested 18–22 and effective 16–24.
- Line 0 receives the correct range taxonomy.
- Callers can explicitly read to EOF/clamp and strict behavior remains backward compatible.
Summary
Excerpt range normalization overwrites the requested range after applying context, line 0 is misdiagnosed as a missing start, and reading to EOF requires knowing the exact line count because overshoot is always fatal.
Audit IDs: Q-13, Q-32, and R-13. Reproduced with locally built cdidx v1.40.3 at
404db09489c305f17d94f37026e00564d3ac527a.Existing issue relationship
No exact existing issue was found.
Expected behavior and PR scope
Preserve requested versus effective ranges, validate one-based inputs accurately, and add an explicit EOF and/or clamp mode without changing strict numeric defaults. These belong to one excerpt range parser/response PR.
Implementation guide for Codex 5.6 sol xhigh
--end eof,--all, or explicit clamp flag; do not silently clamp strict numeric requests.file:line, Unicode, and JSON recovery metadata.changelog.d/unreleased/fragment.Acceptance criteria