Skip to content

🚚 refactor: move addBedrockCacheControl logic and tests over from LC - #28

Merged
danny-avila merged 1 commit into
mainfrom
feat/bedrock-cache-control
Nov 11, 2025
Merged

danny-avila merged 1 commit into
mainfrom
feat/bedrock-cache-control

Conversation

@dustinhealy

Copy link
Copy Markdown
Collaborator

Sibling PR to #8271

Since 0e19057, addCacheControl logic has been moved into agents from api/server/controllers/agents/client.js. This PR migrates the addBedrockCacheControl logic to sit alongside addCacheControl to maintain architectural consistency.

Still requires testing to confirm proper implementation.

@danny-avila danny-avila changed the title 🚚 refactor: move addBedrockCacheControl logic and tests over from LC 🚚 refactor: move addBedrockCacheControl logic and tests over from LC Nov 11, 2025
@danny-avila
danny-avila merged commit 807afcd into main Nov 11, 2025
danny-avila added a commit that referenced this pull request May 5, 2026
…imes (Codex P1 #28, P2 #29)

P1 #28: \`killProcessTree\` only sent SIGTERM. A child that traps the
signal (\`trap '' TERM; while true; do sleep 1; done\`) ignores it
and never emits \`close\`, so \`spawnLocalProcess\` hangs past
timeoutMs / maxSpawnedBytes — defeating both guarantees. Now sends
SIGTERM first (graceful), arms a 2 s escalation timer that delivers
SIGKILL to the process tree if the child is still alive. The
escalation timer is unref'd so it can't keep the Node process alive
past natural exit, and is cleared the moment \`close\` fires. Test
pinned: \`bash -c "trap '' TERM; while true; do sleep 0.1; done"\`
with timeoutMs=1500 — pre-fix Jest would time out at 5 s; post-fix
the spawn promise resolves in ~3.5 s (timeout + escalation).

P2 #29: the compile-style \`execute_code\` runtimes (\`rs\`, \`c\`,
\`cpp\`, \`java\`, \`d\`, \`f90\`) hardcoded \`bash\` via a private
\`configShell()\` helper instead of honoring \`local.shell\`. Same
shape as the syntax-preflight gap Codex P1 #6 fixed earlier — just
missed in this surface. \`getRuntimeCommand\` now takes a
\`shellOverride\` param threaded from \`config.shell\`; falls back
to \`configShell()\` when undefined (existing behavior). Test
pinned: rust runtime invoked with \`shell: '/bin/sh'\` dispatches via
\`/bin/sh\`, not bash.

789 tests passing across all suites, lint baseline unchanged.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants