Address ClawSweeper review on #88211:
- Substitute plugin config ${VAR} against the loader's per-load env
(env ?? process.env) instead of process.env directly, and thread that
env from both validatePluginConfig call sites, so explicit-env callers
are honored (parity with read-time config substitution).
- Fix the regression test: the probe plugin used the empty default schema,
which rejected its apiKey config before register() ran, so the test never
exercised substitution. Give writePlugin an optional configSchema and a
schema that permits apiKey; add an explicit-env case alongside the
process-env case.
- Rename the global probe key to satisfy no-underscore-dangle lint.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Plugin entry config (`plugins.entries.*.config`) could reach the plugin
with `${VAR}` references unresolved, while provider config resolved them
correctly. A provider plugin whose API key was supplied as
`apiKey: "${MY_KEY}"` therefore authenticated with the literal
placeholder and every upstream request was rejected — surfacing as a
"provider down" / silent model failover with no indication why.
Resolve `${VAR}` references in `validatePluginConfig` (the single point
all plugin entry config passes through on its way to the plugin) so
plugins always receive resolved values, matching provider-config
behaviour. Missing vars are preserved as their literal placeholder
rather than throwing, matching read-time config substitution; the call
is a no-op when the config is already resolved.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Fix Codex app-server native thread overflow recovery and CLI compaction fallback.
- rotate Codex native startup bindings when rollout token pressure leaves too little headroom
- keep byte-size rollout fuses ahead of rollout content reads
- clear stale resumed context-engine bindings only when the stored thread id still matches
- fall back to context-engine compaction when Codex owns/skips native compaction
Verification:
- node scripts/run-vitest.mjs run --config test/vitest/vitest.extension-codex.config.ts extensions/codex/src/app-server/startup-binding.test.ts extensions/codex/src/app-server/run-attempt.context-engine.test.ts extensions/codex/src/app-server/session-binding.test.ts --reporter=verbose
- node scripts/run-vitest.mjs run --config test/vitest/vitest.agents.config.ts src/agents/command/cli-compaction.test.ts --reporter=verbose
- git diff --check origin/main...HEAD
- autoreview --mode branch --base origin/main: clean
- GitHub CI for 466bfbe78c: green
Co-authored-by: fuller-stack-dev <263060202+fuller-stack-dev@users.noreply.github.com>