Skip to content

Fix anonymous class expression names for serialization classes#991

Merged
TooTallNate merged 2 commits intomainfrom
02-10-fix_anonymous_class_expression_names_for_serialization_classes
Feb 11, 2026
Merged

Fix anonymous class expression names for serialization classes#991
TooTallNate merged 2 commits intomainfrom
02-10-fix_anonymous_class_expression_names_for_serialization_classes

Conversation

@TooTallNate
Copy link
Copy Markdown
Member

When upstream bundlers like tsup/esbuild transform class declarations into anonymous class expressions (e.g. var Foo = class { ... }), the SWC plugin now re-inserts the binding name into the class expression (e.g. var Foo = class Foo { ... }). This preserves the class .name property through subsequent bundling passes, preventing runtime failures in downstream bundlers like Nitro's Rollup bundler that rely on the class expression name for serialization class registration.

@changeset-bot
Copy link
Copy Markdown

changeset-bot Bot commented Feb 10, 2026

🦋 Changeset detected

Latest commit: 8d57648

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

This PR includes changesets to release 15 packages
Name Type
@workflow/swc-plugin Patch
@workflow/astro Patch
@workflow/builders Patch
@workflow/cli Patch
@workflow/nest Patch
@workflow/next Patch
@workflow/nitro Patch
@workflow/rollup Patch
@workflow/sveltekit Patch
workflow Patch
@workflow/vite Patch
@workflow/world-testing Patch
@workflow/nuxt Patch
@workflow/core Patch
@workflow/web-shared 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

Copy link
Copy Markdown
Member Author

This stack of pull requests is managed by Graphite. Learn more about stacking.

@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented Feb 10, 2026

🧪 E2E Test Results

Some tests failed

Summary

Passed Failed Skipped Total
✅ ▲ Vercel Production 490 0 38 528
✅ 💻 Local Development 418 0 62 480
✅ 📦 Local Production 418 0 62 480
✅ 🐘 Local Postgres 418 0 62 480
✅ 🪟 Windows 45 0 3 48
❌ 🌍 Community Worlds 103 41 9 153
✅ 📋 Other 123 0 21 144
Total 2015 41 257 2313

❌ Failed Tests

🌍 Community Worlds (41 failed)

turso (41 failed):

  • addTenWorkflow
  • addTenWorkflow
  • should work with react rendering in step
  • promiseAllWorkflow
  • promiseRaceWorkflow
  • promiseAnyWorkflow
  • hookWorkflow
  • webhookWorkflow
  • sleepingWorkflow
  • nullByteWorkflow
  • workflowAndStepMetadataWorkflow
  • fetchWorkflow
  • promiseRaceStressTestWorkflow
  • error handling error propagation workflow errors nested function calls preserve message and stack trace
  • error handling error propagation workflow errors cross-file imports preserve message and stack trace
  • error handling error propagation step errors basic step error preserves message and stack trace
  • error handling error propagation step errors cross-file step error preserves message and function names in stack
  • error handling retry behavior regular Error retries until success
  • error handling retry behavior FatalError fails immediately without retries
  • error handling retry behavior RetryableError respects custom retryAfter delay
  • error handling retry behavior maxRetries=0 disables retries
  • error handling catchability FatalError can be caught and detected with FatalError.is()
  • hookCleanupTestWorkflow - hook token reuse after workflow completion
  • concurrent hook token conflict - two workflows cannot use the same hook token simultaneously
  • stepFunctionPassingWorkflow - step function references can be passed as arguments (without closure vars)
  • stepFunctionWithClosureWorkflow - step function with closure variables passed as argument
  • closureVariableWorkflow - nested step functions with closure variables
  • spawnWorkflowFromStepWorkflow - spawning a child workflow using start() inside a step
  • health check (queue-based) - workflow and step endpoints respond to health check messages
  • pathsAliasWorkflow - TypeScript path aliases resolve correctly
  • Calculator.calculate - static workflow method using static step methods from another class
  • AllInOneService.processNumber - static workflow method using sibling static step methods
  • ChainableService.processWithThis - static step methods using this to reference the class
  • thisSerializationWorkflow - step function invoked with .call() and .apply()
  • customSerializationWorkflow - custom class serialization with WORKFLOW_SERIALIZE/WORKFLOW_DESERIALIZE
  • instanceMethodStepWorkflow - instance methods with "use step" directive
  • crossContextSerdeWorkflow - classes defined in step code are deserializable in workflow context
  • stepFunctionAsStartArgWorkflow - step function reference passed as start() argument
  • pages router addTenWorkflow via pages router
  • pages router promiseAllWorkflow via pages router
  • pages router sleepingWorkflow via pages router

