Skip to content

test(workflows): prove real QuickJS Run and Thread recovery - #281

Merged
yanpgwang merged 3 commits into
mainfrom
codex/workflow-quickjs-vertical
Oct 26, 2026
Merged

yanpgwang merged 3 commits into
mainfrom
codex/workflow-quickjs-vertical

Conversation

@yanpgwang

Copy link
Copy Markdown
Owner

Problem, rationale, and scope

The Run coordinator previously had only a scripted evaluator proof. This bounded research slice runs frozen real JavaScript through the existing QuickJS candidate, actual Temporal Run pump, PostgreSQL frontier/owned receipts, outboxes and Thread runner. It is test-only feasibility evidence, not public Workflow admission, complete Run lifecycle, a production JS engine decision or CMA parity.

What changed

Add internal fenced delivery/return decisions to the existing journal without a second agent loop or migration. A test-only adapter validates each bounded IPC quantum before proposing effects and replays only committed receipt deliveries in their original order. Cover parallel and sequential two-call programs, actual Thread failure/catch/fallback, replay mismatch and hard resource failure.

Verification

  • Independent exact-head review passed on e85f6cdae723bd069e1188069c90014a0ff66710; fresh publication review requested.
  • make verify, full make test-service, docs checks and focused real PG tests passed.
  • All seven real QuickJS/PG/Temporal cases passed; -race -count=3 passed.
  • Evaluator kill, SQL commit/ACK loss, worker replacement, Continue-As-New, stale epoch and B-before-A cached delivery ordering asserted.
  • Final immutable image sha256:683be7683f7c30681f8b5d45e8305cf8121becfd9232d84e4745dde21ee6a834, linux/arm64. Explicit reproducible target: make test-workflow-quickjs-integration with disposable service addresses.
  • Final stored candidate: {"total":12,"note":"beta-text","order":["B","A"],"tag":{"study":true}}.
  • No paid provider smoke was run; all model inference used deterministic fixtures.

API impact and design provenance

No public API/SDK or schema changes. The opt-in adapter exists only in Go test files and no default worker enables it. QuickJS is the existing checksum-pinned study candidate. Official public CMA/SDK cookbook material informs workflow ownership, not a claim about CMA private language or engine. This proof is not the cookbook fact-check acceptance sample.

Durability and security

Delivery and return candidates use Session-first owner/epoch/lifecycle fences and existing outbox transactions. Program return remains a candidate with Run open: primary terminal delivery, Outcome resume and aggregate lifecycle barriers are still absent. Resource/IPC failures cannot admit partial effect batches. One local platform/profile was tested; strong isolation, supervisor-crash reaping and arbitrary-program qualification remain open. Disposable fixtures only; no credentials or user DB touched.

Checklist

  • The problem, acceptance criteria, and non-goals are recorded here or in a linked design document/Issue.
  • Tests cover the changed behavior.
  • Public behavior is documented (unexposed).
  • Material external design influences and Mango-owned decisions are recorded.
  • No credentials, generated build output, or local databases are included.

@yanpgwang
yanpgwang marked this pull request as ready for review October 26, 2026 12:49
@yanpgwang
yanpgwang merged commit 6bb7329 into main Oct 26, 2026
13 checks passed
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.

1 participant