Skip to content

[core] Rename experimental_setAttributes to setAttributes#2882

Merged
VaguelySerious merged 1 commit into
mainfrom
peter/rename-set-attributes
Jul 11, 2026
Merged

[core] Rename experimental_setAttributes to setAttributes#2882
VaguelySerious merged 1 commit into
mainfrom
peter/rename-set-attributes

Conversation

@VaguelySerious

@VaguelySerious VaguelySerious commented Jul 11, 2026

Copy link
Copy Markdown
Member

Summary

The attributes feature is no longer experimental, so the experimental_setAttributes export is renamed to setAttributes.

  • setAttributes is now exported from workflow (both the host-side and workflow-VM entrypoints), along with the SetAttributesOptions type.
  • experimental_setAttributes (and the ExperimentalSetAttributesOptions type) remain as deprecated aliases so existing code keeps working; they will be removed in a future release.
  • Error messages, doc comments, workbench e2e workflows, and tests now use the new name. Unit tests cover the deprecated alias.

Docs

  • The API reference page moved from api-reference/workflow/experimental-set-attributes to api-reference/workflow/set-attributes, with permanent redirects for the old URL (both versioned and unversioned paths).
  • The Observability → Attributes page drops the experimental callout and uses the new name; links in start and the workflow package index were updated.
  • The new API reference page notes the old name as a deprecated alias.

🤖 Generated with Claude Code

Docs Preview

Page v5
setAttributes API reference (renamed page) /v5/docs/api-reference/workflow/set-attributes
Observability → Attributes /v5/docs/observability/attributes
workflow package index (updated card) /v5/docs/api-reference/workflow
start() (updated link) /v5/docs/api-reference/workflow-api/start
Old URL redirect /v5/docs/api-reference/workflow/experimental-set-attributes

The attributes feature is no longer experimental. The old
experimental_setAttributes export remains as a deprecated alias.
Docs page moved to api-reference/workflow/set-attributes with
redirects from the old URL.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@VaguelySerious VaguelySerious requested review from a team and ijjk as code owners July 11, 2026 01:16
@vercel

vercel Bot commented Jul 11, 2026

Copy link
Copy Markdown
Contributor

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
example-nextjs-workflow-turbopack Ready Ready Preview, Comment Jul 11, 2026 1:19am
example-nextjs-workflow-webpack Ready Ready Preview, Comment Jul 11, 2026 1:19am
example-workflow Ready Ready Preview, Comment Jul 11, 2026 1:19am
workbench-astro-workflow Ready Ready Preview, Comment Jul 11, 2026 1:19am
workbench-express-workflow Ready Ready Preview, Comment Jul 11, 2026 1:19am
workbench-fastify-workflow Ready Ready Preview, Comment Jul 11, 2026 1:19am
workbench-hono-workflow Ready Ready Preview, Comment Jul 11, 2026 1:19am
workbench-nitro-workflow Ready Ready Preview, Comment Jul 11, 2026 1:19am
workbench-nuxt-workflow Ready Ready Preview, Comment Jul 11, 2026 1:19am
workbench-sveltekit-workflow Ready Ready Preview, Comment Jul 11, 2026 1:19am
workbench-tanstack-start-workflow Ready Ready Preview, Comment Jul 11, 2026 1:19am
workbench-vite-workflow Ready Ready Preview, Comment Jul 11, 2026 1:19am
workflow-docs Ready Ready Preview, Comment, Open in v0 Jul 11, 2026 1:19am
workflow-swc-playground Ready Ready Preview, Comment Jul 11, 2026 1:19am
workflow-tarballs Ready Ready Preview, Comment Jul 11, 2026 1:19am
workflow-web Ready Ready Preview, Comment Jul 11, 2026 1:19am

@changeset-bot

changeset-bot Bot commented Jul 11, 2026

Copy link
Copy Markdown

🦋 Changeset detected