Details by Category

✅ ▲ Vercel Production
App Passed Failed Skipped
✅ astro 44 0 4
✅ example 44 0 4
✅ express 44 0 4
✅ fastify 44 0 4
✅ hono 44 0 4
✅ nextjs-turbopack 47 0 1
✅ nextjs-webpack 47 0 1
✅ nitro 44 0 4
✅ nuxt 44 0 4
✅ sveltekit 44 0 4
✅ vite 44 0 4
✅ 💻 Local Development
App Passed Failed Skipped
✅ astro-stable 41 0 7
✅ express-stable 41 0 7
✅ fastify-stable 41 0 7
✅ hono-stable 41 0 7
✅ nextjs-turbopack-stable 45 0 3
✅ nextjs-webpack-stable 45 0 3
✅ nitro-stable 41 0 7
✅ nuxt-stable 41 0 7
✅ sveltekit-stable 41 0 7
✅ vite-stable 41 0 7
✅ 📦 Local Production
App Passed Failed Skipped
✅ astro-stable 41 0 7
✅ express-stable 41 0 7
✅ fastify-stable 41 0 7
✅ hono-stable 41 0 7
✅ nextjs-turbopack-stable 45 0 3
✅ nextjs-webpack-stable 45 0 3
✅ nitro-stable 41 0 7
✅ nuxt-stable 41 0 7
✅ sveltekit-stable 41 0 7
✅ vite-stable 41 0 7
✅ 🐘 Local Postgres
App Passed Failed Skipped
✅ astro-stable 41 0 7
✅ express-stable 41 0 7
✅ fastify-stable 41 0 7
✅ hono-stable 41 0 7
✅ nextjs-turbopack-stable 45 0 3
✅ nextjs-webpack-stable 45 0 3
✅ nitro-stable 41 0 7
✅ nuxt-stable 41 0 7
✅ sveltekit-stable 41 0 7
✅ vite-stable 41 0 7
✅ 🪟 Windows
App Passed Failed Skipped
✅ nextjs-turbopack 45 0 3
❌ 🌍 Community Worlds
App Passed Failed Skipped
✅ mongodb-dev 3 0 0
✅ mongodb 45 0 3
✅ redis-dev 3 0 0
✅ redis 45 0 3
✅ turso-dev 3 0 0
❌ turso 4 41 3
✅ 📋 Other
App Passed Failed Skipped
✅ e2e-local-dev-nest-stable 41 0 7
✅ e2e-local-postgres-nest-stable 41 0 7
✅ e2e-local-prod-nest-stable 41 0 7

📋 View full workflow run

@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented Feb 10, 2026

📊 Benchmark Results

📈 Comparing against baseline from main branch. Green 🟢 = faster, Red 🔺 = slower.

workflow with no steps

