From d8643ee03aa9aaa953e26f0512292711260768c8 Mon Sep 17 00:00:00 2001 From: Evan Jarrett Date: Fri, 11 Sep 2026 10:54:18 -0500 Subject: [PATCH] config: describe what test_mode still controls The comments on server.test_mode predated the testmode build tag and still claimed the flag allows HTTP DID resolution (appview) or changes OAuth redirects (hold). Neither is true: DID resolution is decided at build time now, and the hold's OAuth redirect never read the flag. Say what remains behind the runtime switch on each side and point at the build tag for the rest. Only the comment lines in the example YAMLs are updated; the examples carry hand-edited values and are not regenerated. Co-Authored-By: Claude Fable 5.1 Claude-Session: https://claude.ai/code/session_01UwYzaG3Yy7uA8FbZ5qk3tQ --- config-appview.example.yaml | 2 +- config-hold.example.yaml | 2 +- pkg/appview/config.go | 2 +- pkg/hold/config.go | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/config-appview.example.yaml b/config-appview.example.yaml index b25eac1..071d8d3 100644 --- a/config-appview.example.yaml +++ b/config-appview.example.yaml @@ -25,7 +25,7 @@ server: addr: :5000 # Public-facing URL for OAuth callbacks and JWT realm. Auto-detected if empty. base_url: "" - # Allows HTTP (not HTTPS) for DID resolution and uses transition:generic OAuth scope. + # Local development only. Routes pushes to the default hold when the user's chosen hold is unreachable and quiets backfill warnings about external holds. Does not affect DID resolution: that needs a -tags testmode build. test_mode: false # Display name shown on OAuth authorization screens. client_name: AT Container Registry diff --git a/config-hold.example.yaml b/config-hold.example.yaml index 85b5985..76e8354 100644 --- a/config-hold.example.yaml +++ b/config-hold.example.yaml @@ -43,7 +43,7 @@ server: public: false # DID of successor hold for migration. Appview redirects all requests to the successor. successor: "" - # Use localhost for OAuth redirects during development. + # Local development only. Skips relay crawl requests (a local hold is not reachable by public relays) and tolerates an appview token issuer that differs from appview_did. Does not affect DID resolution: that needs a -tags testmode build. test_mode: false # Endpoints used for proactive scan discovery. MUST support com.atproto.sync.listReposByCollection. Also sent requestCrawl on startup (best-effort, in addition to built-in known relays). relay_endpoints: diff --git a/pkg/appview/config.go b/pkg/appview/config.go index 29209e4..d9bb37b 100644 --- a/pkg/appview/config.go +++ b/pkg/appview/config.go @@ -56,7 +56,7 @@ type ServerConfig struct { BaseURL string `yaml:"base_url" comment:"Public-facing URL for OAuth callbacks and JWT realm. Auto-detected if empty."` // Allows HTTP (not HTTPS) for DID resolution. - TestMode bool `yaml:"test_mode" comment:"Allows HTTP (not HTTPS) for DID resolution and uses transition:generic OAuth scope."` + TestMode bool `yaml:"test_mode" comment:"Local development only. Routes pushes to the default hold when the user's chosen hold is unreachable and quiets backfill warnings about external holds. Does not affect DID resolution: that needs a -tags testmode build."` // Display name shown on OAuth authorization screens. ClientName string `yaml:"client_name" comment:"Display name shown on OAuth authorization screens."` diff --git a/pkg/hold/config.go b/pkg/hold/config.go index cb98374..2b9763a 100644 --- a/pkg/hold/config.go +++ b/pkg/hold/config.go @@ -161,7 +161,7 @@ type ServerConfig struct { Successor string `yaml:"successor" comment:"DID of successor hold for migration. Appview redirects all requests to the successor."` // Use localhost for OAuth redirects during development. - TestMode bool `yaml:"test_mode" comment:"Use localhost for OAuth redirects during development."` + TestMode bool `yaml:"test_mode" comment:"Local development only. Skips relay crawl requests (a local hold is not reachable by public relays) and tolerates an appview token issuer that differs from appview_did. Does not affect DID resolution: that needs a -tags testmode build."` // Relay endpoints used primarily for proactive scan discovery via // com.atproto.sync.listReposByCollection. Endpoints listed here MUST