Latest commit: ee88cbe

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 20 packages
Name Type
@workflow/world Patch
@workflow/core Minor
workflow Minor
@workflow/cli Patch
@workflow/vitest Patch
@workflow/web-shared Patch
@workflow/web Patch
@workflow/world-local Patch
@workflow/world-postgres Patch
@workflow/world-testing Patch
@workflow/world-vercel Patch
@workflow/builders Patch
@workflow/next Patch
@workflow/nitro Patch
@workflow/astro Patch
@workflow/nest Patch
@workflow/nuxt Patch
@workflow/rollup Patch
@workflow/sveltekit Patch
@workflow/vite Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@github-actions

github-actions Bot commented Jul 11, 2026

Copy link
Copy Markdown
Contributor

🧪 E2E Test Results

All tests passed

Summary

Passed Failed Skipped Total
✅ ▲ Vercel Production 1453 0 230 1683
✅ 💻 Local Development 1617 0 219 1836
✅ 📦 Local Production 1617 0 219 1836
✅ 🐘 Local Postgres 1617 0 219 1836
✅ 🪟 Windows 153 0 0 153
✅ 📋 Other 894 0 177 1071
Total 7351 0 1064 8415

Details by Category

✅ ▲ Vercel Production
App Passed Failed Skipped
✅ astro 126 0 27
✅ example 126 0 27
✅ express 126 0 27
✅ fastify 126 0 27
✅ hono 126 0 27
✅ nextjs-turbopack 150 0 3
✅ nextjs-webpack 150 0 3
✅ nitro 126 0 27
✅ nuxt 126 0 27
✅ sveltekit 145 0 8
✅ vite 126 0 27
✅ 💻 Local Development
App Passed Failed Skipped
✅ astro-stable 128 0 25
✅ express-stable 128 0 25
✅ fastify-stable 128 0 25
✅ hono-stable 128 0 25
✅ nextjs-turbopack-canary 134 0 19
✅ nextjs-turbopack-stable 153 0 0
✅ nextjs-webpack-canary 134 0 19
✅ nextjs-webpack-stable 153 0 0
✅ nitro-stable 128 0 25
✅ nuxt-stable 128 0 25
✅ sveltekit-stable 147 0 6
✅ vite-stable 128 0 25
✅ 📦 Local Production
App Passed Failed Skipped
✅ astro-stable 128 0 25
✅ express-stable 128 0 25
✅ fastify-stable 128 0 25
✅ hono-stable 128 0 25
✅ nextjs-turbopack-canary 134 0 19
✅ nextjs-turbopack-stable 153 0 0
✅ nextjs-webpack-canary 134 0 19
✅ nextjs-webpack-stable 153 0 0
✅ nitro-stable 128 0 25
✅ nuxt-stable 128 0 25
✅ sveltekit-stable 147 0 6
✅ vite-stable 128 0 25
✅ 🐘 Local Postgres
App Passed Failed Skipped
✅ astro-stable 128 0 25
✅ express-stable 128 0 25
✅ fastify-stable 128 0 25
✅ hono-stable 128 0 25
✅ nextjs-turbopack-canary 134 0 19
✅ nextjs-turbopack-stable 153 0 0
✅ nextjs-webpack-canary 134 0 19
✅ nextjs-webpack-stable 153 0 0
✅ nitro-stable 128 0 25
✅ nuxt-stable 128 0 25
✅ sveltekit-stable 147 0 6
✅ vite-stable 128 0 25
✅ 🪟 Windows
App Passed Failed Skipped
✅ nextjs-turbopack 153 0 0
✅ 📋 Other
App Passed Failed Skipped
✅ e2e-local-dev-nest-stable 128 0 25
✅ e2e-local-dev-tanstack-start- 128 0 25
✅ e2e-local-postgres-nest-stable 128 0 25
✅ e2e-local-postgres-tanstack-start- 128 0 25
✅ e2e-local-prod-nest-stable 128 0 25
✅ e2e-local-prod-tanstack-start- 128 0 25
✅ e2e-vercel-prod-tanstack-start 126 0 27

📋 View full workflow run

@github-actions

github-actions Bot commented Jul 11, 2026

Copy link
Copy Markdown
Contributor

📊 Workflow Benchmarks

commit ee88cbe · Sat, 11 Jul 2026 01:36:03 GMT · run logs

Backend: vercel · app: nextjs-turbopack

