fix(config): correct OIDC token-type/scopes env keys; address review round 1
- _DEFAULTS keys for NEXTCLOUD_OIDC_TOKEN_TYPE / NEXTCLOUD_OIDC_SCOPES were registered as oidc_* (uppercasing to OIDC_*), so dynaconf (ignore_unknown_envvars) never read the NEXTCLOUD_-prefixed env vars and the fields stayed at their defaults. Prefix the keys to match _field_map; add a regression test. - Add gte=1 validator for HEALTH_READY_REFRESH_INTERVAL and a 1..65535 range validator for PORT. - Tie ReadinessCache.ttl_seconds to 2x the configured refresh interval so is_stale() stays meaningful when the interval is tuned. - Raise the refresh-loop exception log from DEBUG to WARNING. - Make health_ready a sync handler (no awaits); dedupe the localhost fallback into _DEFAULT_MCP_SERVER_URL; use pytest.approx for the float default. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Opus 4.8
parent
6ef7786cec
commit
cc2ce6e853
@@ -18,7 +18,7 @@ def test_dependency_status_defaults():
|
||||
status = DependencyStatus(name="nextcloud")
|
||||
assert status.healthy is None # not yet checked
|
||||
assert status.detail == "pending"
|
||||
assert status.checked_at == 0.0
|
||||
assert status.checked_at == pytest.approx(0.0)
|
||||
|
||||
|
||||
def test_update_and_snapshot_round_trip():
|
||||
|
||||
Reference in New Issue
Block a user