From 49ed417f6a45d5ab4e08a2f0c62ab8a22aa23b31 Mon Sep 17 00:00:00 2001 From: Drewry Pope Date: Sun, 22 Nov 2026 18:26:54 -0600 Subject: [PATCH] test(mcpx): probe remaining script setting exemptions --- pkgs/mcpx/internal/e2e/effect_test.go | 160 ++++++++++++++++++ .../e2e/feature_coverage_exemptions.txt | 4 - pkgs/mcpx/internal/settings/effect.go | 48 +++--- 3 files changed, 184 insertions(+), 28 deletions(-) diff --git a/pkgs/mcpx/internal/e2e/effect_test.go b/pkgs/mcpx/internal/e2e/effect_test.go index e34b6db46a..3e4357af3b 100644 --- a/pkgs/mcpx/internal/e2e/effect_test.go +++ b/pkgs/mcpx/internal/e2e/effect_test.go @@ -58,6 +58,10 @@ var implementedEffectProbes = map[string]string{ "script.devshell": "TestScriptDevshellIsReachableFromTheEnvironment", "script.captureConsole": "TestScriptCaptureConsoleOffDropsConsoleOutput", "script.check": "TestScriptTypecheckOnRefusesATypeError", + "script.checkOnError": "TestScriptCheckOnErrorDecidesOnACheckError", + "script.importsCrossProject": "TestScriptImportsCrossProjectDecidesAForeignProjectEdge", + "script.importsOnMissing": "TestScriptImportsOnMissingDecidesOnAMissingPackage", + "script.importsNetwork": "TestScriptImportsNetworkDecidesWhetherToPinAnUndeclaredPackage", "logging.file": "TestLoggingFileOffWritesNoDurableLog", "plumbing.strictUnknownKeys": "TestStrictUnknownKeysRefusesATypo", "paths.state": "TestStateDirectoryIsReachableAsASetting", @@ -291,6 +295,10 @@ var effectProbeFuncs = map[string]func(*testing.T){ "TestScriptDevshellIsReachableFromTheEnvironment": TestScriptDevshellIsReachableFromTheEnvironment, "TestScriptPrefixIsReachableFromTheEnvironment": TestScriptPrefixIsReachableFromTheEnvironment, "TestScriptTypecheckOnRefusesATypeError": TestScriptTypecheckOnRefusesATypeError, + "TestScriptCheckOnErrorDecidesOnACheckError": TestScriptCheckOnErrorDecidesOnACheckError, + "TestScriptImportsCrossProjectDecidesAForeignProjectEdge": TestScriptImportsCrossProjectDecidesAForeignProjectEdge, + "TestScriptImportsOnMissingDecidesOnAMissingPackage": TestScriptImportsOnMissingDecidesOnAMissingPackage, + "TestScriptImportsNetworkDecidesWhetherToPinAnUndeclaredPackage": TestScriptImportsNetworkDecidesWhetherToPinAnUndeclaredPackage, "TestSearchLimitCapsTheResults": TestSearchLimitCapsTheResults, "TestStateDirectoryIsReachableAsASetting": TestStateDirectoryIsReachableAsASetting, "TestStrictUnknownKeysRefusesATypo": TestStrictUnknownKeysRefusesATypo, @@ -595,6 +603,158 @@ func TestScriptTypecheckOnRefusesATypeError(t *testing.T) { } } +// TestScriptCheckOnErrorDecidesOnACheckError is the effect probe for +// script.checkOnError. A script with a type error is checked under Deno. +// Oracle: by default (fail) the run stops before running and reports the +// error; warn reports it and still runs; run stays quiet and runs. +func TestScriptCheckOnErrorDecidesOnACheckError(t *testing.T) { + testsupport.RequireBinary(t, "deno") + e := newEnv(t, oneServer) + script := filepath.Join(e.dir, "bad.ts") + src := "const n: number = \"not a number\";\n" + + "export default function () { return n; }\n" + if err := os.WriteFile(script, []byte(src), 0o644); err != nil { + t.Fatal(err) + } + e.setenv("MCPX_SCRIPT_CHECK=types") + + if out, err := e.try("run", script); err == nil || !strings.Contains(out, "does not type check") { + t.Fatalf("default (fail) should refuse and report a type error (err=%v):\n%s", err, out) + } + + e.setenv("MCPX_SCRIPT_CHECK_ON_ERROR=warn") + out, err := e.try("run", script) + if err != nil { + t.Fatalf("warn should run the script: %v\n%s", err, out) + } + if !strings.Contains(out, "does not type check") || !strings.Contains(out, "not a number") { + t.Fatalf("warn should report the error and run the script:\n%s", out) + } + + e.setenv("MCPX_SCRIPT_CHECK_ON_ERROR=run") + out, err = e.try("run", script) + if err != nil { + t.Fatalf("run should run the script: %v\n%s", err, out) + } + if strings.Contains(out, "does not type check") || !strings.Contains(out, "not a number") { + t.Fatalf("run should stay quiet and run the script:\n%s", out) + } +} + +// TestScriptImportsCrossProjectDecidesAForeignProjectEdge is the effect +// probe for script.importsCrossProject. A script in one project imports a +// module from a second project whose manifest declares a package, so the +// cross-project policy decides whether that foreign subset is isolated, +// merged, or ignored. +func TestScriptImportsCrossProjectDecidesAForeignProjectEdge(t *testing.T) { + testsupport.RequireBinary(t, "deno") + e := newEnv(t, oneServer) + if err := os.MkdirAll(filepath.Join(e.dir, "a"), 0o755); err != nil { + t.Fatal(err) + } + if err := os.MkdirAll(filepath.Join(e.dir, "b"), 0o755); err != nil { + t.Fatal(err) + } + if err := os.WriteFile(filepath.Join(e.dir, "a", "main.ts"), []byte("import \"../b/helper.ts\";\nconsole.log(\"ran-main\")\n"), 0o644); err != nil { + t.Fatal(err) + } + if err := os.WriteFile(filepath.Join(e.dir, "b", "helper.ts"), []byte("import \"foreign-dep\";\nconsole.log(\"ran-helper\")\n"), 0o644); err != nil { + t.Fatal(err) + } + if err := os.WriteFile(filepath.Join(e.dir, "a", "package.json"), []byte(`{"dependencies":{}}`), 0o644); err != nil { + t.Fatal(err) + } + if err := os.WriteFile(filepath.Join(e.dir, "b", "package.json"), []byte(`{"dependencies":{"foreign-dep":"1.2.3"}}`), 0o644); err != nil { + t.Fatal(err) + } + script := filepath.Join(e.dir, "a", "main.ts") + e.setenv("MCPX_SCRIPT_CHECK=off") + e.setenv("MCPX_SCRIPT_IMPORTS_ON_MISSING=install") + + run := func(mode string) string { + t.Helper() + e.setenv("MCPX_SCRIPT_IMPORTS_CROSS_PROJECT=" + mode) + out, _ := e.try("run", script) + return out + } + + if out := run("isolate"); !strings.Contains(out, "isolated dependency subset") { + t.Fatalf("isolate should report an isolated foreign subset:\n%s", out) + } + if out := run("merge"); !strings.Contains(out, "resolved dependency set includes") { + t.Fatalf("merge should fold the foreign package into the root set:\n%s", out) + } + if out := run("ignore"); !strings.Contains(out, "ignored import") { + t.Fatalf("ignore should report the ignored foreign import:\n%s", out) + } +} + +// TestScriptImportsOnMissingDecidesOnAMissingPackage is the effect probe +// for script.importsOnMissing. A script imports a package declared (but +// not installed) in its own manifest, so the missing-package policy +// decides whether the run stops, warns, or records the set. +func TestScriptImportsOnMissingDecidesOnAMissingPackage(t *testing.T) { + testsupport.RequireBinary(t, "deno") + e := newEnv(t, oneServer) + if err := os.WriteFile(filepath.Join(e.dir, "main.ts"), []byte("import \"foreign-dep\";\nconsole.log(\"ran\")\n"), 0o644); err != nil { + t.Fatal(err) + } + if err := os.WriteFile(filepath.Join(e.dir, "package.json"), []byte(`{"dependencies":{"foreign-dep":"1.2.3"}}`), 0o644); err != nil { + t.Fatal(err) + } + script := filepath.Join(e.dir, "main.ts") + e.setenv("MCPX_SCRIPT_CHECK=off") + e.setenv("MCPX_SCRIPT_IMPORTS_NETWORK=off") + + run := func(mode string) string { + t.Helper() + e.setenv("MCPX_SCRIPT_IMPORTS_ON_MISSING=" + mode) + out, _ := e.try("run", script) + return out + } + + if out := run("fail"); !strings.Contains(out, "unresolved import") || !strings.Contains(out, "but is not installed") { + t.Fatalf("fail should report an unresolved, not-installed import:\n%s", out) + } + if out := run("warn"); !strings.Contains(out, "dependency was not installed") { + t.Fatalf("warn should report a non-fatal missing dependency:\n%s", out) + } + if out := run("install"); !strings.Contains(out, "stage 2 records the set but does not install it") { + t.Fatalf("install should record the set without installing:\n%s", out) + } +} + +// TestScriptImportsNetworkDecidesWhetherToPinAnUndeclaredPackage is the +// effect probe for script.importsNetwork. A script imports a package +// with no manifest entry, so the network policy decides whether mcpx +// tries to pin it from the registry or refuses up front. +func TestScriptImportsNetworkDecidesWhetherToPinAnUndeclaredPackage(t *testing.T) { + testsupport.RequireBinary(t, "deno") + e := newEnv(t, oneServer) + if err := os.WriteFile(filepath.Join(e.dir, "main.ts"), []byte("import \"undeclared-pkg-xyz\";\nconsole.log(\"ran\")\n"), 0o644); err != nil { + t.Fatal(err) + } + if err := os.WriteFile(filepath.Join(e.dir, "package.json"), []byte(`{"dependencies":{}}`), 0o644); err != nil { + t.Fatal(err) + } + script := filepath.Join(e.dir, "main.ts") + e.setenv("MCPX_SCRIPT_CHECK=off") + e.setenv("MCPX_SCRIPT_IMPORTS_ON_MISSING=fail") + + if out, _ := func() (string, error) { + e.setenv("MCPX_SCRIPT_IMPORTS_NETWORK=off") + return e.try("run", script) + }(); !strings.Contains(out, "script.importsNetwork is off") { + t.Fatalf("off should refuse up front naming the disabled network:\n%s", out) + } + if out, _ := func() (string, error) { + e.setenv("MCPX_SCRIPT_IMPORTS_NETWORK=on") + return e.try("run", script) + }(); !strings.Contains(out, "cannot pin") { + t.Fatalf("on should attempt to pin (and report the outcome):\n%s", out) + } +} + // --- Surface: searching the catalog ----------------------------------- func TestSearchLimitCapsTheResults(t *testing.T) { diff --git a/pkgs/mcpx/internal/e2e/feature_coverage_exemptions.txt b/pkgs/mcpx/internal/e2e/feature_coverage_exemptions.txt index 85a61f1a52..b6a9e9328b 100644 --- a/pkgs/mcpx/internal/e2e/feature_coverage_exemptions.txt +++ b/pkgs/mcpx/internal/e2e/feature_coverage_exemptions.txt @@ -17,10 +17,6 @@ setting daemon.inlineStartPoll no integration-test exercise yet; burn-down #8468 setting daemon.tsnet.hostname no integration-test exercise yet; burn-down #8468 (settings daemon family); needs an EffectProbes entry + e2e test setting daemon.tsnetUpTimeout no integration-test exercise yet; burn-down #8468 (settings daemon family); needs an EffectProbes entry + e2e test setting http.streamBufferInit allocation-capacity hint only; output and line ceiling are unchanged, so allocation size has no stable e2e behavior oracle -setting script.checkOnError no integration-test exercise yet; burn-down #8474 (settings script family); needs an EffectProbes entry + e2e test -setting script.importsCrossProject no integration-test exercise yet; burn-down #8474 (settings script family); needs an EffectProbes entry + e2e test -setting script.importsNetwork no integration-test exercise yet; burn-down #8474 (settings script family); needs an EffectProbes entry + e2e test -setting script.importsOnMissing no integration-test exercise yet; burn-down #8474 (settings script family); needs an EffectProbes entry + e2e test setting protoTasks.cancelGrace no integration-test exercise yet; burn-down #8473 (settings proto family); needs an EffectProbes entry + e2e test setting plugin.annotate no integration-test exercise yet; burn-down #8472 (settings plugin family); needs an EffectProbes entry + e2e test setting plugin.backend no integration-test exercise yet; burn-down #8472 (settings plugin family); needs an EffectProbes entry + e2e test diff --git a/pkgs/mcpx/internal/settings/effect.go b/pkgs/mcpx/internal/settings/effect.go index 8a4b0eb64e..a68c18c104 100644 --- a/pkgs/mcpx/internal/settings/effect.go +++ b/pkgs/mcpx/internal/settings/effect.go @@ -105,6 +105,7 @@ var EffectProbes = map[string]string{ "events.history": "TestEventsHistoryBoundsTheReplay", "events.reconnect": "TestEventsReconnectWaitsForTheConfiguredDelay", "script.checkOnUnsupported": "TestScriptCheckOnUnsupportedDecidesWhatANonDenoCheckDoes", + "script.checkOnError": "TestScriptCheckOnErrorDecidesOnACheckError", "daemon.takeoverTimeout": "TestDaemonTakeoverTimeoutBoundsTheHandoverFromTheEnvironment", "daemon.socketProbeTimeout": "TestDaemonSocketProbeTimeoutDecidesWhetherALiveSocketIsStale", "logging.maxAge": "TestLoggingMaxAgeRotatesAnAgedFile", @@ -112,6 +113,9 @@ var EffectProbes = map[string]string{ "paths.config": "TestPathsConfigReadsAConfigOnlyThatPathHolds", "script.importsOnDynamic": "TestScriptImportsOnDynamicDecidesAComputedImport", "script.imports": "TestScriptImportsOffSkipsTheImportPipeline", + "script.importsCrossProject": "TestScriptImportsCrossProjectDecidesAForeignProjectEdge", + "script.importsOnMissing": "TestScriptImportsOnMissingDecidesOnAMissingPackage", + "script.importsNetwork": "TestScriptImportsNetworkDecidesWhetherToPinAnUndeclaredPackage", "prompt.runTimeout": "TestPromptRunTimeoutBoundsARecipeRun", "daemon.roots": "TestDaemonRootsAnswersAnUpstreamRootsRequest", "prompt.sampleTimeout": "TestPromptSampleTimeoutBoundsASamplingQuestion", @@ -262,35 +266,31 @@ var EffectProbes = map[string]string{ // covers it yet. An empty or missing reason is a violation, and the // count is pinned by EffectExemptionPin. var EffectExemptions = map[string]string{ - "script.importsOnMissing": "missing-package policies are covered by deterministic internal/preflight resolver tests; the e2e harness has no Deno graph fixture yet", - "script.importsCrossProject": "cross-project subset policies are covered by deterministic internal/preflight resolver tests; the e2e harness has no multi-project Deno graph fixture yet", - "script.importsNetwork": "registry lookup gating is covered by deterministic internal/preflight resolver tests; the e2e harness has no Deno graph fixture yet", - "script.checkOnError": "check failure policy is covered by deterministic internal/preflight stub-runtime tests; the e2e harness has no isolated checker fixture yet", - "daemon.tsnetUpTimeout": "tsnet bring-up needs a tailnet the harness does not have", - "daemon.tsnet.hostname": "daemon lifecycle, binding, or timing: its effect is a bound, an interval, or a network identity the isolated harness cannot vary deterministically", - "http.streamBufferInit": "Scanner allocation-capacity hint only; changing it does not change emitted events or line limits, and allocation size is not a stable e2e behavior oracle", - "embeddings.wasmPath": "embeddings backend: needs a live embeddings service or a wasm model fixture the harness does not provide", - "daemon.inlineStartPoll": "daemon lifecycle, binding, or timing: its effect is a bound, an interval, or a network identity the isolated harness cannot vary deterministically", - "plugin.bin": "read by the opencode plugin host (JS side); the Go e2e harness does not drive the plugin host", - "plugin.binArgs": "read by the opencode plugin host (JS side); the Go e2e harness does not drive the plugin host", - "plugin.backend": "read by the opencode plugin host (JS side); the Go e2e harness does not drive the plugin host", - "plugin.discoveryRetry": "read by the opencode plugin host (JS side); the Go e2e harness does not drive the plugin host", - "plugin.toolTiming": "read by the opencode plugin host (JS side); the Go e2e harness does not drive the plugin host", - "plugin.env": "read by the opencode plugin host (JS side); the Go e2e harness does not drive the plugin host", - "plugin.instructions": "read by the opencode plugin host (JS side); the Go e2e harness does not drive the plugin host", - "plugin.tools": "read by the opencode plugin host (JS side); the Go e2e harness does not drive the plugin host", - "plugin.remember": "read by the opencode plugin host (JS side); the Go e2e harness does not drive the plugin host", - "plugin.annotate": "read by the opencode plugin host (JS side); the Go e2e harness does not drive the plugin host", - "plugin.headless": "read by the opencode plugin host (JS side); the Go e2e harness does not drive the plugin host", - "plugin.daemonTools": "read by the opencode plugin host (JS side); the Go e2e harness does not drive the plugin host", - "plugin.disabledTools": "read by the opencode plugin host (JS side); the Go e2e harness does not drive the plugin host", - "protoTasks.cancelGrace": "task-store cancellation timing: covered by internal/tasks store tests, not by a settings with/without probe", + "daemon.tsnetUpTimeout": "tsnet bring-up needs a tailnet the harness does not have", + "daemon.tsnet.hostname": "daemon lifecycle, binding, or timing: its effect is a bound, an interval, or a network identity the isolated harness cannot vary deterministically", + "http.streamBufferInit": "Scanner allocation-capacity hint only; changing it does not change emitted events or line limits, and allocation size is not a stable e2e behavior oracle", + "embeddings.wasmPath": "embeddings backend: needs a live embeddings service or a wasm model fixture the harness does not provide", + "daemon.inlineStartPoll": "daemon lifecycle, binding, or timing: its effect is a bound, an interval, or a network identity the isolated harness cannot vary deterministically", + "plugin.bin": "read by the opencode plugin host (JS side); the Go e2e harness does not drive the plugin host", + "plugin.binArgs": "read by the opencode plugin host (JS side); the Go e2e harness does not drive the plugin host", + "plugin.backend": "read by the opencode plugin host (JS side); the Go e2e harness does not drive the plugin host", + "plugin.discoveryRetry": "read by the opencode plugin host (JS side); the Go e2e harness does not drive the plugin host", + "plugin.toolTiming": "read by the opencode plugin host (JS side); the Go e2e harness does not drive the plugin host", + "plugin.env": "read by the opencode plugin host (JS side); the Go e2e harness does not drive the plugin host", + "plugin.instructions": "read by the opencode plugin host (JS side); the Go e2e harness does not drive the plugin host", + "plugin.tools": "read by the opencode plugin host (JS side); the Go e2e harness does not drive the plugin host", + "plugin.remember": "read by the opencode plugin host (JS side); the Go e2e harness does not drive the plugin host", + "plugin.annotate": "read by the opencode plugin host (JS side); the Go e2e harness does not drive the plugin host", + "plugin.headless": "read by the opencode plugin host (JS side); the Go e2e harness does not drive the plugin host", + "plugin.daemonTools": "read by the opencode plugin host (JS side); the Go e2e harness does not drive the plugin host", + "plugin.disabledTools": "read by the opencode plugin host (JS side); the Go e2e harness does not drive the plugin host", + "protoTasks.cancelGrace": "task-store cancellation timing: covered by internal/tasks store tests, not by a settings with/without probe", } // EffectExemptionPin is the ratchet: the exemption count at the time // the guard landed. It may only ever be lowered, and only in the PR // that removes an exemption by adding the probe that replaces it. -const EffectExemptionPin = 23 // Shrunk 2026-11-21 (#8469): idle connection limits and timeout now assert actual connection reuse/expiry through configured clients. Shrunk 2026-11-21 (#8470): retention.stickyWindow now expires requested tools after its configured window. Earlier shrunk 2026-11-21 (#8470): events.reconnect now asserts retry delay after a dropped connection. Earlier shrunk 2026-11-21 (#8470): deps.autoInstall now asserts Bun's selected install policy. Earlier shrunk 2026-11-19 (#8467): output.color now has a PTY-backed interactive TUI probe. Earlier shrunk 2026-11-18 (#8473 chain 73): script.checkOnUnsupported is now probed under bun. Earlier shrunk 2026-11-18 (#8473 chain 72): daemon.takeoverTimeout gained a probe with a successor whose takeover dial cannot finish. Earlier shrunk 2026-11-18 (#8473 chain 71): daemon.socketProbeTimeout gained a probe with a second daemon started beside a live one. Earlier shrunk 2026-11-18 (#8473 chain 70): logging.maxAge gained a probe with a log file whose first record is two hours old. Earlier shrunk 2026-11-18 (#8473 chain 69): logstore.followBacklog gained a follow probe with a burst between two polls. Earlier shrunk 2026-11-18 (#8473 chain 68): paths.config gained a probe with a config planted only on the named path. Earlier shrunk 2026-11-18 (#8473 chain 67): script.importsOnDynamic and script.imports gained probes with a computed import() in exec source text, which needs no Deno graph. Earlier shrunk 2026-11-18 (#8473 chain 66): prompt.runTimeout gained a probe with a recipe that sleeps past a 1s bound. Earlier shrunk 2026-11-18 (#8473 chain 65): daemon.roots gained a probe through the ask fixture's new need_roots tool. Earlier shrunk 2026-11-18 (#8473 chain 64): prompt.sampleTimeout was orphaned since #2004; it is now the sampling question fallback when model.timeout is unset, and gained a probe. Earlier shrunk 2026-11-18 (#8473 chain 63): prompt.sample and prompt.catalogBudget gained probes on an unmatched prompt, the latter against the fake model endpoint. Earlier shrunk 2026-11-18 (#8473 chain 62): search.semantic and the remote embeddings settings gained probes against a fake OpenAI-compatible embeddings endpoint. Earlier shrunk 2026-11-18 (#8473 chain 61): proto.samplingPerMinute, proto.samplingSessionPerMinute and proto.elicitationPerMinute gained rate-limit probes driven by the ask fixture. Earlier shrunk 2026-11-18 (#8473 chain 60): sampling.answerLocally gained an upstream-sampling probe against the fake model endpoint. Earlier shrunk 2026-11-18 (#8473 chain 59): model.provider, baseURL, default, apiKeyEnv, budget, providers, profiles, timeout and prompt.maxTokens gained prompt-hook probes against a fake model endpoint. Earlier shrunk 2026-11-18 (#8473 chain 58): session.releaseTimeout gained an end-of-run release probe. Earlier shrunk 2026-11-18 (#8473 chain 57): daemon.idleExit gained an idle-daemon probe. Earlier shrunk 2026-11-18 (#8473 chain 56): daemon.port gained a bound-port probe. Earlier shrunk 2026-11-18 (#8473 chain 55): daemon.saveInterval gained a lease-table save probe. Earlier shrunk 2026-11-18 (#8473 chain 54): autostart.pollInterval gained a readiness-poll probe. Earlier shrunk 2026-11-18 (#8473 chain 53): daemon.leaseTTL gained a silent-caller probe. Earlier shrunk 2026-11-18 (#8473 chain 52): elicit.disambiguate and elicit.disambiguateDefault gained probes. Earlier shrunk 2026-11-18 (#8473 chain 51): elicit.ttl and elicit.maxAge gained probes, once upstream questions took their deadline from the broker. Earlier shrunk 2026-11-18 (#8473 chain 50): elicit.pendingLimit gained a probe, once `mcpx elicit list` honoured it. Earlier shrunk 2026-11-18 (#8473 chain 49): elicit.askTimeout gained a held-confirmation probe. Earlier shrunk 2026-11-18 (#8473 chain 48): artifacts.idleTtl and artifacts.maxAge gained touch-on-read probes. Earlier shrunk 2026-11-18 (#8473 chain 47): artifacts.ttl, artifacts.gcInterval, pool.min and autostart.idleExit gained probes. Earlier shrunk 2026-11-18 (#8473 chain 46): daemon.warm, pool.idleTimeout, daemon.reapInterval and daemon.endpoint gained probes. Earlier shrunk 2026-11-18 (#8473 chain 45): upstream.probeTimeout gained a probe, and upstream.eraCache and upstream.protocol were mapped to the era test, whose subtests run each with and without. Earlier shrunk 2026-11-18 (#8473 chain 44): prompt.autonomy, hooks.autonomy and repair.autonomy gained probes. Earlier shrunk 2026-11-18 (#8473 chain 43): policy.write, elicit.confirmDestructive and autonomy.max gained probes. Earlier shrunk 2026-11-18 (#8473 chain 42): daemon.inline, autostart.bin, autostart.args, autostart.logTail and daemon.watchConfig gained probes. Earlier shrunk 2026-11-18 (#8473 chain 41): daemon.inlineStartTimeout and daemon.probeTimeout gained probes. Earlier shrunk 2026-11-18 (#8473 chain 40): daemon.warmTimeout, autostart.connectTimeout and autostart.pingTimeout gained probes. Earlier shrunk 2026-11-18 (#8473 chain 39): pool.callTimeout, pool.startTimeout and daemon.refreshTimeout gained probes. Earlier shrunk 2026-11-18 (#8473 chain 38): doctor.timeout and registry.timeout gained probes that set a bound no request can meet. Earlier shrunk 2026-11-18 (#8473 chain 37): completion.maxValues gained a probe once the fake server could answer completions. Earlier shrunk 2026-11-18 (#8473 chain 36): catalog.instructions gained a probe once the fake server could serve instructions. Earlier shrunk 2026-11-18 (#8473 chain 35): the five plumbing source and launcher switches gained probes. Earlier shrunk 2026-11-18 (#8473 chain 34): artifacts.chunkBytes, script.launcher and paths.placeholders gained probes. Earlier shrunk 2026-11-18 (#8473 chain 33): artifacts.interceptImages and plumbing.indexOnQuery gained probes. Earlier shrunk 2026-11-18 (#8473 chain 32): plumbing.validatePaths and script.language gained probes. Earlier shrunk 2026-11-18 (#8473 chain 31): logging.trace and exec.where gained probes. Earlier shrunk 2026-11-18 (#8473 chain 30): paths.adapters and paths.apis gained declaration-file probes. Earlier shrunk 2026-11-18 (#8473 chain 29): script.runtime, runtimeOrder, permissions, profiles and runtimes gained node-backed probes. Earlier shrunk 2026-11-18 (#8473 chain 28): script.before, onSuccess, onError and suffix gained a run-phase probe. Earlier shrunk 2026-11-18 (#8473 chain 27): hooks, hooks.timeout, daemon.ui and daemon.uiDir gained probes. Earlier shrunk 2026-11-18 (#8473 chain 26): logging.level, format, source, dir, include, maxLines, maxBytes and keep gained durable-log probes. Earlier shrunk 2026-11-18 (#8473 chain 25): artifacts.enabled, maxBytes, quota, delivery, inlineMaxBytes and dir gained script-artifact probes. Earlier shrunk 2026-11-18 (#8473 chain 24): preset and serve.mode gained probes. Earlier shrunk 2026-11-18 (#8473 chain 23): presets gained a --preset probe. Earlier shrunk 2026-11-18 (#8473 chain 22): catalog.budget and catalog.bias gained `mcpx catalog` probes. Earlier shrunk 2026-11-18 (#8473 chain 21): catalog.pinnedTools and retention.maxTools gained reactive-session probes. Earlier shrunk 2026-11-18 (#8473 chain 20): diagnose.history and diagnose.preflight gained schema-churn probes. Earlier shrunk 2026-11-18 (#8473 chain 19): events.history gained a trimmed-replay probe. Earlier shrunk 2026-11-18 (#8473 chain 18): protoTasks.maxTTL, maxPerRequestor and perMinute gained task-store probes. Earlier shrunk 2026-11-18 (#8473 chain 17): tasks.ttl and tasks.resultWait gained /v1 task probes. Earlier shrunk 2026-11-18 (#8473 chain 16): recipes.minScore, matchMargin and limit gained recipe probes. Earlier shrunk 2026-11-18 (#8473 chain 15): logstore.queryLimit gained a /v1/log probe. Earlier shrunk 2026-11-18 (#8473 chain 14): completion.perMinute and completion.serverPerMinute gained 429 probes. Earlier shrunk 2026-11-18 (#8473 chain 13): mcp.pageSize and mcp.passthrough gained tools/list probes. Earlier shrunk 2026-11-18 (#8473 chain 12): exec.timeout (now read by local runs), exec.maxOutputBytes and exec.output gained probes. Earlier shrunk 2026-11-18 (#8473 chain 11): spec.first and spec.lenient mapped to their existing revision-policy probes, spec.precedence gained one. Earlier shrunk 2026-11-18 (#8473 chain 10): protoMessages.taskAfter and protoTasks.pollInterval gained task probes. Earlier shrunk 2026-11-18 (#8473 chain 9): protoMessages.listMaxAge and readMaxAge gained cache-hint probes. Earlier shrunk 2026-11-18 (#8473 chain 8): proto.native gained an asked-client probe. Earlier shrunk 2026-11-18 (#8473 chain 7): proto.mcpPath and proto.serveMCP gained mount probes. Earlier shrunk 2026-11-18 (#8473 chain 6): proto.sessionIdle gained a reaped-session probe. Earlier shrunk 2026-11-18 (#8473 chain 5): proto.stateTTL gained a late-resume probe. Earlier shrunk 2026-11-18 (#8473 chain 4): proto.askTimeout gained a held-request probe. Earlier shrunk 2026-11-18 (#8473 chain 3): proto.askTTL gained a /v1/ask deadline probe. Earlier shrunk 2026-11-18 (#8473 chain 2): proto.askRounds gained a two-round MCP e2e probe. Earlier shrunk 2026-11-18 (#8468 chain 2): daemon.autostart gained its probe. Earlier shrunk 2026-11-17: (#8467 settings core-paths burn-down) paths.plugins gained its probe. Earlier shrunk 2026-11-17: (#8469) 14 http.* and transport.* settings gained their probes. Earlier shrunk 2026-11-17: (#8470 burn-down) stats.top gained its probe. Earlier shrunk 2026-11-17 (#8467 settings core-paths burn-down): paths.cache gained its probe. Earlier shrunk 2026-11-17 (#8467 settings core-paths burn-down): paths.scripts gained its probe. Earlier shrunk 2026-11-17 (#8468 chain 1): daemon.address gained its probe. Earlier shrunk 2026-11-17 (#8473 chain 1): proto.askPoll gained its probe. Deliberate +1 (2026-11-14, #1917 remainder shepherd of PR #7818) for script.language: covered by deterministic internal/runner tests (TestEffectiveScriptLanguage, TestExplicitPythonLanguageRunsInlineSnippet); the e2e harness script fixtures are TypeScript-only. Earlier deliberate +3 (2026-11-09, #2716) for proto.elicitationPerMinute, proto.samplingPerMinute and proto.samplingSessionPerMinute: daemon rate limits whose effect needs an over-limit sampling/elicitation flood no e2e fixture drives deterministically; the limiter is covered by internal/mcpclient and internal/daemon ratelimit tests. Earlier deliberate raises: +1 for daemon.roots and +8 for model.*: model settings are covered by internal/model and daemon unit tests; settings-driven e2e probes are not yet present. Deliberate +1 (2026-11-03, #1925 slice 3) for sampling.answerLocally: same model-layer coverage, daemon unit tests in internal/daemon/sampling_local_test.go. Deliberate +1 (2026-11-03, #5242) for plugin.disabledTools: read by the opencode plugin host (JS side); the Go e2e harness does not drive the plugin host, the same basis as every other plugin.* exemption. Deliberate +5 (2026-11-04, #1915 stage 2): import graph, missing, dynamic, cross-project and network policies are covered by deterministic internal/preflight tests, but the e2e harness has no isolated Deno graph fixture yet. Deliberate +2 (2026-11-05, #1911): checker error and unsupported-runtime policies are covered by deterministic internal/preflight stub-runtime tests; the e2e harness has no isolated Deno checker fixture. +const EffectExemptionPin = 19 // Shrunk 2026-11-22 (#8474): script.importsOnMissing + script.importsNetwork now have e2e probes. Shrunk 2026-11-22 (#8474): script.importsCrossProject + script.checkOnError. Shrunk 2026-11-21 (#8469): idle connection limits and timeout now assert actual connection reuse/expiry through configured clients. Shrunk 2026-11-21 (#8470): retention.stickyWindow now expires requested tools after its configured window. Earlier shrunk 2026-11-21 (#8470): events.reconnect now asserts retry delay after a dropped connection. Earlier shrunk 2026-11-21 (#8470): deps.autoInstall now asserts Bun's selected install policy. Earlier shrunk 2026-11-19 (#8467): output.color now has a PTY-backed interactive TUI probe. Earlier shrunk 2026-11-18 (#8473 chain 73): script.checkOnUnsupported is now probed under bun. Earlier shrunk 2026-11-18 (#8473 chain 72): daemon.takeoverTimeout gained a probe with a successor whose takeover dial cannot finish. Earlier shrunk 2026-11-18 (#8473 chain 71): daemon.socketProbeTimeout gained a probe with a second daemon started beside a live one. Earlier shrunk 2026-11-18 (#8473 chain 70): logging.maxAge gained a probe with a log file whose first record is two hours old. Earlier shrunk 2026-11-18 (#8473 chain 69): logstore.followBacklog gained a follow probe with a burst between two polls. Earlier shrunk 2026-11-18 (#8473 chain 68): paths.config gained a probe with a config planted only on the named path. Earlier shrunk 2026-11-18 (#8473 chain 67): script.importsOnDynamic and script.imports gained probes with a computed import() in exec source text, which needs no Deno graph. Earlier shrunk 2026-11-18 (#8473 chain 66): prompt.runTimeout gained a probe with a recipe that sleeps past a 1s bound. Earlier shrunk 2026-11-18 (#8473 chain 65): daemon.roots gained a probe through the ask fixture's new need_roots tool. Earlier shrunk 2026-11-18 (#8473 chain 64): prompt.sampleTimeout was orphaned since #2004; it is now the sampling question fallback when model.timeout is unset, and gained a probe. Earlier shrunk 2026-11-18 (#8473 chain 63): prompt.sample and prompt.catalogBudget gained probes on an unmatched prompt, the latter against the fake model endpoint. Earlier shrunk 2026-11-18 (#8473 chain 62): search.semantic and the remote embeddings settings gained probes against a fake OpenAI-compatible embeddings endpoint. Earlier shrunk 2026-11-18 (#8473 chain 61): proto.samplingPerMinute, proto.samplingSessionPerMinute and proto.elicitationPerMinute gained rate-limit probes driven by the ask fixture. Earlier shrunk 2026-11-18 (#8473 chain 60): sampling.answerLocally gained an upstream-sampling probe against the fake model endpoint. Earlier shrunk 2026-11-18 (#8473 chain 59): model.provider, baseURL, default, apiKeyEnv, budget, providers, profiles, timeout and prompt.maxTokens gained prompt-hook probes against a fake model endpoint. Earlier shrunk 2026-11-18 (#8473 chain 58): session.releaseTimeout gained an end-of-run release probe. Earlier shrunk 2026-11-18 (#8473 chain 57): daemon.idleExit gained an idle-daemon probe. Earlier shrunk 2026-11-18 (#8473 chain 56): daemon.port gained a bound-port probe. Earlier shrunk 2026-11-18 (#8473 chain 55): daemon.saveInterval gained a lease-table save probe. Earlier shrunk 2026-11-18 (#8473 chain 54): autostart.pollInterval gained a readiness-poll probe. Earlier shrunk 2026-11-18 (#8473 chain 53): daemon.leaseTTL gained a silent-caller probe. Earlier shrunk 2026-11-18 (#8473 chain 52): elicit.disambiguate and elicit.disambiguateDefault gained probes. Earlier shrunk 2026-11-18 (#8473 chain 51): elicit.ttl and elicit.maxAge gained probes, once upstream questions took their deadline from the broker. Earlier shrunk 2026-11-18 (#8473 chain 50): elicit.pendingLimit gained a probe, once `mcpx elicit list` honoured it. Earlier shrunk 2026-11-18 (#8473 chain 49): elicit.askTimeout gained a held-confirmation probe. Earlier shrunk 2026-11-18 (#8473 chain 48): artifacts.idleTtl and artifacts.maxAge gained touch-on-read probes. Earlier shrunk 2026-11-18 (#8473 chain 47): artifacts.ttl, artifacts.gcInterval, pool.min and autostart.idleExit gained probes. Earlier shrunk 2026-11-18 (#8473 chain 46): daemon.warm, pool.idleTimeout, daemon.reapInterval and daemon.endpoint gained probes. Earlier shrunk 2026-11-18 (#8473 chain 45): upstream.probeTimeout gained a probe, and upstream.eraCache and upstream.protocol were mapped to the era test, whose subtests run each with and without. Earlier shrunk 2026-11-18 (#8473 chain 44): prompt.autonomy, hooks.autonomy and repair.autonomy gained probes. Earlier shrunk 2026-11-18 (#8473 chain 43): policy.write, elicit.confirmDestructive and autonomy.max gained probes. Earlier shrunk 2026-11-18 (#8473 chain 42): daemon.inline, autostart.bin, autostart.args, autostart.logTail and daemon.watchConfig gained probes. Earlier shrunk 2026-11-18 (#8473 chain 41): daemon.inlineStartTimeout and daemon.probeTimeout gained probes. Earlier shrunk 2026-11-18 (#8473 chain 40): daemon.warmTimeout, autostart.connectTimeout and autostart.pingTimeout gained probes. Earlier shrunk 2026-11-18 (#8473 chain 39): pool.callTimeout, pool.startTimeout and daemon.refreshTimeout gained probes. Earlier shrunk 2026-11-18 (#8473 chain 38): doctor.timeout and registry.timeout gained probes that set a bound no request can meet. Earlier shrunk 2026-11-18 (#8473 chain 37): completion.maxValues gained a probe once the fake server could answer completions. Earlier shrunk 2026-11-18 (#8473 chain 36): catalog.instructions gained a probe once the fake server could serve instructions. Earlier shrunk 2026-11-18 (#8473 chain 35): the five plumbing source and launcher switches gained probes. Earlier shrunk 2026-11-18 (#8473 chain 34): artifacts.chunkBytes, script.launcher and paths.placeholders gained probes. Earlier shrunk 2026-11-18 (#8473 chain 33): artifacts.interceptImages and plumbing.indexOnQuery gained probes. Earlier shrunk 2026-11-18 (#8473 chain 32): plumbing.validatePaths and script.language gained probes. Earlier shrunk 2026-11-18 (#8473 chain 31): logging.trace and exec.where gained probes. Earlier shrunk 2026-11-18 (#8473 chain 30): paths.adapters and paths.apis gained declaration-file probes. Earlier shrunk 2026-11-18 (#8473 chain 29): script.runtime, runtimeOrder, permissions, profiles and runtimes gained node-backed probes. Earlier shrunk 2026-11-18 (#8473 chain 28): script.before, onSuccess, onError and suffix gained a run-phase probe. Earlier shrunk 2026-11-18 (#8473 chain 27): hooks, hooks.timeout, daemon.ui and daemon.uiDir gained probes. Earlier shrunk 2026-11-18 (#8473 chain 26): logging.level, format, source, dir, include, maxLines, maxBytes and keep gained durable-log probes. Earlier shrunk 2026-11-18 (#8473 chain 25): artifacts.enabled, maxBytes, quota, delivery, inlineMaxBytes and dir gained script-artifact probes. Earlier shrunk 2026-11-18 (#8473 chain 24): preset and serve.mode gained probes. Earlier shrunk 2026-11-18 (#8473 chain 23): presets gained a --preset probe. Earlier shrunk 2026-11-18 (#8473 chain 22): catalog.budget and catalog.bias gained `mcpx catalog` probes. Earlier shrunk 2026-11-18 (#8473 chain 21): catalog.pinnedTools and retention.maxTools gained reactive-session probes. Earlier shrunk 2026-11-18 (#8473 chain 20): diagnose.history and diagnose.preflight gained schema-churn probes. Earlier shrunk 2026-11-18 (#8473 chain 19): events.history gained a trimmed-replay probe. Earlier shrunk 2026-11-18 (#8473 chain 18): protoTasks.maxTTL, maxPerRequestor and perMinute gained task-store probes. Earlier shrunk 2026-11-18 (#8473 chain 17): tasks.ttl and tasks.resultWait gained /v1 task probes. Earlier shrunk 2026-11-18 (#8473 chain 16): recipes.minScore, matchMargin and limit gained recipe probes. Earlier shrunk 2026-11-18 (#8473 chain 15): logstore.queryLimit gained a /v1/log probe. Earlier shrunk 2026-11-18 (#8473 chain 14): completion.perMinute and completion.serverPerMinute gained 429 probes. Earlier shrunk 2026-11-18 (#8473 chain 13): mcp.pageSize and mcp.passthrough gained tools/list probes. Earlier shrunk 2026-11-18 (#8473 chain 12): exec.timeout (now read by local runs), exec.maxOutputBytes and exec.output gained probes. Earlier shrunk 2026-11-18 (#8473 chain 11): spec.first and spec.lenient mapped to their existing revision-policy probes, spec.precedence gained one. Earlier shrunk 2026-11-18 (#8473 chain 10): protoMessages.taskAfter and protoTasks.pollInterval gained task probes. Earlier shrunk 2026-11-18 (#8473 chain 9): protoMessages.listMaxAge and readMaxAge gained cache-hint probes. Earlier shrunk 2026-11-18 (#8473 chain 8): proto.native gained an asked-client probe. Earlier shrunk 2026-11-18 (#8473 chain 7): proto.mcpPath and proto.serveMCP gained mount probes. Earlier shrunk 2026-11-18 (#8473 chain 6): proto.sessionIdle gained a reaped-session probe. Earlier shrunk 2026-11-18 (#8473 chain 5): proto.stateTTL gained a late-resume probe. Earlier shrunk 2026-11-18 (#8473 chain 4): proto.askTimeout gained a held-request probe. Earlier shrunk 2026-11-18 (#8473 chain 3): proto.askTTL gained a /v1/ask deadline probe. Earlier shrunk 2026-11-18 (#8473 chain 2): proto.askRounds gained a two-round MCP e2e probe. Earlier shrunk 2026-11-18 (#8468 chain 2): daemon.autostart gained its probe. Earlier shrunk 2026-11-17: (#8467 settings core-paths burn-down) paths.plugins gained its probe. Earlier shrunk 2026-11-17: (#8469) 14 http.* and transport.* settings gained their probes. Earlier shrunk 2026-11-17: (#8470 burn-down) stats.top gained its probe. Earlier shrunk 2026-11-17 (#8467 settings core-paths burn-down): paths.cache gained its probe. Earlier shrunk 2026-11-17 (#8467 settings core-paths burn-down): paths.scripts gained its probe. Earlier shrunk 2026-11-17 (#8468 chain 1): daemon.address gained its probe. Earlier shrunk 2026-11-17 (#8473 chain 1): proto.askPoll gained its probe. Deliberate +1 (2026-11-14, #1917 remainder shepherd of PR #7818) for script.language: covered by deterministic internal/runner tests (TestEffectiveScriptLanguage, TestExplicitPythonLanguageRunsInlineSnippet); the e2e harness script fixtures are TypeScript-only. Earlier deliberate +3 (2026-11-09, #2716) for proto.elicitationPerMinute, proto.samplingPerMinute and proto.samplingSessionPerMinute: daemon rate limits whose effect needs an over-limit sampling/elicitation flood no e2e fixture drives deterministically; the limiter is covered by internal/mcpclient and internal/daemon ratelimit tests. Earlier deliberate raises: +1 for daemon.roots and +8 for model.*: model settings are covered by internal/model and daemon unit tests; settings-driven e2e probes are not yet present. Deliberate +1 (2026-11-03, #1925 slice 3) for sampling.answerLocally: same model-layer coverage, daemon unit tests in internal/daemon/sampling_local_test.go. Deliberate +1 (2026-11-03, #5242) for plugin.disabledTools: read by the opencode plugin host (JS side); the Go e2e harness does not drive the plugin host, the same basis as every other plugin.* exemption. Deliberate +5 (2026-11-04, #1915 stage 2): import graph, missing, dynamic, cross-project and network policies are covered by deterministic internal/preflight tests, but the e2e harness has no isolated Deno graph fixture yet. Deliberate +2 (2026-11-05, #1911): checker error and unsupported-runtime policies are covered by deterministic internal/preflight stub-runtime tests; the e2e harness has no isolated Deno checker fixture. // CheckEffectCoverage returns one violation per way the probe and // exemption maps fail to cover reg exactly: a setting with neither,