Metric Scenario Avg (ms) P75 (ms) P90 (ms) P99 (ms) Samples
TTFS stream 1392 (-1.3%) 1662 🔴 1693 🔴 1860 🔴 30
TTFS hook + stream 1633 (±0%) 1973 🔴 2035 🔴 2135 🔴 30
STSO 1020 steps (1-20) 278 (-1.3%) 332 🔴 384 🔴 550 🔴 19
STSO 1020 steps (101-120) 443 (+9.6%) 492 🔴 606 🔴 684 🔴 19
STSO 1020 steps (1001-1020) 1027 (+25%) 885 🔴 916 🔴 4621 🔴 19
WO stream 1392 (-1.3%) 1662 1693 1860 30
WO hook + stream 1633 (±0%) 1973 2035 2135 30
SL stream 4367 (-13%) 4836 🔴 5669 🔴 5910 🔴 30
SL hook + stream 4768 (±0%) 5339 🔴 5590 🔴 5679 🔴 30

Avg deltas compare against the most recent benchmark run on main at the time of this run.

Metrics — TTFS: time to first step body execution · STSO: step-to-step overhead (gap between consecutive step bodies) · WO: workflow overhead (time outside step bodies, client start → last step body exit) · SL: stream latency (first chunk write → visible to the reader)

Scenarios — stream: one step that streams chunks back to the client; no hooks, so the run stays in turbo mode · hook + stream: registers a hook before the same streaming step, which exits turbo mode · 1020 steps: 1020 trivial sequential steps; STSO is measured between consecutive steps in the given step ranges

🟢/🔴 mark percentiles within/above target. Targets (p75/p90/p99, ms) — TTFS 200/300/600 · SL 50/60/125 · STSO (1-20) 20/30/60 · STSO (101-120) 30/45/90 · STSO (1001-1020) 40/60/120

TTFS/WO compare client vs deployment clocks and SL compares the step runner’s clock vs the client’s (NTP-synced in CI). WO ends at the last step body exit, the closest observable proxy for the final step-completion request.

@TooTallNate TooTallNate left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Clean graduation rename. No blocking issues.

Changes reviewed (23 files, +201/-162):

  1. Deprecated aliases done right: export const experimental_setAttributes = setAttributes with @deprecated JSDoc in BOTH entrypoints (host-side core/src/set-attributes.ts and workflow-VM core/src/workflow/set-attributes.ts), plus ExperimentalSetAttributesOptions = SetAttributesOptions type alias. Existing code keeps compiling and gets editor deprecation hints. Unit tests cover the alias.
  2. Docs: API reference page renamed with permanent redirects in next.config.ts covering both the versioned (/v5/...) and unversioned paths — the comment explaining the unversioned path matters once v5 becomes default is a nice touch. The old-name callout on the new page helps people landing from stale links/snippets.
  3. Consistency sweep: error messages, doc comments, workbench e2e workflows, and the Observability → Attributes page (experimental callout dropped, "Experimental Behavior" → "Behavior") all updated.
  4. Changesets: minor for @workflow/core + workflow (new export), patch for @workflow/world (doc comments only). Correct semver classification.

All CI green. LGTM.

@VaguelySerious VaguelySerious merged commit 0b956f6 into main Jul 11, 2026
170 of 172 checks passed
@VaguelySerious VaguelySerious deleted the peter/rename-set-attributes branch July 11, 2026 17:17
@github-actions

Copy link
Copy Markdown
Contributor

No backport to stable for 0b956f6 (AI decision).

This commit renames the experimental_setAttributes export to setAttributes, but the entire attributes feature (the set-attributes.ts files, the experimental_setAttributes/normalizeAttributeChanges code, and the attributes field on WorkflowRunBaseSchema) does not exist on stable — verified via git ls-tree/git grep. The remaining changes only touch docs/content/docs/v5/ (a docs version not shipped on stable) and a docs/next.config.ts redirect for that v5 path, so there is nothing on stable for this rename to apply to.

To override, re-run the Backport to stable workflow manually via workflow_dispatch and paste this commit SHA into the ref input:

0b956f65cb0ab30501c72e934fc8d4352c4c3ea2

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