💻 Local Development

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
💻 Local 🥇 Nitro 0.031s (-4.0%) 1.004s (~) 0.973s 10 1.00x
💻 Local Express 0.032s (-0.6%) 1.005s (~) 0.973s 10 1.01x
💻 Local Next.js (Turbopack) 0.040s 1.005s 0.964s 10 1.28x
🌐 Redis Next.js (Turbopack) 0.048s 1.004s 0.957s 10 1.53x
🌐 MongoDB Next.js (Turbopack) 0.095s 1.007s 0.912s 10 3.02x
🐘 Postgres Express 0.117s (-47.6% 🟢) 1.010s (~) 0.893s 10 3.72x
🐘 Postgres Nitro 0.122s (+6.8% 🔺) 1.010s (~) 0.888s 10 3.89x
🐘 Postgres Next.js (Turbopack) 0.398s 1.009s 0.610s 10 12.68x

▲ Production (Vercel)

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Nitro 0.757s (-17.7% 🟢) 2.073s (-8.1% 🟢) 1.316s 10 1.00x
▲ Vercel Express 0.788s (-5.0% 🟢) 2.103s (-8.3% 🟢) 1.314s 10 1.04x
▲ Vercel Next.js (Turbopack) 1.034s (+17.5% 🔺) 2.500s (+20.8% 🔺) 1.466s 10 1.36x

🔍 Observability: Nitro | Express | Next.js (Turbopack)

workflow with 1 step

💻 Local Development

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
💻 Local 🥇 Next.js (Turbopack) 1.101s 2.005s 0.904s 10 1.00x
💻 Local Express 1.103s (~) 2.004s (~) 0.901s 10 1.00x
💻 Local Nitro 1.105s (~) 2.005s (~) 0.899s 10 1.00x
🌐 Redis Next.js (Turbopack) 1.109s 2.006s 0.897s 10 1.01x
🌐 MongoDB Next.js (Turbopack) 1.305s 2.007s 0.702s 10 1.19x
🐘 Postgres Next.js (Turbopack) 1.808s 2.011s 0.203s 10 1.64x
🐘 Postgres Nitro 2.439s (~) 3.014s (~) 0.576s 10 2.22x
🐘 Postgres Express 2.446s (+16.2% 🔺) 3.019s (~) 0.573s 10 2.22x

▲ Production (Vercel)

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Nitro 2.672s (-1.4%) 3.499s (-4.0%) 0.827s 10 1.00x
▲ Vercel Next.js (Turbopack) 2.743s (-6.6% 🟢) 3.605s (-13.2% 🟢) 0.862s 10 1.03x
▲ Vercel Express 2.797s (~) 3.961s (+1.4%) 1.163s 10 1.05x

🔍 Observability: Nitro | Next.js (Turbopack) | Express

workflow with 10 sequential steps

💻 Local Development

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
🌐 Redis 🥇 Next.js (Turbopack) 10.722s 11.022s 0.300s 3 1.00x
💻 Local Next.js (Turbopack) 10.740s 11.021s 0.282s 3 1.00x
💻 Local Nitro 10.824s (~) 11.021s (~) 0.197s 3 1.01x
💻 Local Express 10.828s (~) 11.023s (~) 0.194s 3 1.01x
🌐 MongoDB Next.js (Turbopack) 12.179s 13.016s 0.838s 3 1.14x
🐘 Postgres Next.js (Turbopack) 14.947s 15.544s 0.598s 2 1.39x
🐘 Postgres Express 20.303s (-1.0%) 21.058s (~) 0.754s 2 1.89x
🐘 Postgres Nitro 20.331s (~) 21.059s (~) 0.728s 2 1.90x

▲ Production (Vercel)

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Express 20.636s (-11.3% 🟢) 21.364s (-13.6% 🟢) 0.728s 2 1.00x
▲ Vercel Nitro 20.881s (-9.7% 🟢) 21.757s (-10.8% 🟢) 0.876s 2 1.01x
▲ Vercel Next.js (Turbopack) 21.390s (+0.5%) 23.125s (+1.8%) 1.736s 2 1.04x

🔍 Observability: Express | Nitro | Next.js (Turbopack)

workflow with 25 sequential steps

