fix(controller): absent telemetry must stay an untyped nil - #68
Merged
Conversation
FromEnvironment yields a typed-nil *Exporter when GDS_OTLP_ENDPOINT is unset, and main stored it straight into the service's TelemetryFlusher interface -- so the nil guard passed, the flush loop spawned, and the first tick panicked on a nil receiver. Measured live on the estate controller's first real run: one successful reconciliation, one backup, then a crash loop every ten seconds. The seam now keeps absence as an untyped nil, and the test pins exactly that. Claude-Session: https://claude.ai/code/session_01LsGid6U5RrQdFvJmvYdGCF
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
First live run of gds-controller on the estate: runtime loaded, state opened, one reconciliation succeeded, one backup landed — then
panic: value method telemetry.Exporter.Flush called using nil *Exporter pointerevery RestartSec.FromEnvironmentreturns a typed-nil*ExporterwithoutGDS_OTLP_ENDPOINT; main stored it in theTelemetryFlusherinterface field, defeatingService.Run's nil guard. The seam (telemetryFlusher) now keeps absence untyped; the test pins it.core/operationsis unaffected (concrete-typed field).https://claude.ai/code/session_01LsGid6U5RrQdFvJmvYdGCF