feat(config): make gate reconcile timings configurable - #862
Conversation
Wrap Available() failures so context deadlines and a missing gh binary are not reported as "gh CLI is not authenticated". Co-authored-by: Cursor <cursoragent@cursor.com>
Confidence Score: 5/5The PR appears safe to merge. The previously reported cancellation misclassification is fixed by reporting a canceled context as an interruption while preserving Reviews (4): Last reviewed commit: "no-mistakes: apply agent fixes" | Re-trigger Greptile |
Expose gate_reconcile_interval and gate_reconcile_timeout as global-only settings (defaults 2m / 30s) so operators can raise the parked-approval reconcile budget for slow host probes without changing the executor. Co-authored-by: Cursor <cursoragent@cursor.com>
|
Speaking as Kun's firstmate: First look at HEAD VISION.md:
|
Intent
Make the parked approval-gate reconcile interval and per-attempt timeout configurable via global config (gate_reconcile_interval / gate_reconcile_timeout), so operators can raise the budget for slow gh auth probes without hardcoding 2m/30s in the executor.
Fixes #833
What Changed
gate_reconcile_interval(default2m) andgate_reconcile_timeout(default30s) so operators can raise the parked approval-gate reconcile budget without hardcoding timings in the executor.gh auth statusavailability probes report timeout, interruption, and missing-binary failures distinctly from authentication failure, with docs updated for the new knobs and error distinction.Risk Assessment
✅ Low: Global-only duration knobs are parsed fail-closed, merged into Config, and applied by NewExecutor with the prior 2m/30s defaults preserved, while the gh Available change only clarifies timeout/cancel/missing-binary errors without altering success paths.
Testing
Verified global config parsing/defaults, repo-config inertness, invalid rejection, and that config.yaml timings are applied by NewExecutor to the reconcile interval/timeout path. Targeted tests and an operator example load (5m/2m) all passed.
Evidence: operator global config example (5m / 2m)
Evidence: LoadGlobal+Merge operator path transcript
operator config.yaml loaded: gate_reconcile_interval=5m0s gate_reconcile_timeout=2m0sEvidence: NewExecutor applies config timings to reconcile
PASS TestExecutor_AppliesGateReconcileTimingsFromGlobalConfig; PASS TestExecutor_AppliesGateReconcileIntervalFromGlobalConfigPipeline
Updates from git push no-mistakes
✅ **intent** - passed
✅ No issues found.
✅ **Rebase** - passed
✅ No issues found.
✅ **Review** - passed
✅ No issues found.
✅ **Test** - passed
✅ No issues found.
go test -count=1 ./internal/config/ -run 'GateReconcile|DefaultConfigYAML_MatchesGoDefaults|LoadRepo_GateReconcile' -vgo test -count=1 ./internal/config/ -run 'TestLoadGlobal_GateReconcileTimings_OperatorSlowAuthBudget' -vgo test -count=1 ./internal/pipeline/ -run 'TestExecutor_AppliesGateReconcile(Timings|Interval)FromGlobalConfig' -vgo test -count=1 ./internal/pipeline/ -run 'AppliesGateReconcile|GateRecheckIsBounded|ReconcilesParkedGate' -vgate_reconcile_interval: 5m/gate_reconcile_timeout: 2mload+Merge verification recorded as evidence✅ **Document** - passed
✅ No issues found.
✅ **Lint** - passed
✅ No issues found.
✅ **Push** - passed
✅ No issues found.