Commit Graph

1158 Commits

Author SHA1 Message Date
github-actions[bot] 99d1a0ce14 Version Packages (#3105) workflow@4.7.0 2026-07-28 17:40:43 -07:00
Peter Wielander 9d8b293f88 fix(world-vercel): bound HTTP timeouts and retry transport timeouts (#3169) 2026-07-28 16:50:09 -07:00
github-actions[bot] f2714c50bb Pass the webhook request through without buffering its body (#3166) (#3174)
The Astro and SvelteKit webhook wrappers copied the incoming request via
`normalizeRequest()`, which buffers the whole body with `arrayBuffer()`,
before calling the handler that validates the webhook token. Requests
carrying an unknown token therefore did unnecessary work before being
rejected.

The copy turns out to be unnecessary: both frameworks already hand the
route a standard `Request`, so the webhook wrappers now pass it straight
to the handler. The body is left untouched until `resumeWebhook()` has
accepted the token.

The flow route keeps `normalizeRequest()` for now — it authenticates via
the queue trigger rather than a URL token, so the ordering does not
matter there, and whether the shim is needed at all is a separate
question.

Note that the Astro dev server buffers request bodies upstream of the
route handler, so the new behavior is only observable in built output;
the node adapter and Vercel builds both benefit.

Signed-off-by: Nathan Rajlich <n@n8.io>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2026-07-28 16:35:54 -07:00
Peter Wielander 63fe524dc0 Revert "Publish 4.x under the previous dist-tag (#3091)" (#3168)
This reverts commit 3b839446a9.
2026-07-28 14:14:16 -07:00
github-actions[bot] 6f234bd09c fix: upgrade postcss to >=8.5.18 to address GHSA-r28c-9q8g-f849 (#3102) (#3103)
Signed-off-by: Nathan Rajlich <n@n8.io>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2026-07-24 17:31:57 -07:00
github-actions[bot] c77a82d708 [world-testing] Isolate each spawned test server's data directory (#3055) (#3104)
Co-authored-by: Peter Wielander <mittgfu@gmail.com>
2026-07-24 17:00:49 -07:00
Peter Wielander 12e4ef7ea1 Backport #2266 + #2946: precondition guard for event creation (#3079) 2026-07-24 16:18:48 -07:00
Peter Wielander 3b839446a9 Publish 4.x under the previous dist-tag (#3091) 2026-07-24 16:16:53 -07:00
github-actions[bot] 603cd34882 Version Packages (#3074) workflow@4.6.2 2026-07-24 12:35:36 -07:00
github-actions[bot] 58fb594768 Backport #3071: fix: upgrade next to 16.2.11 to address CVE-2026-64641 (#3073)
Co-authored-by: Nathan Rajlich <n@n8.io>
Co-authored-by: VaguelySerious <mittgfu@gmail.com>
2026-07-23 15:45:51 -07:00
github-actions[bot] b090df632b Version Packages (#2863) workflow@4.6.1 2026-07-22 16:22:22 +00:00
Peter Wielander 4cee182f65 fix(workbench/nest): set outputDirectory so stable Vercel deploy succeeds (#3032) 2026-07-21 11:56:56 -07:00
github-actions[bot] 7c0266f193 Retry transient connection timeouts (#3013) (#3019) 2026-07-20 17:32:21 -07:00
github-actions[bot] 8eb110ca2e fix(world-vercel): append caller User-Agent products instead of discarding them (#2998) (#3018)
Co-authored-by: Rui <rui@conti.sh>
2026-07-21 00:15:06 +00:00
github-actions[bot] f1f7e1dc25 Backport #2963: Fix dotted tsconfig alias workflow discovery (#2982)
Co-authored-by: Peter Wielander <mittgfu@gmail.com>
2026-07-20 15:34:32 -07:00
github-actions[bot] 0422a0e51b Backport #2996: perf(core): cache port discovery for step invocations (#2997)
Co-authored-by: Joey Hotz <joeyhotz1@gmail.com>
Signed-off-by: Joey Hotz <joeyhotz1@gmail.com>
Co-authored-by: Peter Wielander <peter.wielander@vercel.com>
2026-07-20 11:25:14 -07:00
github-actions[bot] aac6ea53ec fix(world-vercel): log queue handler retry errors (#2959) (#2961)
Co-authored-by: Alex Langenfeld <alexlangenfeld@gmail.com>
2026-07-16 20:00:13 +00:00
github-actions[bot] 489ed710cc Make sure that everyone is still /docs code owners (#2939) (#2945) 2026-07-15 11:44:16 -07:00
github-actions[bot] df622965f2 Add team-python to CODEOWNERS for docs (#2936) (#2938) 2026-07-15 09:26:33 -07:00
github-actions[bot] 8bfee36c31 fix(nitro): skip generated build artifacts (#2925) (#2928)
Signed-off-by: Nathan Colosimo <110621881+NathanColosimo@users.noreply.github.com>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2026-07-14 23:27:38 +00:00
Nathan Colosimo 3b46dab148 Fix Workflow loader source map warnings (#2693) (#2926)
Co-authored-by: JJ Kasper <jj@jjsweb.site>
2026-07-14 22:52:21 +00:00
github-actions[bot] 89983d9ea7 Backport #2814: Bump e2e framework versions (#2819)
* Bump e2e framework versions (#2814)

* Fix SvelteKit config loading

* Bump e2e framework versions

Signed-off-by: Nathan Colosimo <110621881+NathanColosimo@users.noreply.github.com>

* Fix SvelteKit config loading

* Fix stable SvelteKit Undici resolution

---------

Signed-off-by: Nathan Colosimo <110621881+NathanColosimo@users.noreply.github.com>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: Nathan Colosimo <110621881+NathanColosimo@users.noreply.github.com>
2026-07-14 14:07:16 -07:00
github-actions[bot] ab33490cde Update vitest from 4.0.18 to 4.1.10 (#2916) (#2920) 2026-07-14 19:18:48 +00:00
github-actions[bot] 332afdee1e docs: fix stale and broken vercel.com links (#2910) (#2911)
Audited every vercel.com link in docs/content (20 unique URLs,
HTTP-validated including anchor fragments):

- project-configuration#regions (2x): the #regions anchor no longer
  exists on that page — content moved to the vercel-json subpage; now
  links project-configuration/vercel-json#regions
- gateway/api-reference/overview (2x): hard 404; the AI Gateway docs
  restructured — 'get an API key' context now points at
  ai-gateway/authentication
- observability/otel-overview (1x): redirects to
  tracing/instrumentation; link the final URL
- docs/workflow and docs/workflow/python (8x): redirect to the plural
  docs/workflows paths; link the final URLs (also drops a redundant
  ?language=py param that the redirect discards)

All other links (queues, queues/pricing + anchors, plans/hobby,
limits, regions, sandbox, workflows/pricing#storage-retention,
cli/project-linking, audit-log, home, help, blog) verified 200 with
live anchors.

Signed-off-by: Nathan Rajlich <n@n8.io>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2026-07-13 16:58:21 -07:00
github-actions[bot] 2213c91731 Backport #2732: fix(next): respect basePath for workflow routes (#2791)
* fix(next): respect basePath for workflow routes (#2732)

* fix(next): respect basePath for workflow routes

* docs(core): note workflow URL resolution gap

* fix(next): expose workflow health route methods

* test(utils): remove workflow route helper tests

* test(builders): remove route handler string test

* fix(next): defer basePath validation to Next.js

* refactor(utils): remove workflow url helper wrappers

* Test Next basePath builder wiring

Signed-off-by: Nathan Colosimo <110621881+NathanColosimo@users.noreply.github.com>

* fix(backport): preserve framework route wrappers

Signed-off-by: Nathan Colosimo <110621881+NathanColosimo@users.noreply.github.com>

---------

Signed-off-by: Nathan Colosimo <110621881+NathanColosimo@users.noreply.github.com>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: Nathan Colosimo <110621881+NathanColosimo@users.noreply.github.com>
Co-authored-by: Peter Wielander <mittgfu@gmail.com>
2026-07-09 17:17:23 -07:00
github-actions[bot] ad99be5102 Backport #2813: Fix Next watcher with custom distDir (#2818)
* Fix next watcher custom dist dir (#2813)

Signed-off-by: Nathan Colosimo <110621881+NathanColosimo@users.noreply.github.com>

* Update packages/next/src/builder-eager.ts

Co-authored-by: vercel[bot] <35613825+vercel[bot]@users.noreply.github.com>
Signed-off-by: Nathan Colosimo <110621881+NathanColosimo@users.noreply.github.com>

---------

Signed-off-by: Nathan Colosimo <110621881+NathanColosimo@users.noreply.github.com>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: Nathan Colosimo <110621881+NathanColosimo@users.noreply.github.com>
Co-authored-by: vercel[bot] <35613825+vercel[bot]@users.noreply.github.com>
2026-07-09 23:23:21 +00:00
github-actions[bot] b1d1a066a5 Backport #2687: fix(core): guard extractStreamIds against circular references (#2861)
Co-authored-by: Peter Wielander <mittgfu@gmail.com>
Co-authored-by: Syed Osama Ali Shah <86572800+Osamaali313@users.noreply.github.com>
2026-07-09 19:48:13 +00:00
github-actions[bot] 81b1961905 fix(workbench): add @repo/* tsconfig alias to nitro-v2 (#2787) (#2810) 2026-07-07 15:12:11 -07:00
github-actions[bot] 822197c886 Version Packages (#2426) workflow@4.6.0 2026-07-06 12:23:48 -07:00
Peter Wielander d0e4191b7e [core] Correct byte-stream framing capability cutoff (stable) (#2768) 2026-07-03 15:59:58 -07:00
github-actions[bot] 6dbe2de33f fix(world-local): rebuild hook caches from event log (#2747) (#2766)
Signed-off-by: Nathan Colosimo <110621881+NathanColosimo@users.noreply.github.com>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2026-07-02 23:18:24 +00:00
github-actions[bot] b534da2388 Fix Postgres step lifecycle event ordering (#2714) (#2756)
* Fix Postgres step start event ordering

* Document Postgres step start transaction

* Increase canary HMR e2e timeouts

* Address Postgres lifecycle review comments

Signed-off-by: Nathan Colosimo <110621881+NathanColosimo@users.noreply.github.com>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2026-07-02 12:04:14 -07:00
github-actions[bot] 980933fd43 fix(nitro): pass workflow dirs to builders (#2722) (#2754)
Signed-off-by: Nathan Colosimo <110621881+NathanColosimo@users.noreply.github.com>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2026-07-02 19:00:35 +00:00
github-actions[bot] 4b422493cd fix(vitest): derive workflow cwd from project root (#2726) (#2755)
* fix(vitest): derive workflow cwd from project root

* chore(vitest): simplify project root options

Signed-off-by: Nathan Colosimo <110621881+NathanColosimo@users.noreply.github.com>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2026-07-02 18:59:15 +00:00
github-actions[bot] 01265b748c fix(next): derive workflow project root (#2729) (#2743)
* fix(next): derive workflow project root

* test(next): clean temp root after leaving app dir

* chore(next): simplify project root detection

* chore(next): mirror root detection

Signed-off-by: Nathan Colosimo <110621881+NathanColosimo@users.noreply.github.com>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2026-07-02 11:10:57 -07:00
github-actions[bot] c4bc5a1590 fix(vite-frameworks): derive workflow roots (#2725) (#2753)
* fix(vite-frameworks): derive workflow roots

* chore(vite-frameworks): simplify derived roots

* chore(vite-frameworks): simplify root derivation

* fix(sveltekit): respect configured routes directory

* test(frameworks): cover builder option pass-through

* test(frameworks): remove builder option tests

* fix(sveltekit): assert loaded routes config

* docs(sveltekit): note internal config loader

Signed-off-by: Nathan Colosimo <110621881+NathanColosimo@users.noreply.github.com>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2026-07-02 11:10:42 -07:00
github-actions[bot] aa9919b14e fix(next): prewarm SWC plugin cache (#2538) (#2576)
Co-authored-by: Nathan Colosimo <110621881+NathanColosimo@users.noreply.github.com>
2026-07-02 11:08:23 -07:00
github-actions[bot] ef60d31963 fix(ai): recover from invalid tool-call input instead of aborting the agent stream (#2699) (#2703)
#2192 by @boomyao

Co-authored-by: yao <zhangyaoruo@outlook.com>
Co-authored-by: Peter Wielander <mittgfu@gmail.com>
2026-07-01 20:12:22 +00:00
github-actions[bot] f927d6933b fix(nitro): use workspaceDir for monorepos (#2713) (#2720)
* fix(nitro): use workspaceDir for monorepos

* test: stabilize Next canary HMR e2e

Signed-off-by: Nathan Colosimo <110621881+NathanColosimo@users.noreply.github.com>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2026-07-01 20:10:56 +00:00
github-actions[bot] cfb8f770ac fix(ai): continue durable agent tool loops (#2730) (#2740)
Co-authored-by: Nathan Colosimo <110621881+NathanColosimo@users.noreply.github.com>
2026-07-01 18:31:14 +00:00
github-actions[bot] 50492d760c Fix workflow Postgres enum schemas (#2705) (#2717)
Signed-off-by: Nathan Colosimo <110621881+NathanColosimo@users.noreply.github.com>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2026-06-30 14:37:49 -07:00
github-actions[bot] 643cae23d3 test: reduce e2e timing flakes (#2665) (#2701)
* test: reduce e2e timing flakes

* test: tighten e2e timing bounds

Signed-off-by: Nathan Colosimo <110621881+NathanColosimo@users.noreply.github.com>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2026-06-30 10:33:34 -07:00
github-actions[bot] 02c8e4d9d4 Upgrade workspace to TypeScript 6 (#2700) (#2706)
* Upgrade workspace to TypeScript 6

* Restore Nest baseUrl for SWC builds

* Use empty changeset for TS6 upgrade

* Remove TS6 changeset

Signed-off-by: Nathan Colosimo <110621881+NathanColosimo@users.noreply.github.com>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: Nathan Colosimo <110621881+NathanColosimo@users.noreply.github.com>
2026-06-30 10:33:13 -07:00
github-actions[bot] 504cf88465 Fix graph extraction for annotated step proxies (#2702) (#2710)
Signed-off-by: Nathan Colosimo <110621881+NathanColosimo@users.noreply.github.com>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2026-06-30 10:32:55 -07:00
Nathan Colosimo db90c40a13 Fix Nitro Vercel workflow routes (#2645)
* Fix Nitro Vercel workflow routes

* Simplify Nitro Vercel route fix

* Support latest Nitro 3 stable builds

* Remove unused Nitro Vercel webhook function output

* Use generated Vercel functions for Nitro workflow routes
2026-06-30 06:06:53 +00:00
github-actions[bot] 04e78129dc Propagate trace context to vercel-workflow.com in workbench instrumentation (#2601) (#2602)
* Propagate trace context to vercel-workflow.com in workbench instrumentation

@vercel/otel only propagates W3C trace context to Vercel deployment URLs
by default, so outgoing requests to the workflow-server
(vercel-workflow.com) got a client span with no `traceparent` header —
breaking the APM trace link to workflow-server's spans. Add
`instrumentationConfig.fetch.propagateContextUrls` for the workflow-server
domain in every workbench that uses @vercel/otel: example,
nextjs-turbopack, nextjs-webpack, and sveltekit. The Next.js and SvelteKit
apps already declared @vercel/otel but weren't registering it at all; they
now do.



* Also propagate trace context to the Vercel Queue Service (vercel-queue.com)

The workflow-server queue path (@vercel/queue) sends to regional
vercel-queue.com subdomains (e.g. iad1.vercel-queue.com) when not using the
queues proxy, which were missing a `traceparent` header for the same reason
as vercel-workflow.com. Add `/vercel-queue\.com/` to propagateContextUrls in
all four workbench instrumentation configs.



---------

Signed-off-by: Pranay Prakash <pranay.gp@gmail.com>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: Claude Opus 4.8 <noreply@anthropic.com>
Co-authored-by: Peter Wielander <mittgfu@gmail.com>
2026-06-29 13:04:09 -07:00
github-actions[bot] 67fcf1a750 Redrive on transient workflow-server transport failures instead of failing the run (#2445) (#2689)
* Redrive on transient workflow-server transport failures instead of failing the run

A firewall in front of workflow-server shedding load with sustained 429/503
makes undici's shared RetryAgent exhaust its retries and throw
UND_ERR_REQ_RETRY. That raw error was rethrown unwrapped, so it was
classified as USER_ERROR and the replay terminal branch wrote run_failed —
permanently failing a run on a transient blip (or, in an outage, falling back
to the ~5min queue visibility-timeout redrive).

- world-vercel: map exhausted-retry / socket / connect / DNS / timeout
  failures to a typed WorkflowWorldError (code TRANSPORT/TIMEOUT) by walking
  the fetch() cause chain.
- core: add isRetryableWorldError (429 / 5xx / TRANSPORT / TIMEOUT) and
  rethrow such errors from the replay terminal branch so the queue redrives
  quickly (1s->60s backoff) instead of failing the run. Reuse it in start()
  and step_started handling.
- world-vercel: surface the Vercel firewall x-vercel-mitigated
  (challenge/deny) header alongside x-vercel-id in error diagnostics and logs.



* Address review: back off + cap on every retry path; fix mock; refine scope

Revises the transport-error handling per PR review (VaguelySerious,
karthikscale3).

Blocking fix — step_started no longer self-enqueues a throttled defer for
transient world errors. Returning `{ type: 'throttled', timeoutSeconds: 1 }`
acked the delivery and enqueued a fresh message, resetting the delivery count
so the path never backed off and never reached MAX_QUEUE_DELIVERIES — an
unbounded flat-1s loop if step_started kept failing. It now throws, so the
error flows through the replay loop's retryable-world-error rethrow and earns
both the delivery-count backoff and the max-delivery cap. Throwing is safe on
step_started (the body hasn't run; a write that landed dedupes to skipped).

Also in this revision:
- Backoff that lasts: raise the queue handler-error retry ceiling 60s -> 900s.
  VQS clamps each redelivery to its 900s SQS limit and adds its own post-32
  exponential, so ramping our base toward 900s stretches survival from ~3.7h to
  most of the 24h message-visibility window. Corrected the stale
  MAX_QUEUE_DELIVERIES comment to match the real VQS schedule.
- Stop amplifying firewall challenges: the undici RetryAgent no longer retries
  429 in-process (a challenge is a 429 the client can't solve). 429s surface
  immediately as ThrottleError carrying x-vercel-mitigated / x-vercel-id, so
  the diagnostic header now reaches us for the challenge case too.
- Track world faults as WORLD_CONTRACT_ERROR (not USER_ERROR) in
  classifyRunError so an outage isn't attributed to user code.
- Fix queue.test.ts mock that `biome check --write` had rewritten from a
  newable `function` into an arrow (broke `new QueueClient`); pin with a
  biome-ignore.

All Vercel-specific logic stays in @workflow/world-vercel; @workflow/core
operates only on the generic WorkflowWorldError abstraction.



* Update .changeset/transport-error-redrive.md



* Trim changeset to a single sentence per review



* Route firewall-challenge 429s to the retryable transport path, not ThrottleError

A 429 carrying `x-vercel-mitigated: challenge` is a firewall challenge our
server-to-server client cannot solve, so it recurs for the life of the
incident. Mapping it to `ThrottleError` meant the `step_started` write deferred
it as `{ type: 'throttled' }`, which self-enqueues a FRESH queue message and
resets the delivery count — so it never backed off past `retryAfter` and never
reached `MAX_QUEUE_DELIVERIES`, hot-looping against an already-overloaded
firewall (the exact amplification this PR set out to remove, and contrary to
the "step_started can't loop unbounded" invariant, which only held for 5xx).

Map a challenge to a retryable transport `WorkflowWorldError` (`code:
'TRANSPORT'`) in both the v3 `makeRequest` and v4 `throwForErrorResponse`
(the hot event-write path) error mappings, via a shared `isFirewallChallenge429`
helper. It then propagates through the V1/V2 step paths and the replay loop's
retryable-world-error rethrow, earning the delivery-count backoff AND the
delivery cap. A genuine application-level 429 (no `challenge` mitigation) stays
a `ThrottleError` and keeps its `Retry-After`-paced defer.

Also correct the survival-window comments: with the 900s ceiling,
MAX_QUEUE_DELIVERIES=48 spans ~9-10h (~35,000s), not "the better part of 24h";
reaching 24h would need a higher delivery cap, not a higher per-hop ceiling.



---------

Signed-off-by: Peter Wielander <mittgfu@gmail.com>
Signed-off-by: Pranay Prakash <pranay.gp@gmail.com>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: Claude Opus 4.8 <noreply@anthropic.com>
Co-authored-by: Peter Wielander <mittgfu@gmail.com>
Co-authored-by: Peter Wielander <peter.wielander@vercel.com>
2026-06-29 13:03:50 -07:00
github-actions[bot] 8db7b7f864 Backport #2564: fix(next): discover root entrypoints (#2578) 2026-06-29 13:02:01 -07:00
github-actions[bot] af08c04da6 fix(nitro): reload steps during Vite HMR (#2572) (#2639) 2026-06-29 13:01:42 -07:00
github-actions[bot] 6f8730acc1 [ai] Fix WorkflowChatTransport reconnect test stale after framing normalizer (#2681) (#2682)
Co-authored-by: Peter Wielander <mittgfu@gmail.com>
2026-06-26 17:04:04 -07:00