Skip to content

fix(runner): list codex in the /health harnesses payload - #5715

Open
WahidSaeed wants to merge 2 commits into
Agenta-AI:mainfrom
WahidSaeed:fix/5693-health-missing-codex-harness
Open

fix(runner): list codex in the /health harnesses payload#5715
WahidSaeed wants to merge 2 commits into
Agenta-AI:mainfrom
WahidSaeed:fix/5693-health-missing-codex-harness

Conversation

@WahidSaeed

@WahidSaeed WahidSaeed commented Aug 3, 2026

Copy link
Copy Markdown

Summary

  • The runner's HARNESS_KINDS list in services/runner/src/version.ts was not extended when Codex became a harness of its own (its own model catalog, its own CODEX_HOME setup, routed through run-plan.ts like pi_core/claude/pi_agenta).
  • Its only consumer is runnerInfo().harnesses, surfaced on GET /health — nothing is gated on the list, but a client probing /health concludes Codex is unsupported on a runner where it actually works.

Fixes #5693

Demo

Backend-only, non-visual change (one string added to a hardcoded array) — the demo below is real captured output: the actual pre-fix line (git show of the base commit), the actual runnerInfo() JSON after the fix (run directly against the fixed code), and the actual passing test run for version.test.ts.

before/after /health payload and passing test run

Test plan

  • Added services/runner/tests/unit/version.test.ts asserting HARNESS_KINDS includes codex and runnerInfo().harnesses surfaces it.
  • pnpm vitest run --project unit: 1479/1479 tests pass across 97 files (full runner unit suite, not just the new file).
  • tsc --noEmit: no errors.

HARNESS_KINDS in version.ts was not extended when Codex became a
harness of its own (its own model catalog, its own CODEX_HOME setup,
routed through run-plan.ts like the others). Its only consumer is the
/health payload, so nothing was gated on the omission, but a client
probing /health concluded Codex was unsupported on this runner.

Fixes Agenta-AI#5693
@dosubot dosubot Bot added the size:XS This PR changes 0-9 lines, ignoring generated files. label Aug 3, 2026
@vercel

vercel Bot commented Aug 3, 2026

Copy link
Copy Markdown

@WahidSaeed is attempting to deploy a commit to the agenta projects Team on Vercel.

A member of the Team first needs to authorize it.

@github-actions

github-actions Bot commented Aug 3, 2026

Copy link
Copy Markdown
Contributor

✅ Thanks @WahidSaeed! This PR now meets the contribution requirements and has been reopened. A maintainer will review it soon.

@github-actions github-actions Bot added the incomplete-pr PR is missing required template sections or a demo recording label Aug 3, 2026
@github-actions github-actions Bot closed this Aug 3, 2026
@CLAassistant

CLAassistant commented Aug 3, 2026

Copy link
Copy Markdown

CLA assistant check
All committers have signed the CLA.

@coderabbitai

coderabbitai Bot commented Aug 3, 2026

Copy link
Copy Markdown

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro Plus

Run ID: ab1b2f9e-8be7-4fff-a785-5a64b0b56495

📥 Commits

Reviewing files that changed from the base of the PR and between 69e2165 and e958f13.

⛔ Files ignored due to path filters (1)
  • .github/pr-assets/5693-health-codex-harness.png is excluded by !**/*.png
📒 Files selected for processing (2)
  • services/runner/src/version.ts
  • services/runner/tests/unit/version.test.ts

📝 Walkthrough

Summary by CodeRabbit

  • New Features

    • Added Codex as a supported runner harness.
    • Codex is now included in runner health information, making its availability visible in service status details.
  • Tests

    • Added coverage confirming Codex support and its inclusion in health reporting.

Walkthrough

The runner now includes codex in HARNESS_KINDS. Unit tests verify that HARNESS_KINDS and runnerInfo().harnesses expose Codex.

Changes

Codex harness identity

Layer / File(s) Summary
Harness identity and validation
services/runner/src/version.ts, services/runner/tests/unit/version.test.ts
The exported harness list includes codex. Unit tests verify the list and the runner health identity payload.

Estimated code review effort: 1 (Trivial) | ~5 minutes

Possibly related PRs

  • Agenta-AI/agenta#5706: Both PRs update harness-kind handling and tests, but use different code paths.
  • Agenta-AI/agenta#5716: This PR makes the same HARNESS_KINDS update and validates its health payload exposure.
🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly states that the runner health payload now lists Codex as a harness.
Description check ✅ Passed The description explains the missing Codex health entry, the implementation, and the validation performed.
Linked Issues check ✅ Passed The changes add codex to HARNESS_KINDS and verify that runnerInfo().harnesses exposes it, satisfying issue #5693.
Out of Scope Changes check ✅ Passed The changes are limited to the health harness list and focused unit tests required by issue #5693.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
✨ Finishing Touches 💡 1
🛠️ Fix failing CI checks 💡
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@WahidSaeed

Copy link
Copy Markdown
Author

Hi maintainers — this PR was auto-closed for missing a demo, but I think it's a mismatch between the bot and the written policy: CONTRIBUTING.md and the first-pr guide both say a demo is required for UI/UX changes, and that non-visual changes should mark the demo section "not applicable." This change is a one-line addition to a hardcoded string array (HARNESS_KINDS in services/runner/src/version.ts) surfaced verbatim on GET /health — there's no UI or visual behavior to record.

The PR description already includes the concrete before/after of the only observable output (the /health JSON payload) plus full test evidence (1479/1479 unit tests passing, new regression test, clean typecheck). Happy to add anything else that would help review — could a maintainer take a look and reopen if this qualifies for the non-visual exemption?

Real captured output: git show of the pre-fix HARNESS_KINDS line,
the actual runnerInfo() JSON after the fix, and the actual passing
vitest run for version.test.ts. Rendered to PNG via headless Chrome
for the PR's required demo image.
@github-actions github-actions Bot removed the incomplete-pr PR is missing required template sections or a demo recording label Aug 3, 2026
@github-actions github-actions Bot reopened this Aug 3, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Backend size:XS This PR changes 0-9 lines, ignoring generated files. tests

Projects

None yet

Development

Successfully merging this pull request may close these issues.

(bug) The runner's /health endpoint doesn't list codex as a harness

2 participants