💻 Local Development

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
🌐 Redis 🥇 Next.js (Turbopack) 26.883s 27.049s 0.166s 3 1.00x
💻 Local Next.js (Turbopack) 27.216s 28.055s 0.839s 3 1.01x
💻 Local Express 27.452s (~) 28.048s (~) 0.596s 3 1.02x
💻 Local Nitro 27.470s (~) 28.051s (~) 0.581s 3 1.02x
🌐 MongoDB Next.js (Turbopack) 30.322s 31.028s 0.706s 2 1.13x
🐘 Postgres Next.js (Turbopack) 33.506s 33.577s 0.071s 2 1.25x
🐘 Postgres Express 50.295s (~) 50.627s (-1.0%) 0.332s 2 1.87x
🐘 Postgres Nitro 50.319s (~) 51.135s (~) 0.816s 2 1.87x

▲ Production (Vercel)

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Nitro 51.744s (-1.6%) 52.832s (-1.4%) 1.088s 2 1.00x
▲ Vercel Next.js (Turbopack) 51.869s (-3.2%) 53.492s (-1.6%) 1.623s 2 1.00x
▲ Vercel Express 54.551s (+3.6%) 55.713s (+3.6%) 1.162s 2 1.05x

🔍 Observability: Nitro | Next.js (Turbopack) | Express

workflow with 50 sequential steps

💻 Local Development

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
🌐 Redis 🥇 Next.js (Turbopack) 54.261s 55.096s 0.835s 2 1.00x
💻 Local Next.js (Turbopack) 56.710s 57.105s 0.395s 2 1.05x
💻 Local Express 57.137s (~) 58.102s (~) 0.965s 2 1.05x
💻 Local Nitro 57.230s (~) 58.101s (~) 0.871s 2 1.05x
🌐 MongoDB Next.js (Turbopack) 60.682s 61.055s 0.372s 2 1.12x
🐘 Postgres Next.js (Turbopack) 67.302s 68.161s 0.859s 2 1.24x
🐘 Postgres Nitro 98.161s (-2.1%) 98.221s (-3.0%) 0.060s 1 1.81x
🐘 Postgres Express 100.164s (~) 100.224s (-1.0%) 0.060s 1 1.85x

▲ Production (Vercel)

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Next.js (Turbopack) 109.039s (+1.9%) 110.276s (+2.1%) 1.237s 1 1.00x
▲ Vercel Express 114.385s (+6.0% 🔺) 115.921s (+5.7% 🔺) 1.536s 1 1.05x
▲ Vercel Nitro 119.083s (+5.4% 🔺) 120.097s (+4.8%) 1.014s 1 1.09x

🔍 Observability: Next.js (Turbopack) | Express | Nitro

Promise.all with 10 concurrent steps

💻 Local Development

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
🌐 Redis 🥇 Next.js (Turbopack) 1.250s 2.006s 0.756s 15 1.00x
💻 Local Express 1.400s (~) 2.005s (~) 0.606s 15 1.12x
💻 Local Next.js (Turbopack) 1.411s 2.005s 0.594s 15 1.13x
💻 Local Nitro 1.426s (+0.8%) 2.006s (~) 0.580s 15 1.14x
🐘 Postgres Next.js (Turbopack) 2.147s 2.512s 0.364s 12 1.72x
🌐 MongoDB Next.js (Turbopack) 2.166s 3.007s 0.842s 10 1.73x
🐘 Postgres Nitro 2.264s (-2.1%) 2.830s (-6.1% 🟢) 0.567s 11 1.81x
🐘 Postgres Express 2.273s (-0.8%) 3.013s (~) 0.740s 10 1.82x

▲ Production (Vercel)

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Next.js (Turbopack) 3.021s (-25.7% 🟢) 4.023s (-26.7% 🟢) 1.003s 8 1.00x
▲ Vercel Nitro 3.051s (+4.5%) 4.474s (+17.1% 🔺) 1.423s 7 1.01x
▲ Vercel Express 3.338s (+13.2% 🔺) 4.131s (+5.9% 🔺) 0.792s 8 1.11x

