Harden scoped SDK auth and KV reliability - #42
Conversation
Entire-Checkpoint: 01KZR8N3JZ3BZ2SKD3RHNF3JSS
Entire-Checkpoint: 01KZR8YYCNK9XMV2RQS7SKRN04
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 2ddcbf21b4
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| traceID, parentSpanID, executionStart, owned := h.SDKAuth.TraceContext(execID, callerFnID) | ||
| if !owned { | ||
| respond.Error(w, http.StatusForbidden, "SDK_SCOPE_VIOLATION", | ||
| "span execution is not active for the calling function", reqID) | ||
| return |
There was a problem hiding this comment.
Keep Node span ingestion inside the active window
When a Node handler uses await trace.span(...), the SDK deliberately starts the span POST without awaiting it (backend/runtimes/node/orva.js:451-463). The handler can therefore return and let Proxy.Forward remove the BindExecution entry before that POST reaches this ownership check; the request then receives 403, and the SDK's .catch(() => {}) silently discards the span. Await span ingestion or retain a verifiable execution context long enough for these documented fire-and-forget requests to finish.
Useful? React with 👍 / 👎.
Summary
Validation
make testmake lintcd frontend && npm test && npm run lint && npm run buildmake build-allgit diff --checkThe provisioned Linux CI jobs now run
test/sdk-test.shfor Node/Python sandbox parity. The local dev host cannot remount a copied rootfs read-only inside nested nsjail, so that boundary is left to the mandatory CI runner.