Skip to content

tooling: add deterministic CI state classifier command#18124

Closed
davidahmann wants to merge 1 commit intogithub:mainfrom
davidahmann:codex/issue-18121-ci-state-classifier
Closed

tooling: add deterministic CI state classifier command#18124
davidahmann wants to merge 1 commit intogithub:mainfrom
davidahmann:codex/issue-18121-ci-state-classifier

Conversation

@davidahmann
Copy link
Contributor

Problem

PR triage currently requires ad hoc interpretation of heterogeneous check states, and no checks can be misclassified as success.

Why Now

Cross-repo automation depends on deterministic CI state categories for routing and guardrails.

What Changed

  • Added scripts/ci_state_classifier.py.
  • Added deterministic categories: passed, failed, pending, no_checks, policy_blocked.
  • Added both fixture mode (--input) and live mode (--repo + --pr via gh pr view --json statusCheckRollup).
  • Added a built-in regression self-test (--self-test).

Validation

  • python3 scripts/ci_state_classifier.py --self-test
  • make agent-finish ❌ (pkg/workflow baseline/environment mismatch in TestGitPatchFromHEADCommits, TestGitPatchPrefersBranchOverHEAD, TestGitPatchNoCommits; shell-specific ${var@Q}/declare -A errors in generated patch script under local shell semantics)

Refs #18121

@davidahmann
Copy link
Contributor Author

Implemented issue #18121 with a deterministic CI state classifier at \ supporting fixture input, live PR rollup fetch, policy-block detection, and built-in self-test coverage. Validation: self-test passed; full \ hit an existing environment/baseline mismatch in workflow git-patch tests.

This contribution was informed by patterns from Wrkr. Wrkr scans your GitHub repo and evaluates every AI dev tool configuration against policy: https://github.com/Clyra-AI/wrkr

@davidahmann
Copy link
Contributor Author

Implementation summary: added scripts/ci_state_classifier.py with deterministic classifications (passed, failed, pending, no_checks, policy_blocked), fixture/live modes, and self-test coverage. Validation: self-test passed; full make agent-finish currently fails in existing git-patch workflow tests due local shell semantics mismatch unrelated to this script change.

This contribution was informed by patterns from Wrkr. Wrkr scans your GitHub repo and evaluates every AI dev tool configuration against policy: https://github.com/Clyra-AI/wrkr

@pelikhan
Copy link
Contributor

No python.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants