Skip to content

fix(artifacts): report S-record data after the final count - #14059

Closed
ShuaixinHuang wants to merge 4 commits into
morluto:mainfrom
ShuaixinHuang:fix/srec-data-after-count
Closed

ShuaixinHuang wants to merge 4 commits into
morluto:mainfrom
ShuaixinHuang:fix/srec-data-after-count

Conversation

@ShuaixinHuang

@ShuaixinHuang ShuaixinHuang commented Nov 23, 2026 •

Copy link
Copy Markdown
Contributor

Summary

Keep decoded S-record regions when data follows the last S5 or S6 count, and report that the last count covers only the preceding records.

Problem and change

REA already rejects counts that disagree with the number of preceding S1, S2 or S3 records. A final count can agree with that prefix while leaving trailing data uncounted. The first version of this PR rejected that input. The updated decoder preserves the regions and the declared count, then reports a limitation with the count line and the observed total. A subsequent valid count that covers all data clears the limitation. Termination still determines region coverage, and the output schema is unchanged.

Evidence and validation

  • GNU objcopy 2.44 accepted the exact S5 fixtures used in the regression, with and without a later final count. Running objcopy -I srec -O binary produced all 33 bytes, 00 through 1f followed by 2a. The extraction assertions check those bytes.
  • The same version of objcopy rejected the analogous S6 fixture with trailing data, and accepted the S6 control without trailing data. REA previously accepted both variants, and the revised PR preserves that behavior while recording the uncovered count. The portable regression does not require objcopy.
  • The revised artifact-reader regressions reproduced two failures against the previous PR head. All 21 reader tests and all 43 decoder tests passed after the change. Normal commit and push checks passed. Separately packaged CLI and MCP invocations were not run.

Conflict resolution

Merged current main and retained the S5/S6 extraction regressions alongside the upstream physical-run and lifecycle tests. All 65 focused tests passed.

Supersedes #12750.

Author readiness

Human owner: @ShuaixinHuang

  • I reviewed the final diff and relevant existing code, understand the change and its edge cases, and take responsibility for the complete PR, including AI-assisted work.
  • I checked the evidence above, confirmed it supports the current change, and recorded meaningful validation gaps.
  • I declare this PR ready for initial maintainer review.

@greptile-apps

greptile-apps Bot commented Nov 23, 2026 •

Copy link
Copy Markdown
Contributor

RetriggerView in GreptileConfidence Score: 5/5

[Medium impact] The changes appear safe to merge; no actionable issue was found.

Summary

Reports data after the final S5 or S6 count without discarding decoded regions or changing the output schema.

  • S-record regions keep data after a count and report uncovered records.

Reviews (1) · Last reviewed commit: "Merge upstream main into S-record count ..." · Reviewed by Greptile

@ShuaixinHuang
ShuaixinHuang marked this pull request as ready for review November 23, 2026 12:18
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Nov 23, 2026 •

Copy link
Copy Markdown
Codex Review Summary: ✅ Completed

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-11-23T12:24:09.379494Z 657a9cc Draft marked ready
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@morluto morluto added area: evidence Evidence, artifacts, and reconstruction bug Something isn't working labels Nov 26, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area: evidence Evidence, artifacts, and reconstruction bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants