Skip to content

fix: tolerate malformed evidence in evolution assessment - #98

Open
roodboi wants to merge 1 commit into
mainfrom
fix/evolve-assess-malformed-evidence
Open

roodboi wants to merge 1 commit into
mainfrom
fix/evolve-assess-malformed-evidence

Conversation

@roodboi

@roodboi roodboi commented Oct 27, 2026 •

Copy link
Copy Markdown
Contributor

fclt ai evolve assess --json crashed when a persisted writeback had no evidence array. Missing or non-array evidence now counts as empty, malformed entries produce an ID-bearing warning on stderr, and assessment JSON includes a warnings list. Good entries continue through assessment.

The shared loader also normalizes tags and issue links for sibling commands. The independent reconciliation reader uses the same normalization. Assessment leaves persisted queues unchanged, and repeated reads within one CLI invocation emit one warning per entry ID.

The malformed-entry tests live in the new src/ai-evolve-malformed.test.ts suite. The existing AI CLI and reconciliation test files are unchanged.

Validation used fully isolated HOME and all four XDG directories, plus local quarantine-cleanup preloads:

  • ./scripts/test-safe.sh src/ai-evolve-malformed.test.ts: 12 passed.
  • ./scripts/test-safe.sh src/reconciliation.test.ts --test-name-pattern writeback: 8 passed.
  • Full AI suites and the new suite on the identical source tree: 63 passed; one existing preflight context-resolution failure, also reproduced on base commit 3ad4959.
  • bun run type-check, bun run check, and git diff --check: passed.

Risks: assessment JSON gains an additive warnings field. This handles missing/non-array fields; it preserves existing validation of array members. CI and review are pending.

Claude (Fable 5.1) review pending until Oct 30 rate limit; Codex review requested


View with [code]smith Autofix with [code]smith
Need help on this PR? Tag @codesmith-bot with what you need.

roodboi commented Oct 27, 2026

Copy link
Copy Markdown
Contributor Author

@codex review

Please review malformed writeback array handling, warning deduplication, and preservation of valid-entry assessment. Regression coverage is in the new src/ai-evolve-malformed.test.ts suite.

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Oct 27, 2026 •

Copy link
Copy Markdown

Codex Review Summary

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

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-10-27T13:45:54.807447Z af4aab3 Manual request
ℹ️ 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.

@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. More of your lovely PRs please.

Reviewed commit: af4aab3592

ℹ️ 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".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

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.

1 participant