Skip to content

fix(builders): resolve path aliases when externalizing non-step imports#1613

Merged
VaguelySerious merged 4 commits into
mainfrom
matchai/fix-vitest-path-aliases
Apr 7, 2026
Merged

fix(builders): resolve path aliases when externalizing non-step imports#1613
VaguelySerious merged 4 commits into
mainfrom
matchai/fix-vitest-path-aliases

Conversation

@matchai
Copy link
Copy Markdown
Member

@matchai matchai commented Apr 6, 2026

When step bundles externalize non-step imports that use path aliases (e.g. @/lib/config via tsconfig paths or esbuild alias), enhanced-resolve can't resolve them — it doesn't know about esbuild aliases or tsconfig path mappings. The unresolved import falls through to esbuild's native resolver which bundles it inline instead of externalizing.

This causes @workflow/vitest to fail at runtime with ERR_MODULE_NOT_FOUND for any project using path aliases in step function dependencies, since the step bundle inlines the code instead of producing externalized imports that vite-node can intercept for vi.mock().

Fix

When enhanced-resolve fails for a non-relative import, fall back to build.resolve (esbuild's own resolver) which handles both alias config and tsconfig paths. A pluginData guard prevents infinite re-entry. Additionally, isAbsolute(resolvedPath) is checked when deciding whether to compute a relative external path, since resolved alias paths are absolute even though the original import specifier isn't.

@changeset-bot
Copy link
Copy Markdown

changeset-bot Bot commented Apr 6, 2026

🦋 Changeset detected

Latest commit: 60ed9e5

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

This PR includes changesets to release 16 packages
Name Type
@workflow/builders Patch
@workflow/astro Patch
@workflow/cli Patch
@workflow/nest Patch
@workflow/next Patch
@workflow/nitro Patch
@workflow/rollup Patch
@workflow/sveltekit Patch
@workflow/vite Patch
@workflow/vitest Patch
workflow Patch
@workflow/world-testing Patch
@workflow/nuxt Patch
@workflow/ai 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

@vercel
Copy link
Copy Markdown
Contributor

vercel Bot commented Apr 6, 2026

@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented Apr 6, 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 🥇 Express 0.041s (-5.4% 🟢) 1.005s (~) 0.964s 10 1.00x
💻 Local Next.js (Turbopack) 0.041s 1.004s 0.964s 10 1.01x
🌐 Redis Next.js (Turbopack) 0.054s 1.005s 0.951s 10 1.33x
🐘 Postgres Next.js (Turbopack) 0.056s 1.009s 0.952s 10 1.39x
🐘 Postgres Nitro 0.058s (-0.9%) 1.010s (~) 0.951s 10 1.44x
🐘 Postgres Express 0.060s (-0.7%) 1.010s (~) 0.950s 10 1.48x
🌐 MongoDB Next.js (Turbopack) 0.071s 1.007s 0.936s 10 1.75x
💻 Local Nitro ⚠️ missing - - - -
workflow with 1 step

💻 Local Development

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
💻 Local 🥇 Next.js (Turbopack) 1.104s 2.005s 0.901s 10 1.00x
💻 Local Express 1.122s (-0.5%) 2.006s (~) 0.884s 10 1.02x
🌐 Redis Next.js (Turbopack) 1.123s 2.006s 0.883s 10 1.02x
🐘 Postgres Express 1.135s (-1.4%) 2.010s (~) 0.875s 10 1.03x
🐘 Postgres Next.js (Turbopack) 1.136s 2.009s 0.873s 10 1.03x
🐘 Postgres Nitro 1.147s (+0.8%) 2.009s (~) 0.862s 10 1.04x
🌐 MongoDB Next.js (Turbopack) 1.286s 2.009s 0.723s 10 1.16x
💻 Local Nitro ⚠️ missing - - - -
workflow with 10 sequential steps

💻 Local Development

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
💻 Local 🥇 Next.js (Turbopack) 10.654s 11.023s 0.369s 3 1.00x
🌐 Redis Next.js (Turbopack) 10.838s 11.022s 0.184s 3 1.02x
🐘 Postgres Nitro 10.842s (~) 11.016s (~) 0.174s 3 1.02x
🐘 Postgres Express 10.865s (~) 11.030s (~) 0.165s 3 1.02x
🐘 Postgres Next.js (Turbopack) 10.872s 11.020s 0.148s 3 1.02x
💻 Local Express 10.905s (-0.6%) 11.022s (~) 0.117s 3 1.02x
🌐 MongoDB Next.js (Turbopack) 12.241s 12.689s 0.448s 3 1.15x
💻 Local Nitro ⚠️ missing - - - -
workflow with 25 sequential steps

💻 Local Development

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
💻 Local 🥇 Next.js (Turbopack) 14.180s 15.028s 0.848s 4 1.00x
🌐 Redis Next.js (Turbopack) 14.220s 15.028s 0.808s 4 1.00x
🐘 Postgres Nitro 14.469s (-0.8%) 15.021s (~) 0.552s 4 1.02x
🐘 Postgres Next.js (Turbopack) 14.482s 15.021s 0.539s 4 1.02x
🐘 Postgres Express 14.539s (~) 15.024s (~) 0.485s 4 1.03x
💻 Local Express 14.909s (-0.5%) 15.029s (~) 0.119s 4 1.05x
🌐 MongoDB Next.js (Turbopack) 17.886s 18.026s 0.140s 4 1.26x
💻 Local Nitro ⚠️ missing - - - -
workflow with 50 sequential steps

💻 Local Development

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
🌐 Redis 🥇 Next.js (Turbopack) 13.482s 14.026s 0.543s 7 1.00x
🐘 Postgres Next.js (Turbopack) 13.746s 14.019s 0.273s 7 1.02x
🐘 Postgres Nitro 13.848s (-1.1%) 14.164s (~) 0.316s 7 1.03x
🐘 Postgres Express 13.973s (-1.5%) 14.452s (-2.9%) 0.479s 7 1.04x
💻 Local Next.js (Turbopack) 14.880s 15.027s 0.147s 6 1.10x
💻 Local Express 16.483s (-1.9%) 17.030s (~) 0.548s 6 1.22x
🌐 MongoDB Next.js (Turbopack) 20.466s 21.034s 0.568s 5 1.52x
💻 Local Nitro ⚠️ missing - - - -
Promise.all with 10 concurrent steps

💻 Local Development

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
🐘 Postgres 🥇 Next.js (Turbopack) 1.231s 2.009s 0.778s 15 1.00x
🐘 Postgres Nitro 1.255s (~) 2.009s (~) 0.754s 15 1.02x
🐘 Postgres Express 1.267s (-1.5%) 2.009s (~) 0.742s 15 1.03x
🌐 Redis Next.js (Turbopack) 1.304s 2.006s 0.702s 15 1.06x
💻 Local Express 1.497s (-2.4%) 2.005s (~) 0.508s 15 1.22x
💻 Local Next.js (Turbopack) 1.533s 2.072s 0.539s 15 1.24x
🌐 MongoDB Next.js (Turbopack) 2.147s 3.009s 0.862s 10 1.74x
💻 Local Nitro ⚠️ missing - - - -
Promise.all with 25 concurrent steps

💻 Local Development

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
🐘 Postgres 🥇 Express 2.307s (-0.9%) 3.009s (~) 0.702s 10 1.00x
🐘 Postgres Nitro 2.322s (-0.6%) 3.010s (~) 0.687s 10 1.01x
🐘 Postgres Next.js (Turbopack) 2.380s 3.010s 0.630s 10 1.03x
🌐 Redis Next.js (Turbopack) 2.580s 3.008s 0.428s 10 1.12x
💻 Local Next.js (Turbopack) 2.733s 3.008s 0.275s 10 1.18x
💻 Local Express 2.988s (-4.5%) 3.454s (-11.1% 🟢) 0.465s 9 1.30x
🌐 MongoDB Next.js (Turbopack) 8.589s 9.017s 0.428s 4 3.72x
💻 Local Nitro ⚠️ missing - - - -
Promise.all with 50 concurrent steps

💻 Local Development

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
🐘 Postgres 🥇 Nitro 3.445s (-1.2%) 4.008s (~) 0.563s 8 1.00x
🐘 Postgres Express 3.483s (~) 4.011s (~) 0.528s 8 1.01x
🐘 Postgres Next.js (Turbopack) 3.664s 4.012s 0.348s 8 1.06x
🌐 Redis Next.js (Turbopack) 4.205s 4.868s 0.663s 7 1.22x
💻 Local Next.js (Turbopack) 7.072s 7.619s 0.547s 5 2.05x
💻 Local Express 8.020s (-3.8%) 8.520s (-5.6% 🟢) 0.501s 4 2.33x
🌐 MongoDB Next.js (Turbopack) 20.273s 20.527s 0.254s 2 5.88x
💻 Local Nitro ⚠️ missing - - - -
Promise.race with 10 concurrent steps

💻 Local Development

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
🐘 Postgres 🥇 Next.js (Turbopack) 1.216s 2.008s 0.793s 15 1.00x
🐘 Postgres Nitro 1.250s (+0.6%) 2.007s (~) 0.757s 15 1.03x
🐘 Postgres Express 1.268s (+0.8%) 2.008s (~) 0.741s 15 1.04x
🌐 Redis Next.js (Turbopack) 1.357s 2.006s 0.649s 15 1.12x
💻 Local Next.js (Turbopack) 1.505s 2.005s 0.500s 15 1.24x
💻 Local Express 1.521s (-0.9%) 2.005s (~) 0.484s 15 1.25x
🌐 MongoDB Next.js (Turbopack) 3.107s 3.760s 0.653s 8 2.56x
💻 Local Nitro ⚠️ missing - - - -
Promise.race with 25 concurrent steps

💻 Local Development

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
🐘 Postgres 🥇 Nitro 2.304s (-0.7%) 3.009s (~) 0.705s 10 1.00x
🐘 Postgres Express 2.380s (+1.0%) 3.010s (~) 0.630s 10 1.03x
🐘 Postgres Next.js (Turbopack) 2.398s 3.009s 0.611s 10 1.04x
🌐 Redis Next.js (Turbopack) 2.564s 3.008s 0.443s 10 1.11x
💻 Local Next.js (Turbopack) 2.791s 3.007s 0.216s 10 1.21x
💻 Local Express 2.933s (-0.9%) 3.207s (-14.7% 🟢) 0.274s 10 1.27x
🌐 MongoDB Next.js (Turbopack) 9.252s 9.766s 0.515s 4 4.02x
💻 Local Nitro ⚠️ missing - - - -
Promise.race with 50 concurrent steps

💻 Local Development

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
🐘 Postgres 🥇 Nitro 3.474s (~) 4.010s (~) 0.536s 8 1.00x
🐘 Postgres Express 3.481s (~) 4.011s (~) 0.531s 8 1.00x
🐘 Postgres Next.js (Turbopack) 3.668s 4.015s 0.347s 8 1.06x
🌐 Redis Next.js (Turbopack) 4.238s 5.010s 0.772s 6 1.22x
💻 Local Next.js (Turbopack) 7.639s 8.268s 0.629s 4 2.20x
💻 Local Express 8.413s (-1.9%) 9.021s (~) 0.608s 4 2.42x
🌐 MongoDB Next.js (Turbopack) 20.578s 21.023s 0.445s 2 5.92x
💻 Local Nitro ⚠️ missing - - - -
workflow with 10 sequential data payload steps (10KB)

💻 Local Development

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
💻 Local 🥇 Next.js (Turbopack) 0.705s 1.021s 0.316s 59 1.00x
🌐 Redis Next.js (Turbopack) 0.724s 1.004s 0.280s 60 1.03x
🐘 Postgres Next.js (Turbopack) 0.757s 1.006s 0.249s 60 1.07x
🐘 Postgres Nitro 0.803s (-3.8%) 1.023s (+1.5%) 0.220s 59 1.14x
🐘 Postgres Express 0.821s (-4.8%) 1.006s (-1.7%) 0.185s 60 1.16x
💻 Local Express 1.065s (+9.3% 🔺) 1.158s (+7.7% 🔺) 0.093s 52 1.51x
🌐 MongoDB Next.js (Turbopack) 2.140s 3.009s 0.869s 20 3.04x
💻 Local Nitro ⚠️ missing - - - -
workflow with 25 sequential data payload steps (10KB)

💻 Local Development

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
🌐 Redis 🥇 Next.js (Turbopack) 1.768s 2.028s 0.261s 45 1.00x
🐘 Postgres Nitro 1.894s (-3.8%) 2.075s (-8.1% 🟢) 0.181s 44 1.07x
🐘 Postgres Next.js (Turbopack) 1.902s 2.075s 0.174s 44 1.08x
🐘 Postgres Express 1.974s (-5.8% 🟢) 2.316s (-20.5% 🟢) 0.342s 39 1.12x
💻 Local Next.js (Turbopack) 2.236s 3.007s 0.772s 30 1.26x
💻 Local Express 2.980s (-1.0%) 3.341s (-5.8% 🟢) 0.361s 27 1.69x
🌐 MongoDB Next.js (Turbopack) 5.288s 6.012s 0.724s 15 2.99x
💻 Local Nitro ⚠️ missing - - - -
workflow with 50 sequential data payload steps (10KB)

💻 Local Development

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
🌐 Redis 🥇 Next.js (Turbopack) 3.500s 4.008s 0.509s 30 1.00x
🐘 Postgres Next.js (Turbopack) 3.858s 4.076s 0.218s 30 1.10x
🐘 Postgres Nitro 3.942s (-1.5%) 4.296s (-0.8%) 0.353s 28 1.13x
🐘 Postgres Express 3.981s (-5.5% 🟢) 4.331s (-12.9% 🟢) 0.350s 28 1.14x
💻 Local Next.js (Turbopack) 7.290s 8.015s 0.725s 15 2.08x
💻 Local Express 9.093s (~) 9.710s (+1.6%) 0.617s 13 2.60x
🌐 MongoDB Next.js (Turbopack) 11.328s 12.021s 0.692s 10 3.24x
💻 Local Nitro ⚠️ missing - - - -
workflow with 10 concurrent data payload steps (10KB)

💻 Local Development

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
🐘 Postgres 🥇 Next.js (Turbopack) 0.253s 1.007s 0.755s 60 1.00x
🐘 Postgres Express 0.278s (-3.4%) 1.007s (~) 0.729s 60 1.10x
🐘 Postgres Nitro 0.278s (~) 1.006s (~) 0.728s 60 1.10x
🌐 Redis Next.js (Turbopack) 0.319s 1.004s 0.685s 60 1.26x
💻 Local Express 0.564s (-1.5%) 1.004s (~) 0.440s 60 2.23x
💻 Local Next.js (Turbopack) 0.579s 1.004s 0.425s 60 2.29x
🌐 MongoDB Next.js (Turbopack) 3.136s 3.884s 0.747s 16 12.41x
💻 Local Nitro ⚠️ missing - - - -
workflow with 25 concurrent data payload steps (10KB)

💻 Local Development

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
🐘 Postgres 🥇 Nitro 0.478s (-2.7%) 1.006s (~) 0.528s 90 1.00x
🐘 Postgres Express 0.486s (-1.1%) 1.006s (~) 0.520s 90 1.02x
🐘 Postgres Next.js (Turbopack) 0.489s 1.007s 0.518s 90 1.02x
🌐 Redis Next.js (Turbopack) 1.222s 2.006s 0.783s 45 2.56x
💻 Local Express 2.447s (-2.9%) 3.008s (~) 0.562s 30 5.12x
💻 Local Next.js (Turbopack) 2.537s 3.007s 0.471s 30 5.30x
🌐 MongoDB Next.js (Turbopack) 9.494s 10.014s 0.520s 9 19.85x
💻 Local Nitro ⚠️ missing - - - -
workflow with 50 concurrent data payload steps (10KB)

💻 Local Development

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
🐘 Postgres 🥇 Nitro 0.757s (-2.6%) 1.006s (~) 0.250s 120 1.00x
🐘 Postgres Next.js (Turbopack) 0.780s 1.006s 0.226s 120 1.03x
🐘 Postgres Express 0.781s (-3.2%) 1.007s (~) 0.226s 120 1.03x
🌐 Redis Next.js (Turbopack) 2.768s 3.032s 0.264s 40 3.66x
💻 Local Next.js (Turbopack) 9.775s 10.355s 0.580s 12 12.92x
💻 Local Express 10.859s (-3.9%) 11.389s (-3.9%) 0.530s 11 14.35x
🌐 MongoDB Next.js (Turbopack) 19.791s 20.362s 0.571s 6 26.16x
💻 Local Nitro ⚠️ missing - - - -
Stream Benchmarks (includes TTFB metrics)
workflow with stream

💻 Local Development

World Framework Workflow Time TTFB Slurp Wall Time Overhead Samples vs Fastest
💻 Local 🥇 Next.js (Turbopack) 0.139s 1.003s 0.010s 1.016s 0.877s 10 1.00x
🌐 Redis Next.js (Turbopack) 0.182s 1.001s 0.002s 1.008s 0.826s 10 1.31x
🐘 Postgres Next.js (Turbopack) 0.193s 1.001s 0.002s 1.011s 0.817s 10 1.39x
🐘 Postgres Nitro 0.195s (-4.2%) 0.990s (-0.9%) 0.002s (+46.2% 🔺) 1.009s (~) 0.815s 10 1.40x
💻 Local Express 0.200s (-4.5%) 1.004s (~) 0.011s (-4.3%) 1.017s (~) 0.817s 10 1.44x
🐘 Postgres Express 0.202s (-7.4% 🟢) 0.993s (~) 0.002s (+15.4% 🔺) 1.009s (~) 0.808s 10 1.45x
🌐 MongoDB Next.js (Turbopack) 0.506s 0.943s 0.001s 1.009s 0.503s 10 3.64x
💻 Local Nitro ⚠️ missing - - - - -
stream pipeline with 5 transform steps (1MB)

💻 Local Development

World Framework Workflow Time TTFB Slurp Wall Time Overhead Samples vs Fastest
🌐 Redis 🥇 Next.js (Turbopack) 0.502s 1.001s 0.003s 1.011s 0.509s 60 1.00x
🐘 Postgres Nitro 0.581s (-6.2% 🟢) 1.001s (~) 0.004s (+46.5% 🔺) 1.021s (~) 0.440s 59 1.16x
💻 Local Next.js (Turbopack) 0.587s 1.010s 0.009s 1.022s 0.435s 59 1.17x
🐘 Postgres Express 0.606s (~) 1.002s (~) 0.004s (+4.1%) 1.020s (~) 0.415s 59 1.21x
🐘 Postgres Next.js (Turbopack) 0.621s 1.009s 0.007s 1.025s 0.404s 59 1.24x
💻 Local Express 0.802s (-14.9% 🟢) 1.012s (~) 0.009s (+11.8% 🔺) 1.108s (-9.8% 🟢) 0.306s 59 1.60x
🌐 MongoDB Next.js (Turbopack) 1.325s 1.952s 0.003s 2.013s 0.688s 30 2.64x
💻 Local Nitro ⚠️ missing - - - - -
10 parallel streams (1MB each)

💻 Local Development

World Framework Workflow Time TTFB Slurp Wall Time Overhead Samples vs Fastest
🐘 Postgres 🥇 Nitro 0.920s (-3.1%) 1.103s (-7.7% 🟢) 0.000s (+85.2% 🔺) 1.118s (-7.5% 🟢) 0.198s 54 1.00x
🌐 Redis Next.js (Turbopack) 0.942s 1.034s 0.000s 1.039s 0.097s 58 1.02x
🐘 Postgres Next.js (Turbopack) 0.942s 1.201s 0.000s 1.209s 0.266s 50 1.02x
🐘 Postgres Express 0.948s (~) 1.120s (-4.2%) 0.000s (-5.6% 🟢) 1.137s (-4.0%) 0.189s 54 1.03x
💻 Local Express 1.207s (-15.8% 🟢) 2.020s (~) 0.000s (-30.0% 🟢) 2.021s (-8.2% 🟢) 0.815s 30 1.31x
💻 Local Next.js (Turbopack) 1.253s 2.019s 0.000s 2.022s 0.769s 30 1.36x
🌐 MongoDB Next.js (Turbopack) 2.370s 2.954s 0.000s 3.008s 0.639s 20 2.57x
💻 Local Nitro ⚠️ missing - - - - -
fan-out fan-in 10 streams (1MB each)

💻 Local Development

World Framework Workflow Time TTFB Slurp Wall Time Overhead Samples vs Fastest
🌐 Redis 🥇 Next.js (Turbopack) 1.641s 2.035s 0.000s 2.040s 0.398s 30 1.00x
🐘 Postgres Nitro 1.687s (-4.8%) 2.099s (~) 0.000s (+Infinity% 🔺) 2.112s (-1.4%) 0.425s 29 1.03x
🐘 Postgres Express 1.775s (~) 2.137s (+3.1%) 0.000s (-48.2% 🟢) 2.181s (+3.5%) 0.406s 28 1.08x
🐘 Postgres Next.js (Turbopack) 1.844s 2.107s 0.000s 2.149s 0.305s 28 1.12x
💻 Local Express 3.532s (-1.8%) 4.033s (-1.6%) 0.000s (-16.7% 🟢) 4.035s (-1.6%) 0.503s 15 2.15x
💻 Local Next.js (Turbopack) 3.762s 4.388s 0.000s 4.391s 0.629s 14 2.29x
🌐 MongoDB Next.js (Turbopack) 4.394s 4.954s 0.000s 5.011s 0.617s 12 2.68x
💻 Local Nitro ⚠️ missing - - - - -

Summary

Fastest Framework by World

Winner determined by most benchmark wins

World 🥇 Fastest Framework Wins
💻 Local Next.js (Turbopack) 15/21
🐘 Postgres Nitro 11/21
Fastest World by Framework

Winner determined by most benchmark wins

Framework 🥇 Fastest World Wins
Express 🐘 Postgres 18/21
Next.js (Turbopack) 🐘 Postgres 9/21
Nitro 🐘 Postgres 21/21
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


Some benchmark jobs failed:

  • Local: failure
  • Postgres: success
  • Vercel: cancelled

Check the workflow run for details.

@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented Apr 6, 2026

🧪 E2E Test Results

Some tests failed

Summary

Passed Failed Skipped Total
✅ ▲ Vercel Production 868 0 67 935
✅ 💻 Local Development 842 0 178 1020
✅ 📦 Local Production 842 0 178 1020
✅ 🐘 Local Postgres 842 0 178 1020
✅ 🪟 Windows 77 0 8 85
❌ 🌍 Community Worlds 134 64 24 222
✅ 📋 Other 213 0 42 255
Total 3818 64 675 4557

❌ Failed Tests

🌍 Community Worlds (64 failed)

mongodb (4 failed):

  • hookWorkflow is not resumable via public webhook endpoint | wrun_01KNJJ0BRGD5Y1K6KRF3XFBVTD
  • webhookWorkflow | wrun_01KNJJ0M8BJ61MTREYEK6JQXRS
  • concurrent hook token conflict - two workflows cannot use the same hook token simultaneously | wrun_01KNJJ84KKVXPT87DR8RFP1JEW
  • resilient start: addTenWorkflow completes when run_created returns 500

redis (3 failed):

  • hookWorkflow is not resumable via public webhook endpoint | wrun_01KNJJ0BRGD5Y1K6KRF3XFBVTD
  • concurrent hook token conflict - two workflows cannot use the same hook token simultaneously | wrun_01KNJJ84KKVXPT87DR8RFP1JEW
  • resilient start: addTenWorkflow completes when run_created returns 500

turso (57 failed):

  • addTenWorkflow | wrun_01KNJHZ5Z5Y17WMWA28HTRQBB0
  • addTenWorkflow | wrun_01KNJHZ5Z5Y17WMWA28HTRQBB0
  • wellKnownAgentWorkflow (.well-known/agent) | wrun_01KNJJ10GRZPVQRWYP7CRM2Q9A
  • should work with react rendering in step
  • promiseAllWorkflow | wrun_01KNJHZC28TJTK2FHND11MVT6B
  • promiseRaceWorkflow | wrun_01KNJHZJR5ZCREVVDADZ1C93Y0
  • promiseAnyWorkflow | wrun_01KNJHZMQ4DP17M7TC6CCRXDNX
  • importedStepOnlyWorkflow | wrun_01KNJJ1CFA0BPQFQ7XG26BABC9
  • hookWorkflow | wrun_01KNJJ00XPDWKRD72F55BEXWMR
  • hookWorkflow is not resumable via public webhook endpoint | wrun_01KNJJ0BRGD5Y1K6KRF3XFBVTD
  • webhookWorkflow | wrun_01KNJJ0M8BJ61MTREYEK6JQXRS
  • sleepingWorkflow | wrun_01KNJJ0SD2X4T0EEBBDVHDG8XQ
  • parallelSleepWorkflow | wrun_01KNJJ15WR7SSJNE295MTN5C1B
  • nullByteWorkflow | wrun_01KNJJ1AC8HB9HKEK5GJ4YDPZW
  • workflowAndStepMetadataWorkflow | wrun_01KNJJ1D3B0TR9WJ4THT961CNB
  • fetchWorkflow | wrun_01KNJJ41ZPMPP2BBKPGTNRMV3H
  • promiseRaceStressTestWorkflow | wrun_01KNJJ455HBJE31XZ02F0Q41CS
  • 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()
  • error handling not registered WorkflowNotRegisteredError fails the run when workflow does not exist
  • error handling not registered StepNotRegisteredError fails the step but workflow can catch it
  • error handling not registered StepNotRegisteredError fails the run when not caught in workflow
  • hookCleanupTestWorkflow - hook token reuse after workflow completion | wrun_01KNJJ7H0225SCEM16PQ53Z5JD
  • concurrent hook token conflict - two workflows cannot use the same hook token simultaneously | wrun_01KNJJ84KKVXPT87DR8RFP1JEW
  • hookDisposeTestWorkflow - hook token reuse after explicit disposal while workflow still running | wrun_01KNJJ8RPZVEBVDEHP7R84P4SS
  • stepFunctionPassingWorkflow - step function references can be passed as arguments (without closure vars) | wrun_01KNJJ9B43DSJ1GATGD76YMG1E
  • stepFunctionWithClosureWorkflow - step function with closure variables passed as argument | wrun_01KNJJ9K3WJQ121K9AGEGJ36GJ
  • closureVariableWorkflow - nested step functions with closure variables | wrun_01KNJJ9R2DEMS43D7WNBFRFRXX
  • spawnWorkflowFromStepWorkflow - spawning a child workflow using start() inside a step | wrun_01KNJJ9T25Y6NT9ZQJXM801PSA
  • health check (queue-based) - workflow and step endpoints respond to health check messages
  • pathsAliasWorkflow - TypeScript path aliases resolve correctly | wrun_01KNJJA8MWV038S0A8TG9Y4PNH
  • Calculator.calculate - static workflow method using static step methods from another class | wrun_01KNJJAE6V1F9WPB859TP0MQYC
  • AllInOneService.processNumber - static workflow method using sibling static step methods | wrun_01KNJJAMAKHRBHQV3BNN438GPA
  • ChainableService.processWithThis - static step methods using this to reference the class | wrun_01KNJJATK4WVYFN15WPJT6BDQH
  • thisSerializationWorkflow - step function invoked with .call() and .apply() | wrun_01KNJJB1W5BAS0HFW5QCAWYPMS
  • customSerializationWorkflow - custom class serialization with WORKFLOW_SERIALIZE/WORKFLOW_DESERIALIZE | wrun_01KNJJB9RT18BD54Y4HW26R2V6
  • instanceMethodStepWorkflow - instance methods with "use step" directive | wrun_01KNJJBFVGXP9HQE3WG8TVBBSQ
  • crossContextSerdeWorkflow - classes defined in step code are deserializable in workflow context | wrun_01KNJJBT6EHVK2H5QV7H5BDNQV
  • stepFunctionAsStartArgWorkflow - step function reference passed as start() argument | wrun_01KNJJC2B4AVV86G13J5VR9JM0
  • cancelRun - cancelling a running workflow | wrun_01KNJJC8KAFV8RC2G3Q1DSFRZ9
  • cancelRun via CLI - cancelling a running workflow | wrun_01KNJJCHGA5T18XJ4CY9XVQRB4
  • pages router addTenWorkflow via pages router
  • pages router promiseAllWorkflow via pages router
  • pages router sleepingWorkflow via pages router
  • hookWithSleepWorkflow - hook payloads delivered correctly with concurrent sleep | wrun_01KNJJCWR1CGBHKH63B09WF2PG
  • sleepInLoopWorkflow - sleep inside loop with steps actually delays each iteration | wrun_01KNJJDG3025A11SCE1ME12T3P
  • sleepWithSequentialStepsWorkflow - sequential steps work with concurrent sleep (control) | wrun_01KNJJDTCEXA4T7N8MZKK9AF2C
  • importMetaUrlWorkflow - import.meta.url is available in step bundles | wrun_01KNJJE174B3W6M9P7FBYYCAWY
  • metadataFromHelperWorkflow - getWorkflowMetadata/getStepMetadata work from module-level helper (#1577) | wrun_01KNJJE37BW05HP1KMPS71QY4E
  • resilient start: addTenWorkflow completes when run_created returns 500

Details by Category

✅ ▲ Vercel Production
App Passed Failed Skipped
✅ astro 78 0 7
✅ example 78 0 7
✅ express 78 0 7
✅ fastify 78 0 7
✅ hono 78 0 7
✅ nextjs-turbopack 83 0 2
✅ nextjs-webpack 83 0 2
✅ nitro 78 0 7
✅ nuxt 78 0 7
✅ sveltekit 78 0 7
✅ vite 78 0 7
✅ 💻 Local Development
App Passed Failed Skipped
✅ astro-stable 71 0 14
✅ express-stable 71 0 14
✅ fastify-stable 71 0 14
✅ hono-stable 71 0 14
✅ nextjs-turbopack-canary 60 0 25
✅ nextjs-turbopack-stable 77 0 8
✅ nextjs-webpack-canary 60 0 25
✅ nextjs-webpack-stable 77 0 8
✅ nitro-stable 71 0 14
✅ nuxt-stable 71 0 14
✅ sveltekit-stable 71 0 14
✅ vite-stable 71 0 14
✅ 📦 Local Production
App Passed Failed Skipped
✅ astro-stable 71 0 14
✅ express-stable 71 0 14
✅ fastify-stable 71 0 14
✅ hono-stable 71 0 14
✅ nextjs-turbopack-canary 60 0 25
✅ nextjs-turbopack-stable 77 0 8
✅ nextjs-webpack-canary 60 0 25
✅ nextjs-webpack-stable 77 0 8
✅ nitro-stable 71 0 14
✅ nuxt-stable 71 0 14
✅ sveltekit-stable 71 0 14
✅ vite-stable 71 0 14
✅ 🐘 Local Postgres
App Passed Failed Skipped
✅ astro-stable 71 0 14
✅ express-stable 71 0 14
✅ fastify-stable 71 0 14
✅ hono-stable 71 0 14
✅ nextjs-turbopack-canary 60 0 25
✅ nextjs-turbopack-stable 77 0 8
✅ nextjs-webpack-canary 60 0 25
✅ nextjs-webpack-stable 77 0 8
✅ nitro-stable 71 0 14
✅ nuxt-stable 71 0 14
✅ sveltekit-stable 71 0 14
✅ vite-stable 71 0 14
✅ 🪟 Windows
App Passed Failed Skipped
✅ nextjs-turbopack 77 0 8
❌ 🌍 Community Worlds
App Passed Failed Skipped
✅ mongodb-dev 5 0 0
❌ mongodb 57 4 8
✅ redis-dev 5 0 0
❌ redis 58 3 8
✅ turso-dev 5 0 0
❌ turso 4 57 8
✅ 📋 Other
App Passed Failed Skipped
✅ e2e-local-dev-nest-stable 71 0 14
✅ e2e-local-postgres-nest-stable 71 0 14
✅ e2e-local-prod-nest-stable 71 0 14

📋 View full workflow run

The isAbsolute(resolvedPath) condition for detecting file paths was
too broad, matching bare npm specifiers (e.g. lodash.chunk) that
enhanced-resolve already resolved to absolute node_modules paths.
This caused Rollup to reject the relativized paths in Nitro builds.

Gate the check behind resolvedViaEsbuild so it only applies to
alias/tsconfig paths resolved by the esbuild fallback.
…larity

Reject esbuild fallback results that resolve into node_modules to
preserve the nested dep bundling invariant. Refactor resolution
variables for clarity: separate specifier from resolvedPath, rename
isFilePath to shouldMakeRelative, add regression test for aliased
imports targeting node_modules.
Copy link
Copy Markdown
Member

@VaguelySerious VaguelySerious left a comment

Choose a reason for hiding this comment

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

AI review: no blocking issues

const output = result.outputFiles[0].text;
expect(output).toContain('/lib/config.js');
expect(output).not.toContain('@/lib/config');
});
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.