🔍 Observability: Next.js (Turbopack) | Nitro | Express

Promise.all with 25 concurrent steps

💻 Local Development

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
🌐 Redis 🥇 Next.js (Turbopack) 2.482s 3.008s 0.526s 10 1.00x
💻 Local Next.js (Turbopack) 2.501s 3.008s 0.507s 10 1.01x
💻 Local Express 2.573s (+1.5%) 3.008s (~) 0.434s 10 1.04x
💻 Local Nitro 2.636s (+2.4%) 3.008s (~) 0.372s 10 1.06x
🌐 MongoDB Next.js (Turbopack) 4.668s 5.176s 0.509s 6 1.88x
🐘 Postgres Nitro 9.266s (+0.8%) 9.542s (~) 0.276s 4 3.73x
🐘 Postgres Express 10.402s (+39.0% 🔺) 10.710s (+29.3% 🔺) 0.308s 3 4.19x
🐘 Postgres Next.js (Turbopack) 12.413s 12.701s 0.288s 3 5.00x

▲ Production (Vercel)

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Nitro 3.048s (-13.4% 🟢) 4.475s (-8.6% 🟢) 1.427s 7 1.00x
▲ Vercel Next.js (Turbopack) 3.323s (-2.2%) 5.020s (+9.0% 🔺) 1.698s 6 1.09x
▲ Vercel Express 3.484s (+2.5%) 4.690s (+2.2%) 1.205s 7 1.14x

🔍 Observability: Nitro | Next.js (Turbopack) | Express

Promise.all with 50 concurrent steps

💻 Local Development

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
🌐 Redis 🥇 Next.js (Turbopack) 4.011s 4.581s 0.571s 7 1.00x
💻 Local Next.js (Turbopack) 7.473s 8.021s 0.548s 4 1.86x
💻 Local Express 7.480s (+3.3%) 8.020s (~) 0.539s 4 1.87x
💻 Local Nitro 7.652s (+7.2% 🔺) 8.019s (~) 0.367s 4 1.91x
🌐 MongoDB Next.js (Turbopack) 10.075s 10.348s 0.274s 3 2.51x
🐘 Postgres Express 49.351s (+3.7%) 50.139s (+4.2%) 0.788s 1 12.30x
🐘 Postgres Nitro 50.278s (+8.9% 🔺) 51.111s (+8.5% 🔺) 0.833s 1 12.54x
🐘 Postgres Next.js (Turbopack) 53.640s 54.126s 0.486s 1 13.37x

▲ Production (Vercel)

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Nitro 4.162s (+15.2% 🔺) 5.217s (+7.4% 🔺) 1.055s 6 1.00x
▲ Vercel Next.js (Turbopack) 4.909s (+17.3% 🔺) 6.357s (+16.9% 🔺) 1.448s 6 1.18x
▲ Vercel Express 5.638s (+55.9% 🔺) 6.814s (+40.1% 🔺) 1.176s 5 1.35x

🔍 Observability: Nitro | Next.js (Turbopack) | Express

Promise.race with 10 concurrent steps

💻 Local Development

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
🌐 Redis 🥇 Next.js (Turbopack) 1.274s 2.006s 0.731s 15 1.00x
💻 Local Next.js (Turbopack) 1.413s 2.005s 0.592s 15 1.11x
💻 Local Express 1.440s (+0.8%) 2.005s (~) 0.565s 15 1.13x
💻 Local Nitro 1.448s (+2.0%) 2.006s (~) 0.558s 15 1.14x
🐘 Postgres Nitro 2.125s (-1.8%) 2.596s (-11.3% 🟢) 0.471s 12 1.67x
🌐 MongoDB Next.js (Turbopack) 2.157s 3.008s 0.851s 10 1.69x
🐘 Postgres Express 2.188s (+4.2%) 2.595s (+3.3%) 0.407s 12 1.72x
🐘 Postgres Next.js (Turbopack) 2.608s 2.922s 0.314s 11 2.05x

