Recover once from invalid CLI review responses and report safe validation details #30

Closed
opened 2026-10-08 07:11:36 +01:00 by nimmo · 1 comment
Owner

nixos-config MR #286's AI review run #1116 attempt 2 failed before publication with Agent CLI produced a missing, invalid, or oversized review artifact. Runs #1125 and #1126 succeeded on the same head; captured #1126 responses pass JSON/schema validation. The exact rejected output was deleted, so its specific defect is unknown. The earlier stale-secret authorization issue is resolved and separate.

Prepare a bounded retry for completed Pi/agent-cli responses that fail JSON or report-schema validation. Keep strict validation and fail without publishing after a second invalid report. Preserve the original timeout budget, use fresh temporary artifacts, and report safe JSON positions/schema requirements without exposing model output. Execution failures, missing/oversized artifacts and OpenCode event errors must not be retried.

Acceptance: regression tests cover successful recovery, attempt/timeout bounds, fresh artifacts, log privacy and non-retryable failures; existing tests remain green. Publish through a dedicated branch/MR, then verify a live run before closing.

Evidence: https://git.nimmog.uk/nimmo/nixos-config/actions/runs/1116 and https://git.nimmog.uk/nimmo/nixos-config/actions/runs/1126

nixos-config MR #286's AI review run #1116 attempt 2 failed before publication with `Agent CLI produced a missing, invalid, or oversized review artifact`. Runs #1125 and #1126 succeeded on the same head; captured #1126 responses pass JSON/schema validation. The exact rejected output was deleted, so its specific defect is unknown. The earlier stale-secret authorization issue is resolved and separate. Prepare a bounded retry for completed Pi/agent-cli responses that fail JSON or report-schema validation. Keep strict validation and fail without publishing after a second invalid report. Preserve the original timeout budget, use fresh temporary artifacts, and report safe JSON positions/schema requirements without exposing model output. Execution failures, missing/oversized artifacts and OpenCode event errors must not be retried. Acceptance: regression tests cover successful recovery, attempt/timeout bounds, fresh artifacts, log privacy and non-retryable failures; existing tests remain green. Publish through a dedicated branch/MR, then verify a live run before closing. Evidence: https://git.nimmog.uk/nimmo/nixos-config/actions/runs/1116 and https://git.nimmog.uk/nimmo/nixos-config/actions/runs/1126
Author
Owner

Resolved by MR #31, merged as 3d47eea7de203857f8b3ca6d64e92390e9df3cbd.

Validation: 70 unit tests passed with one existing skip. Tests cover recovery from invalid reports, attempt/timeout limits, fresh artifacts, safe diagnostics and non-retryable failures. MR CI also passed.

Live nixos-config run #1127 was verified to load the merged retry implementation. Both review passes and formal publication succeeded, producing a Ready to merge review. The live run did not require a retry; recovery from invalid output is verified by regression tests rather than that live run.

The operator accepted this validation and explicitly authorized closure. Closing as complete.

Resolved by [MR #31](https://git.nimmog.uk/nimmo/forgejo-auto-pr-review/pulls/31), merged as `3d47eea7de203857f8b3ca6d64e92390e9df3cbd`. Validation: 70 unit tests passed with one existing skip. Tests cover recovery from invalid reports, attempt/timeout limits, fresh artifacts, safe diagnostics and non-retryable failures. MR CI also passed. [Live nixos-config run #1127](https://git.nimmog.uk/nimmo/nixos-config/actions/runs/1127) was verified to load the merged retry implementation. Both review passes and formal publication succeeded, producing a [Ready to merge review](https://git.nimmog.uk/nimmo/nixos-config/pulls/286#issuecomment-2683). The live run did not require a retry; recovery from invalid output is verified by regression tests rather than that live run. The operator accepted this validation and explicitly authorized closure. Closing as complete.
nimmo closed this issue 2026-10-08 08:00:30 +01:00
Sign in to join this conversation.
No labels
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
nimmo/forgejo-auto-pr-review#30
No description provided.