[spec 9] A required host contract for the spec 9 QuickJS orchestrator

Open
#5,166 0 comments 0 reactions 0 assignees View on GitHub

Maintainers usually reply within 1 day

Nobody has claimed this yet.

Assessment

Difficulty
4/5
Estimated time
3-5 days
Newbie friendliness
48/100
Issue type
Refactor
Clarity
Clearly specified
Activity status
Active
Tech stack
typescript

Research direction

Start by reading runWorkflowWithQuickJS, its production caller, and quickjs-entrypoint.preload.test.ts; identify the host values the caller already supplies and how the standalone tests construct their Worlds. Move spec 8 preload coverage to spec 8 tests and give the remaining tests a factory using InBandWriter over AppendOnlyWorld. Done when the host argument is required and missing fence or handoff data produces a type error.

Written by the indexing model from the issue text.

Description

(AI) Follow-up from #4661 (spec 9, the experimental single-orchestrator runtime, opt-in via WORKFLOW_SPEC_VERSION=9). Tracked as follow-up 13 on the spec 9 changelog.

runWorkflowWithQuickJS takes its writer, loaded log and cursor, message identity, re-send policy and continuation callback as optional parameters. The one production caller passes them all; the optional forms (direct unfenced writes, a new message in place of a handoff, a per-pass re-send rule) remain only for about ten standalone tests that call it with ad-hoc Worlds (quickjs-entrypoint.preload.test.ts among them, with capabilities: {} and non-slot event ids). Make them one required host argument, give those tests a factory with a real InBandWriter over AppendOnlyWorld, and move spec 8 preload behavior to spec 8's tests, so a missing fence or handoff is a type error. Not done here because every one of those tests has to move to a fence-capable World. 4403942436.

Dominant language
TypeScript
Stars
2.5k
Forks
401
Avg merge
1d 21h
Merged PRs (30d)
201

Getting set up

  • No Dockerfile or Docker Compose file
  • Has a pull request template
  • No contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from vercel/workflow

All issues in vercel/workflow

Similar issues

More TypeScript issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.