▲ Production (Vercel)

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Express 2.716s (-4.9%) 3.588s (-2.8%) 0.872s 9 1.00x
▲ Vercel Next.js (Turbopack) 2.785s (-4.5%) 3.621s (-14.8% 🟢) 0.836s 9 1.03x
▲ Vercel Nitro 3.276s (+15.8% 🔺) 4.062s (+4.8%) 0.785s 8 1.21x

🔍 Observability: Express | Next.js (Turbopack) | Nitro

Promise.race with 25 concurrent steps

💻 Local Development

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
🌐 Redis 🥇 Next.js (Turbopack) 2.503s 3.008s 0.505s 10 1.00x
💻 Local Next.js (Turbopack) 2.557s 3.007s 0.451s 10 1.02x
💻 Local Express 2.661s (-3.8%) 3.007s (~) 0.347s 10 1.06x
💻 Local Nitro 2.756s (+2.2%) 3.007s (~) 0.251s 10 1.10x
🌐 MongoDB Next.js (Turbopack) 4.815s 5.177s 0.362s 6 1.92x
🐘 Postgres Express 11.345s (-1.1%) 11.700s (-2.8%) 0.356s 3 4.53x
🐘 Postgres Nitro 11.693s (-2.5%) 12.030s (-5.3% 🟢) 0.337s 3 4.67x
🐘 Postgres Next.js (Turbopack) 13.981s 14.706s 0.724s 3 5.59x

▲ Production (Vercel)

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Express 3.367s (-5.0%) 4.491s (-0.6%) 1.125s 8 1.00x
▲ Vercel Nitro 3.701s (+20.9% 🔺) 4.636s (~) 0.935s 7 1.10x
▲ Vercel Next.js (Turbopack) 4.158s (+4.8%) 5.478s (+6.0% 🔺) 1.320s 6 1.23x

🔍 Observability: Express | Nitro | Next.js (Turbopack)

Promise.race with 50 concurrent steps

💻 Local Development

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
🌐 Redis 🥇 Next.js (Turbopack) 4.044s 4.581s 0.537s 7 1.00x
💻 Local Next.js (Turbopack) 7.618s 8.016s 0.398s 4 1.88x
💻 Local Express 7.787s (+2.8%) 8.028s (~) 0.241s 4 1.93x
💻 Local Nitro 7.905s (+2.8%) 8.270s (+3.1%) 0.365s 4 1.95x
🌐 MongoDB Next.js (Turbopack) 9.764s 10.350s 0.586s 3 2.41x
🐘 Postgres Express 50.523s (-6.2% 🟢) 51.122s (-5.5% 🟢) 0.599s 1 12.49x
🐘 Postgres Nitro 51.354s (+3.6%) 52.131s (+4.0%) 0.777s 1 12.70x
🐘 Postgres Next.js (Turbopack) 58.463s 59.124s 0.661s 1 14.46x

▲ Production (Vercel)

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Express 3.452s (-12.2% 🟢) 4.642s (-16.1% 🟢) 1.190s 7 1.00x
▲ Vercel Next.js (Turbopack) 4.236s (-17.8% 🟢) 5.752s (-8.0% 🟢) 1.517s 6 1.23x
▲ Vercel Nitro 6.459s (+83.8% 🔺) 7.317s (+43.6% 🔺) 0.858s 5 1.87x

🔍 Observability: Express | Next.js (Turbopack) | Nitro

Stream Benchmarks (includes TTFB metrics)
workflow with stream

💻 Local Development

