Repository navigation
mcpx: effect probe for daemon.address (#8468 chain 1 of 23) - #11270
Conversation
Codex Review Summary: ❌ FailedThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
|
Warning Review limit reachedYou've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository. Next included review available in 24 minutes. View limit details
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. |
|
You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard. |
Moves daemon.address from EffectExemptions to EffectProbes with TestDaemonAddressIsReachableFromTheEnvironment: two harness daemons (ephemeral ports, so no collision) at the default and at MCPX_DAEMON_ADDRESS=0.0.0.0 report loopback vs wildcard endpoints, and the widened endpoint answers /v1/health. EffectExemptionPin ratchets 213 -> 212, the feature_coverage exemption line is deleted, and docs/environment.md is regenerated (pre-existing staleness: separator formatting only, verified failing on HEAD).
abb4675 to
334db39
Compare
What
Burn-down #8468, chain 1 of 23:
daemon.addressgains a real effect probe, and its exemptions come out.pkgs/mcpx/internal/settings/effect.go:daemon.addressmoves fromEffectExemptionstoEffectProbes(TestDaemonAddressIsReachableFromTheEnvironment);EffectExemptionPinratchets 213 → 212.pkgs/mcpx/internal/e2e/effect_test.go: mirror entry,effectProbeFuncsanchor, and the probe itself.pkgs/mcpx/internal/e2e/feature_coverage_exemptions.txt: thesetting daemon.addressline is deleted (the mcpx testing: inventory every feature against its integration tests, and guard that each has one #1978 guard fails on an exemption for a covered feature, so the deletion is self-verifying against the full-suite ledger).pkgs/mcpx/docs/environment.md: regenerated with the settings doc test's-update. Pre-existing staleness, verified failing on unmodified HEAD too — the only content difference is the table separator formatting; every row's text is unchanged. Included so the settings suite is green.The probe
The exemption claimed a bind address is "a network identity the isolated harness cannot vary deterministically". It can:
daemon.portdefaults to 0 (ephemeral), so two harness daemons bind different addresses without colliding, and the daemon reports the endpoint it bound.The probe starts one daemon at the default and one with
MCPX_DAEMON_ADDRESS=0.0.0.0, reads each daemon's reported endpoint viamcpx --json status, and asserts: loopback host at the default; an unspecified (wildcard) host with the setting — and the widened endpoint really answersGET /v1/health. This also supersedes the earlier cross-platform concern about needing a second loopback alias (127.0.0.2): no alias is involved, the comparison is loopback vs wildcard, which behaves the same on every platform Go supports.Verification
go test ./internal/settings/ -count=1— pass (includes the effect-coverage guard and the lowered pin).go test ./internal/e2e/ -run 'TestEffectProbeDeclarationsMatchTheProbesThatExist|TestDaemonAddressIsReachableFromTheEnvironment' -count=1— pass.go test ./internal/e2e/ -count=1 -timeout 60mon the shared dev laptop: the probe passed inside the full run and the run's coverage ledger (803 rows) contains{"test":"TestDaemonAddressIsReachableFromTheEnvironment","kind":"setting","name":"daemon.address"}. The run itself reported unrelated load flakes (restart/disambiguation/concurrency timing tests, plus the mcpx testing: e2e inherits the caller's environment -- build it from an allowlist so tests never reach the user's daemon #1992 caller-daemon check tripped by a second lane's suite running concurrently on the same machine), so guardedMain skipped its end-of-run evaluation.TestFeatureCoverageGuardAgainstRecordedLedger), same ledger both ways: with the baseline exemption file — 3 violations, includingsetting daemon.address is both exercised and exempt; with this PR — 2 violations (cli want,setting script.language, both pre-existing artifacts of rows lost to the flaked tests, identical in the baseline run) and no daemon.address violation. The deletion removes exactly the violation the probe creates, and adds none.Chain: on merge, the chain-2 packet (
daemon.autostart) is enqueued under the same dedupe key; issue #8468 stays open until chain 23 lands.🤖 Queue task 20149, lane any-g.