AntFleet

Disagreement · 0982a39f-openai-1

Admin scripts lack validation for required environment variables and fail with opaque errors when unset

solo GPT-5
repo e24ef98c·PR #6·reviewed 2 weeks ago

GPT-5 finding

Admin scripts lack validation for required environment variables and fail with opaque errors when unset

lowapi-contracthigh
  • apps/web/scripts/inspect-app-hook.ts:21-24
  • apps/web/scripts/inspect-app.ts:20-23
  • apps/web/scripts/inspect-finding-status.ts:12-18
Both GitHub App scripts use non-null assertions on critical env vars without verifying presence before use, and the DB inspection script relies on DATABASE_URL but does not validate it. When missing, these scripts will throw inside library code, producing less actionable errors.

Recommendation

Add explicit early checks with clear error messages and non-zero exits when required env vars are missing, e.g., validate GITHUB_APP_ID and GITHUB_APP_PRIVATE_KEY in the GitHub App scripts, and DATABASE_URL before importing/using the DB layer.

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 →

From the same review

These findings passed the unanimous gate on the same PR review. The disagreement above was filtered out; the findings below were posted.