World Framework Workflow Time TTFB Slurp Wall Time Overhead Samples vs Fastest
🌐 Redis 🥇 Next.js (Turbopack) 0.149s 1.000s 0.001s 1.007s 0.857s 10 1.00x
💻 Local Next.js (Turbopack) 0.150s 1.001s 0.011s 1.016s 0.865s 10 1.01x
💻 Local Express 0.171s (~) 1.002s (~) 0.011s (+1.0%) 1.015s (~) 0.844s 10 1.15x
💻 Local Nitro 0.174s (+0.8%) 1.002s (~) 0.010s (+1.0%) 1.015s (~) 0.841s 10 1.17x
🌐 MongoDB Next.js (Turbopack) 0.515s 0.934s 0.001s 1.008s 0.493s 10 3.45x
🐘 Postgres Next.js (Turbopack) 0.612s 0.921s 0.001s 1.009s 0.397s 10 4.10x
🐘 Postgres Express 1.291s (-41.2% 🟢) 1.748s (-38.4% 🟢) 0.001s (~) 2.013s (-33.2% 🟢) 0.722s 10 8.64x
🐘 Postgres Nitro 1.298s (-45.2% 🟢) 1.742s (-34.8% 🟢) 0.001s (~) 2.012s (-33.3% 🟢) 0.715s 10 8.68x

▲ Production (Vercel)

World Framework Workflow Time TTFB Slurp Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Express 2.715s (+2.9%) 3.349s (+12.1% 🔺) 0.099s (-60.5% 🟢) 4.075s (+3.5%) 1.360s 10 1.00x
▲ Vercel Nitro 2.725s (-3.1%) 3.002s (-0.7%) 0.212s (+63.7% 🔺) 3.825s (-2.5%) 1.100s 10 1.00x
▲ Vercel Next.js (Turbopack) 2.944s (+7.8% 🔺) 3.394s (+5.1% 🔺) 0.260s (+14.1% 🔺) 4.397s (+7.1% 🔺) 1.454s 10 1.08x

🔍 Observability: Express | Nitro | Next.js (Turbopack)

Summary

Fastest Framework by World

Winner determined by most benchmark wins

World 🥇 Fastest Framework Wins
💻 Local Next.js (Turbopack) 10/12
🐘 Postgres Next.js (Turbopack) 6/12
▲ Vercel Nitro 5/12
Fastest World by Framework

Winner determined by most benchmark wins

Framework 🥇 Fastest World Wins
Express 💻 Local 10/12
Next.js (Turbopack) 🌐 Redis 10/12
Nitro 💻 Local 10/12
Column Definitions
  • Workflow Time: Runtime reported by workflow (completedAt - createdAt) - primary metric
  • TTFB: Time to First Byte - time from workflow start until first stream byte received (stream benchmarks only)
  • Slurp: Time from first byte to complete stream consumption (stream benchmarks only)
  • Wall Time: Total testbench time (trigger workflow + poll for result)
  • Overhead: Testbench overhead (Wall Time - Workflow Time)
  • Samples: Number of benchmark iterations run
  • vs Fastest: How much slower compared to the fastest configuration for this benchmark

Worlds:

  • 💻 Local: In-memory filesystem world (local development)
  • 🐘 Postgres: PostgreSQL database world (local development)
  • ▲ Vercel: Vercel production/preview deployment
  • 🌐 Turso: Community world (local development)
  • 🌐 MongoDB: Community world (local development)
  • 🌐 Redis: Community world (local development)
  • 🌐 Jazz: Community world (local development)

📋 View full workflow run

@vercel
Copy link
Copy Markdown
Contributor