AI Review: Note

This test uses esbuild alias to set up the path alias, but the more common real-world scenario is tsconfig paths (which is how most Next.js / Vite projects configure @/* aliases). Consider adding a test that uses a tsconfig.json with compilerOptions.paths and passes it via esbuild's tsconfig option — this would exercise the same build.resolve() fallback path but through the tsconfig resolution pipeline that most users actually hit.

I verified locally that this does work (wrote a test using tsconfig: join(testRoot, 'tsconfig.json') with paths: { "@/*": ["./src/*"] } instead of alias), but having it in the test suite would increase confidence.

didResolve &&
!esbuildResult.path
.replace(/\\/g, '/')
.includes('/node_modules/');
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.

AI Review: Nit

The /node_modules/ string check works for the common case but could theoretically match a project directory literally named node_modules in its path (e.g. /home/user/my-node_modules-tools/src/lib.ts). This is extremely unlikely and I don't think it warrants a change, but worth noting for future awareness.

!esbuildResult.path
.replace(/\\/g, '/')
.includes('/node_modules/');
if (isProjectLocalFile) {
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.

AI Review: Note

When the esbuild fallback resolves an aliased path that also appears in sideEffectEntries, the hasSideEffects check (line 170) uses normalizedResolvedPath — which at this point is correctly set from esbuildResult.path. So the sideEffects flag should propagate correctly for aliased imports. However, there's no test coverage for this interaction. A test where an aliased import matches a sideEffectEntries entry would be valuable.

@VaguelySerious VaguelySerious merged commit 3308701 into main Apr 7, 2026
159 of 166 checks passed
@VaguelySerious VaguelySerious deleted the matchai/fix-vitest-path-aliases branch April 7, 2026 00:01
@ghost ghost mentioned this pull request Apr 6, 2026
VaguelySerious added a commit that referenced this pull request Apr 7, 2026
PR #1613 added an esbuild fallback for resolving path aliases when
enhanced-resolve fails. However, Node.js builtins like `crypto` and
`node:path` also fail enhanced-resolve, and esbuild resolves them to
absolute paths outside node_modules. The `isProjectLocalFile` check
then incorrectly relativizes them (e.g. `../../../../../../crypto`),
breaking Next.js builds.

Fix: check `isBuiltin(specifier)` before falling through to the
esbuild resolver, so builtins are left as bare specifiers.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
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