AntFleet

Disagreement · 24879b45-anthropic-2

Cron sweep route returns 200 even when sweep results are degraded (no per-section status surfacing)

solo Opus
repo e24ef98c·PR #10·reviewed 1 week ago

Opus finding

Cron sweep route returns 200 even when sweep results are degraded (no per-section status surfacing)

lowmaintainabilityhigh
  • apps/web/app/api/cron/sweep/route.ts:78-92
The outgoing PR poll silently degrades to null on any failure (token missing, db down, GitHub 500). The cron response simply omits the field with no indication of degradation, making it impossible for monitoring/alerting to distinguish 'no work to do' from 'this subsystem is broken'. The runOutgoingPrsPoll wrapper does call logError, but the JSON response gives no signal.

Recommendation

Either include `outgoingPrs: null` explicitly with a `degraded: true` flag, or expose a structured `{status: 'ok'|'skipped'|'failed', reason}` field for each sub-section (sweep, onboarder, outgoingPrs) so observability tooling can alert on persistent silent failures.

Other reviewer

The other reviewer flagged nothing in this file/line range.

Why this didn't post

This finding didn't meet AntFleet's unanimous agreement threshold. Both frontier models review every PR independently; only findings they both flag with the same severity and category are posted to the PR. This one fell through.

read the methodology →