vercel Bot commented Feb 10, 2026

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 Feb 11, 2026 11:27pm
example-nextjs-workflow-webpack Ready Ready Preview, Comment Feb 11, 2026 11:27pm
example-workflow Ready Ready Preview, Comment Feb 11, 2026 11:27pm
workbench-astro-workflow Ready Ready Preview, Comment Feb 11, 2026 11:27pm
workbench-express-workflow Ready Ready Preview, Comment Feb 11, 2026 11:27pm
workbench-fastify-workflow Ready Ready Preview, Comment Feb 11, 2026 11:27pm
workbench-hono-workflow Ready Ready Preview, Comment Feb 11, 2026 11:27pm
workbench-nitro-workflow Ready Ready Preview, Comment Feb 11, 2026 11:27pm
workbench-nuxt-workflow Ready Ready Preview, Comment Feb 11, 2026 11:27pm
workbench-sveltekit-workflow Ready Ready Preview, Comment Feb 11, 2026 11:27pm
workbench-vite-workflow Ready Ready Preview, Comment Feb 11, 2026 11:27pm
workflow-docs Ready Ready Preview, Comment, Open in v0 Feb 11, 2026 11:27pm
workflow-nest Ready Ready Preview, Comment Feb 11, 2026 11:27pm
workflow-swc-playground Ready Ready Preview, Comment Feb 11, 2026 11:27pm

@TooTallNate TooTallNate marked this pull request as ready for review February 11, 2026 23:10
@TooTallNate TooTallNate requested review from a team and Copilot February 11, 2026 23:10
When upstream bundlers like tsup/esbuild transform class declarations into anonymous class expressions (e.g. `var Foo = class { ... }`), the SWC plugin now re-inserts the binding name into the class expression (e.g. `var Foo = class Foo { ... }`). This preserves the class `.name` property through subsequent bundling passes, preventing runtime failures in downstream bundlers like Nitro's Rollup bundler that rely on the class expression name for serialization class registration.
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR updates the @workflow/swc-plugin transform to preserve class names for serializable classes when upstream bundlers convert named class declarations into anonymous class expressions, preventing downstream bundlers from losing the class identifier during subsequent bundling passes.

Changes:

  • Update the SWC transform to re-insert the variable binding name into anonymous class expressions when custom serialization methods are present.
  • Update transform fixture outputs to reflect the newly named class expressions.
  • Document the behavior in spec.md and publish a patch changeset.

Reviewed changes

Copilot reviewed 6 out of 6 changed files in this pull request and generated 3 comments.

Show a summary per file
File Description
packages/swc-plugin-workflow/transform/src/lib.rs Implements binding-name re-insertion for anonymous serializable class expressions.
packages/swc-plugin-workflow/transform/tests/fixture/class-expression-binding-name/output-workflow.js Updates expected workflow-mode fixture output to include class Shell.
packages/swc-plugin-workflow/transform/tests/fixture/class-expression-binding-name/output-step.js Updates expected step-mode fixture output to include class Shell.
packages/swc-plugin-workflow/transform/tests/fixture/class-expression-binding-name/output-client.js Updates expected client-mode fixture output to include class Shell.
packages/swc-plugin-workflow/spec.md Documents the anonymous class expression name re-insertion behavior.
.changeset/happy-doodles-return.md Adds a patch changeset for the plugin release.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread packages/swc-plugin-workflow/spec.md Outdated
Comment thread packages/swc-plugin-workflow/transform/src/lib.rs
Comment thread packages/swc-plugin-workflow/transform/src/lib.rs Outdated
Copy link
Copy Markdown
Contributor

@pranaygp pranaygp left a comment

Choose a reason for hiding this comment

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

Looks good. Clean, well-scoped fix.

The guard conditions (has_serde && class_expr.ident.is_none()) correctly ensure this only fires for anonymous serialization classes, leaving named class expressions (like class _Bash) untouched. Test fixtures and spec updated appropriately.

…recompute internal_class_name after ident insertion
@TooTallNate TooTallNate enabled auto-merge (squash) February 11, 2026 23:25
@TooTallNate TooTallNate merged commit 054e40c into main Feb 11, 2026
98 checks passed
@TooTallNate TooTallNate deleted the 02-10-fix_anonymous_class_expression_names_for_serialization_classes branch February 11, 2026 23:34
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.

4 participants