Files
vercel__workflow/.changeset/preserve-step-fn-names.md
Nathan Rajlich 136bd35a98 fix(swc-plugin): preserve step function names in stack traces after bundler minification (#1743)
* fix(swc-plugin): preserve step function names in stack traces after bundler minification

Add Object.defineProperty(fn, 'name', { value, configurable: true }) to the
IIFE step registration so the original function name survives bundler name
mangling (e.g. Turbopack renaming errorStepFn to eD). V8 uses the .name
property for stack traces, so this ensures 'at errorStepFn (...)' appears
instead of 'at eD (...)'.

* Apply suggestion from @Copilot

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Signed-off-by: Nathan Rajlich <n@n8.io>

---------

Signed-off-by: Nathan Rajlich <n@n8.io>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2026-04-16 20:20:26 +00:00

170 B

@workflow/swc-plugin
@workflow/swc-plugin
patch

Preserve original step function names in stack traces by setting Object.defineProperty(fn, "name", ...) in the IIFE registration