#451
fix(installer): allow blank optional AI agent limits
Summary
AI Agents Settings marks its numeric fields optional and .env.example leaves them blank, but saving rejects those blank values. As a result, changing an unrelated option fails with "Same Tool Call Threshold cannot be empty".
Allow empty numeric values to remain empty so the backend's existing defaults apply. Clearing an explicit override also restores that behavior. Explicit values retain integer parsing, normalization, and the existing range checks for all four limits.
Fixes #449.
Validation
- Added 37 regression cases through the real form and controller: saving an unrelated setting with blank defaults, clearing overrides, whitespace, valid boundaries, normalization, and invalid values for each numeric field.
- Confirmed the blank/default regression cases fail before the fix and pass afterward.
- Passed:
go test ./cmd/installer/wizard/models -run TestAIAgentsSettingsForm -count=1(Go 1.26.5, Windows). - Passed:
go vet ./cmd/installer/wizard/modelsandgit diff --check. - Attempted
go test ./cmd/installer/... -count=1; the full suite is not green locally due to missing generated embedded assets and Windows-specific failures (Unix permissions/symlinks, CGO SQLite, and file locking). Existing models-suite failures also reproduce with the original implementation; CRLF-sensitive Bedrock tests additionally fail in this Windows checkout. These unrelated areas are unchanged.