Skip to content

Fix node-module-error plugin matching identifiers in multi-line comments#1554

Open
pranaygp wants to merge 3 commits intomainfrom
fix/node-module-plugin-multiline-comments
Open

Fix node-module-error plugin matching identifiers in multi-line comments#1554
pranaygp wants to merge 3 commits intomainfrom
fix/node-module-plugin-multiline-comments

Conversation

@pranaygp
Copy link
Copy Markdown
Collaborator

Summary

  • Fix findIdentifierUsage in the workflow-node-module-error esbuild plugin to properly skip multi-line block comments (including JSDoc)
  • Previously, lines inside /** ... */ blocks didn't get stripped because the old regex only handled same-line /* ... */ — causing the plugin to point error locations at comment text instead of actual code usage
  • Add tests for both JSDoc and single-line block comment skipping

Test plan

  • All 34 existing tests pass
  • New test: JSDoc comment with identifier is skipped, error points to actual code
  • New test: single-line block comment with identifier is skipped

🤖 Generated with Claude Code

The findIdentifierUsage function only stripped single-line comments and
same-line block comments, but didn't track multi-line block comment state.
Lines inside JSDoc/block comments (e.g. ` * ... Writable stream`) passed
through unstripped, causing the plugin to point at comments instead of
actual code usage.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@pranaygp pranaygp requested a review from a team as a code owner March 30, 2026 07:53
Copilot AI review requested due to automatic review settings March 30, 2026 07:53
@vercel
Copy link
Copy Markdown
Contributor

vercel bot commented Mar 30, 2026

@changeset-bot
Copy link
Copy Markdown

changeset-bot bot commented Mar 30, 2026

🦋 Changeset detected

Latest commit: aa319fe

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

@github-actions
Copy link
Copy Markdown
Contributor

github-actions bot commented Mar 30, 2026

🧪 E2E Test Results

Some tests failed

Summary

Passed Failed Skipped Total
❌ ▲ Vercel Production 845 1 67 913
✅ 💻 Local Development 818 0 178 996
✅ 📦 Local Production 818 0 178 996
✅ 🐘 Local Postgres 818 0 178 996
✅ 🪟 Windows 75 0 8 83
❌ 🌍 Community Worlds 132 60 24 216
✅ 📋 Other 207 0 42 249
Total 3713 61 675 4449

❌ Failed Tests

▲ Vercel Production (1 failed)

nextjs-webpack (1 failed):

  • hookDisposeTestWorkflow - hook token reuse after explicit disposal while workflow still running | wrun_01KN03X09QPWQFK23WV9JRAK6A | 🔍 observability
🌍 Community Worlds (60 failed)

mongodb (3 failed):

  • hookWorkflow is not resumable via public webhook endpoint | wrun_01KN03KE94VDR23E99WJCFDM77
  • webhookWorkflow | wrun_01KN03KQ6D2MSH20RP2WP2YGP8
  • concurrent hook token conflict - two workflows cannot use the same hook token simultaneously | wrun_01KN03W7WC926WQDY57QMF1HG4

redis (2 failed):

  • hookWorkflow is not resumable via public webhook endpoint | wrun_01KN03KE94VDR23E99WJCFDM77
  • concurrent hook token conflict - two workflows cannot use the same hook token simultaneously | wrun_01KN03W7WC926WQDY57QMF1HG4

turso (55 failed):

  • addTenWorkflow | wrun_01KN03J54G16GE7MYY4EFWQ0E3
  • addTenWorkflow | wrun_01KN03J54G16GE7MYY4EFWQ0E3
  • wellKnownAgentWorkflow (.well-known/agent) | wrun_01KN03KWXADJJPBHBV36SR8T4W
  • should work with react rendering in step
  • promiseAllWorkflow | wrun_01KN03JF6QN9DF3VRRTCQ8PAAT
  • promiseRaceWorkflow | wrun_01KN03JMC4GMMNBDZYYMSH4PJ6
  • promiseAnyWorkflow | wrun_01KN03JPMW24EKAHR9F0C91VXR
  • importedStepOnlyWorkflow | wrun_01KN03M95NHG32S3SBTA607EP1
  • hookWorkflow | wrun_01KN03K2VXDH2YS5R3NR6H1CFT
  • hookWorkflow is not resumable via public webhook endpoint | wrun_01KN03KE94VDR23E99WJCFDM77
  • webhookWorkflow | wrun_01KN03KQ6D2MSH20RP2WP2YGP8
  • sleepingWorkflow | wrun_01KN03KXJRB9RTAHC2KB3Q1M4S
  • parallelSleepWorkflow | wrun_01KN03M9AS7YX6J2TWTQBF78J9
  • nullByteWorkflow | wrun_01KN03MCY8XWWG5SY5NX0B9KQN
  • workflowAndStepMetadataWorkflow | wrun_01KN03MF7RCZVMRFMQW5WGWDFK
  • fetchWorkflow | wrun_01KN03Q6NXJEVV0NVBFCVZACT5
  • promiseRaceStressTestWorkflow | wrun_01KN03QAABNTSQM94TWB3D8YJA
  • 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_01KN03VETQXT2TPRSSJRCSM3NF
  • concurrent hook token conflict - two workflows cannot use the same hook token simultaneously | wrun_01KN03W7WC926WQDY57QMF1HG4
  • hookDisposeTestWorkflow - hook token reuse after explicit disposal while workflow still running | wrun_01KN03X09QPWQFK23WV9JRAK6A
  • stepFunctionPassingWorkflow - step function references can be passed as arguments (without closure vars) | wrun_01KN03XMFMHRT1GREM7Z04HN1R
  • stepFunctionWithClosureWorkflow - step function with closure variables passed as argument | wrun_01KN03XXVB6HKKHF4RD2A94DH1
  • closureVariableWorkflow - nested step functions with closure variables | wrun_01KN03Y3NGX606SMJ3FS8BK3NS
  • spawnWorkflowFromStepWorkflow - spawning a child workflow using start() inside a step | wrun_01KN03Y80JV0825GEQ5Y9R0F3Z
  • health check (queue-based) - workflow and step endpoints respond to health check messages
  • pathsAliasWorkflow - TypeScript path aliases resolve correctly | wrun_01KN03YQT28RWDMH1J4MZBT20M
  • Calculator.calculate - static workflow method using static step methods from another class | wrun_01KN03YXV0BH9Y8XWTCA90YGW5
  • AllInOneService.processNumber - static workflow method using sibling static step methods | wrun_01KN03Z4M1FK80T0CF7T3GCNYN
  • ChainableService.processWithThis - static step methods using this to reference the class | wrun_01KN03ZBCYDTR2DV1MXKFSEH8N
  • thisSerializationWorkflow - step function invoked with .call() and .apply() | wrun_01KN03ZJKYJCBFXJ145RGP36C0
  • customSerializationWorkflow - custom class serialization with WORKFLOW_SERIALIZE/WORKFLOW_DESERIALIZE | wrun_01KN03ZSF10F91R3Z353AXAFGY
  • instanceMethodStepWorkflow - instance methods with "use step" directive | wrun_01KN0403VAHRCNHMTCM79ZHG2F
  • crossContextSerdeWorkflow - classes defined in step code are deserializable in workflow context | wrun_01KN040F9X009S2B25R1SMRQ7B
  • stepFunctionAsStartArgWorkflow - step function reference passed as start() argument | wrun_01KN041F40FXKPMM4TMH0VPBXS
  • cancelRun - cancelling a running workflow | wrun_01KN041P05MCT3Q0ATHJ592D75
  • cancelRun via CLI - cancelling a running workflow | wrun_01KN041ZE0K9KK5V8VV5V1RKQ1
  • 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_01KN042C0FCQ059RKV476HA8A9
  • sleepInLoopWorkflow - sleep inside loop with steps actually delays each iteration | wrun_01KN0430P693NB08FNTHFE9D0G
  • sleepWithSequentialStepsWorkflow - sequential steps work with concurrent sleep (control) | wrun_01KN043BYG3ECJNQYKMD7RZC9S
  • importMetaUrlWorkflow - import.meta.url is available in step bundles

Details by Category

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

📋 View full workflow run


Some E2E test jobs failed:

  • Vercel Prod: failure
  • Local Dev: success
  • Local Prod: success
  • Local Postgres: success
  • Windows: success

Check the workflow run for details.

@github-actions
Copy link
Copy Markdown
Contributor

github-actions bot commented Mar 30, 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.045s (-15.0% 🟢) 1.006s (-1.0%) 0.961s 10 1.00x
💻 Local Express 0.045s (+1.3%) 1.005s (~) 0.960s 10 1.01x
💻 Local Next.js (Turbopack) 0.051s 1.005s 0.955s 10 1.13x
🐘 Postgres Nitro 0.051s (-20.0% 🟢) 1.010s (~) 0.959s 10 1.14x
🌐 Redis Next.js (Turbopack) 0.053s 1.005s 0.952s 10 1.19x
🐘 Postgres Next.js (Turbopack) 0.057s 1.010s 0.953s 10 1.27x
🐘 Postgres Express 0.065s (-0.8%) 1.012s (~) 0.947s 10 1.45x
🌐 MongoDB Next.js (Turbopack) 0.088s 1.007s 0.919s 10 1.96x

▲ Production (Vercel)

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Nitro 0.767s (-39.2% 🟢) 2.974s (-17.2% 🟢) 2.207s 10 1.00x
▲ Vercel Express 1.371s (+72.9% 🔺) 3.844s (+25.3% 🔺) 2.473s 10 1.79x
▲ Vercel Next.js (Turbopack) ⚠️ missing - - - -

🔍 Observability: Nitro | Express

workflow with 1 step

💻 Local Development

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
🐘 Postgres 🥇 Nitro 1.121s (-2.8%) 2.011s (~) 0.890s 10 1.00x
💻 Local Next.js (Turbopack) 1.124s 2.006s 0.882s 10 1.00x
💻 Local Express 1.127s (~) 2.006s (~) 0.879s 10 1.01x
🌐 Redis Next.js (Turbopack) 1.131s 2.007s 0.876s 10 1.01x
💻 Local Nitro 1.135s (~) 2.006s (~) 0.872s 10 1.01x
🐘 Postgres Next.js (Turbopack) 1.138s 2.012s 0.874s 10 1.02x
🐘 Postgres Express 1.155s (+0.7%) 2.012s (~) 0.857s 10 1.03x
🌐 MongoDB Next.js (Turbopack) 1.322s 2.009s 0.686s 10 1.18x

▲ Production (Vercel)

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Nitro 2.419s (+9.5% 🔺) 3.970s (-4.9%) 1.552s 10 1.00x
▲ Vercel Express 2.425s (+3.9%) 4.452s (+0.8%) 2.027s 10 1.00x
▲ Vercel Next.js (Turbopack) ⚠️ missing - - - -

🔍 Observability: Nitro | Express

workflow with 10 sequential steps

💻 Local Development

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
🐘 Postgres 🥇 Nitro 10.673s (-2.1%) 11.020s (~) 0.347s 3 1.00x
🌐 Redis Next.js (Turbopack) 10.737s 11.023s 0.286s 3 1.01x
💻 Local Next.js (Turbopack) 10.786s 11.024s 0.239s 3 1.01x
🐘 Postgres Next.js (Turbopack) 10.847s 11.021s 0.174s 3 1.02x
🐘 Postgres Express 10.914s (~) 11.024s (~) 0.110s 3 1.02x
💻 Local Express 10.922s (~) 11.023s (~) 0.101s 3 1.02x
💻 Local Nitro 10.943s (~) 11.023s (~) 0.080s 3 1.03x
🌐 MongoDB Next.js (Turbopack) 12.179s 13.017s 0.838s 3 1.14x

▲ Production (Vercel)

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Express 17.140s (-23.2% 🟢) 19.557s (-19.2% 🟢) 2.417s 2 1.00x
▲ Vercel Nitro 31.271s (+47.5% 🔺) 32.611s (+37.5% 🔺) 1.340s 2 1.82x
▲ Vercel Next.js (Turbopack) ⚠️ missing - - - -

🔍 Observability: Express | Nitro

workflow with 25 sequential steps

💻 Local Development

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
🐘 Postgres 🥇 Nitro 13.993s (-3.8%) 14.023s (-6.7% 🟢) 0.030s 5 1.00x
🌐 Redis Next.js (Turbopack) 14.248s 15.030s 0.782s 4 1.02x
🐘 Postgres Next.js (Turbopack) 14.486s 15.028s 0.541s 4 1.04x
💻 Local Next.js (Turbopack) 14.649s 15.030s 0.381s 4 1.05x
🐘 Postgres Express 14.671s (+1.1%) 15.024s (~) 0.354s 4 1.05x
💻 Local Express 14.934s (~) 15.029s (~) 0.095s 4 1.07x
💻 Local Nitro 15.013s (+0.6%) 15.281s (+1.7%) 0.268s 4 1.07x
🌐 MongoDB Next.js (Turbopack) 17.852s 18.030s 0.178s 4 1.28x

▲ Production (Vercel)

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Express 33.517s (-0.8%) 38.643s (+6.4% 🔺) 5.126s 2 1.00x
▲ Vercel Nitro 34.899s (-4.3%) 36.681s (-4.3%) 1.782s 2 1.04x
▲ Vercel Next.js (Turbopack) ⚠️ missing - - - -

🔍 Observability: Express | Nitro

workflow with 50 sequential steps

💻 Local Development

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
🐘 Postgres 🥇 Nitro 12.950s (-7.4% 🟢) 13.163s (-8.9% 🟢) 0.213s 7 1.00x
🌐 Redis Next.js (Turbopack) 13.476s 14.026s 0.549s 7 1.04x
🐘 Postgres Next.js (Turbopack) 14.051s 14.597s 0.546s 7 1.09x
🐘 Postgres Express 14.554s (+4.7%) 15.192s (+8.4% 🔺) 0.638s 6 1.12x
💻 Local Next.js (Turbopack) 16.003s 16.363s 0.360s 6 1.24x
💻 Local Express 16.544s (-0.5%) 17.031s (~) 0.486s 6 1.28x
💻 Local Nitro 16.821s (+2.6%) 17.031s (~) 0.210s 6 1.30x
🌐 MongoDB Next.js (Turbopack) 20.388s 21.030s 0.641s 5 1.57x

▲ Production (Vercel)

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Nitro 63.090s (~) 66.713s (+2.3%) 3.622s 2 1.00x
▲ Vercel Express 76.691s (+32.0% 🔺) 78.496s (+30.4% 🔺) 1.806s 2 1.22x
▲ Vercel Next.js (Turbopack) ⚠️ missing - - - -

🔍 Observability: Nitro | Express

Promise.all with 10 concurrent steps

💻 Local Development

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
🐘 Postgres 🥇 Nitro 1.202s (-5.6% 🟢) 2.010s (~) 0.808s 15 1.00x
🐘 Postgres Next.js (Turbopack) 1.236s 2.010s 0.774s 15 1.03x
🐘 Postgres Express 1.265s (-0.8%) 2.011s (~) 0.746s 15 1.05x
🌐 Redis Next.js (Turbopack) 1.356s 2.006s 0.651s 15 1.13x
💻 Local Next.js (Turbopack) 1.505s 2.006s 0.500s 15 1.25x
💻 Local Express 1.542s (-0.6%) 2.005s (~) 0.464s 15 1.28x
💻 Local Nitro 1.551s (+1.9%) 2.007s (~) 0.455s 15 1.29x
🌐 MongoDB Next.js (Turbopack) 2.160s 3.008s 0.848s 10 1.80x

▲ Production (Vercel)

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Nitro 2.989s (+7.9% 🔺) 4.754s (+4.5%) 1.766s 7 1.00x
▲ Vercel Express 3.518s (+46.8% 🔺) 6.239s (+50.4% 🔺) 2.721s 5 1.18x
▲ Vercel Next.js (Turbopack) ⚠️ missing - - - -

🔍 Observability: Nitro | Express

Promise.all with 25 concurrent steps

💻 Local Development

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
🐘 Postgres 🥇 Nitro 2.297s (-1.1%) 3.009s (~) 0.713s 10 1.00x
🐘 Postgres Express 2.345s (~) 3.012s (~) 0.666s 10 1.02x
🐘 Postgres Next.js (Turbopack) 2.389s 3.009s 0.620s 10 1.04x
🌐 Redis Next.js (Turbopack) 2.581s 3.008s 0.427s 10 1.12x
💻 Local Next.js (Turbopack) 2.910s 3.566s 0.656s 9 1.27x
💻 Local Express 3.011s (+3.0%) 3.565s (+6.7% 🔺) 0.554s 9 1.31x
💻 Local Nitro 3.164s (+8.6% 🔺) 3.885s (+21.1% 🔺) 0.721s 8 1.38x
🌐 MongoDB Next.js (Turbopack) 4.723s 5.178s 0.455s 6 2.06x

▲ Production (Vercel)

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Nitro 3.368s (+17.4% 🔺) 5.110s (+10.7% 🔺) 1.743s 6 1.00x
▲ Vercel Express 4.118s (+32.9% 🔺) 5.929s (+22.6% 🔺) 1.811s 6 1.22x
▲ Vercel Next.js (Turbopack) ⚠️ missing - - - -

🔍 Observability: Nitro | Express

Promise.all with 50 concurrent steps

💻 Local Development

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
🐘 Postgres 🥇 Nitro 3.372s (-3.1%) 4.012s (~) 0.640s 8 1.00x
🐘 Postgres Express 3.452s (-1.3%) 4.014s (~) 0.562s 8 1.02x
🐘 Postgres Next.js (Turbopack) 3.628s 4.011s 0.383s 8 1.08x
🌐 Redis Next.js (Turbopack) 4.156s 4.582s 0.426s 7 1.23x
💻 Local Next.js (Turbopack) 8.184s 8.521s 0.337s 4 2.43x
💻 Local Express 8.197s (+2.0%) 8.771s (~) 0.574s 4 2.43x
💻 Local Nitro 8.963s (+18.4% 🔺) 9.524s (+18.8% 🔺) 0.561s 4 2.66x
🌐 MongoDB Next.js (Turbopack) 10.002s 10.349s 0.347s 3 2.97x

▲ Production (Vercel)

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Express 3.766s (+10.2% 🔺) 6.530s (+26.9% 🔺) 2.765s 6 1.00x
▲ Vercel Nitro 4.297s (+45.2% 🔺) 5.960s (+27.8% 🔺) 1.663s 6 1.14x
▲ Vercel Next.js (Turbopack) ⚠️ missing - - - -

🔍 Observability: Express | Nitro

Promise.race with 10 concurrent steps

💻 Local Development

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
🐘 Postgres 🥇 Nitro 1.203s (-5.0% 🟢) 2.008s (~) 0.805s 15 1.00x
🐘 Postgres Next.js (Turbopack) 1.244s 2.010s 0.766s 15 1.03x
🐘 Postgres Express 1.255s (~) 2.010s (~) 0.756s 15 1.04x
🌐 Redis Next.js (Turbopack) 1.328s 2.006s 0.678s 15 1.10x
💻 Local Next.js (Turbopack) 1.531s 2.006s 0.474s 15 1.27x
💻 Local Express 1.541s (+1.1%) 2.006s (~) 0.465s 15 1.28x
💻 Local Nitro 1.551s (+1.6%) 2.006s (~) 0.455s 15 1.29x
🌐 MongoDB Next.js (Turbopack) 2.190s 3.008s 0.817s 10 1.82x

▲ Production (Vercel)

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Express 2.762s (+6.0% 🔺) 4.486s (+1.0%) 1.724s 7 1.00x
▲ Vercel Nitro 2.764s (+24.1% 🔺) 5.065s (+21.1% 🔺) 2.300s 7 1.00x
▲ Vercel Next.js (Turbopack) ⚠️ missing - - - -

🔍 Observability: Express | Nitro

Promise.race with 25 concurrent steps

💻 Local Development

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
🐘 Postgres 🥇 Nitro 2.268s (-4.0%) 3.011s (~) 0.743s 10 1.00x
🐘 Postgres Express 2.338s (-1.0%) 3.011s (~) 0.673s 10 1.03x
🐘 Postgres Next.js (Turbopack) 2.385s 3.010s 0.625s 10 1.05x
🌐 Redis Next.js (Turbopack) 2.566s 3.008s 0.442s 10 1.13x
💻 Local Nitro 3.020s (+7.3% 🔺) 3.884s (+21.1% 🔺) 0.864s 8 1.33x
💻 Local Express 3.051s (~) 3.677s (-5.4% 🟢) 0.626s 9 1.35x
💻 Local Next.js (Turbopack) 3.221s 3.759s 0.538s 8 1.42x
🌐 MongoDB Next.js (Turbopack) 4.649s 5.179s 0.530s 6 2.05x

▲ Production (Vercel)

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Nitro 3.564s (-13.3% 🟢) 4.878s (-15.8% 🟢) 1.313s 7 1.00x
▲ Vercel Express 3.621s (-46.1% 🟢) 6.397s (-24.8% 🟢) 2.776s 5 1.02x
▲ Vercel Next.js (Turbopack) ⚠️ missing - - - -

🔍 Observability: Nitro | Express

Promise.race with 50 concurrent steps

💻 Local Development

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
🐘 Postgres 🥇 Nitro 3.409s (-1.1%) 4.010s (~) 0.601s 8 1.00x
🐘 Postgres Express 3.501s (+1.3%) 4.013s (~) 0.513s 8 1.03x
🐘 Postgres Next.js (Turbopack) 3.616s 4.011s 0.394s 8 1.06x
🌐 Redis Next.js (Turbopack) 4.138s 4.725s 0.587s 7 1.21x
💻 Local Next.js (Turbopack) 8.860s 9.269s 0.409s 4 2.60x
💻 Local Express 8.871s (+2.4%) 9.274s (+2.8%) 0.403s 4 2.60x
💻 Local Nitro 8.996s (+14.2% 🔺) 9.525s (+11.8% 🔺) 0.528s 4 2.64x
🌐 MongoDB Next.js (Turbopack) 9.869s 10.351s 0.481s 3 2.90x

▲ Production (Vercel)

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Express 3.334s (-33.6% 🟢) 5.922s (-11.2% 🟢) 2.588s 6 1.00x
▲ Vercel Nitro 3.602s (+25.6% 🔺) 4.980s (+13.9% 🔺) 1.378s 7 1.08x
▲ Vercel Next.js (Turbopack) ⚠️ missing - - - -

🔍 Observability: Express | Nitro

workflow with 10 sequential data payload steps (10KB)

💻 Local Development

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
🐘 Postgres 🥇 Nitro 0.601s (-26.1% 🟢) 1.007s (~) 0.406s 60 1.00x
🐘 Postgres Next.js (Turbopack) 0.747s 1.007s 0.260s 60 1.24x
🌐 Redis Next.js (Turbopack) 0.799s 1.095s 0.296s 55 1.33x
🐘 Postgres Express 0.847s (+2.6%) 1.007s (~) 0.160s 60 1.41x
💻 Local Next.js (Turbopack) 0.862s 1.022s 0.159s 59 1.44x
💻 Local Express 0.981s (~) 1.076s (-3.6%) 0.095s 56 1.63x
💻 Local Nitro 1.024s (+0.9%) 1.720s (~) 0.696s 35 1.70x
🌐 MongoDB Next.js (Turbopack) 2.151s 3.008s 0.857s 20 3.58x

▲ Production (Vercel)

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Nitro 10.142s (-14.7% 🟢) 11.885s (-14.7% 🟢) 1.743s 6 1.00x
▲ Vercel Express 10.147s (-7.8% 🟢) 11.912s (-8.9% 🟢) 1.764s 6 1.00x
▲ Vercel Next.js (Turbopack) ⚠️ missing - - - -

🔍 Observability: Nitro | Express

workflow with 25 sequential data payload steps (10KB)

💻 Local Development

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
🐘 Postgres 🥇 Nitro 1.450s (-23.8% 🟢) 2.008s (-1.1%) 0.558s 45 1.00x
🌐 Redis Next.js (Turbopack) 1.638s 2.006s 0.368s 45 1.13x
🐘 Postgres Next.js (Turbopack) 1.893s 2.102s 0.209s 43 1.31x
🐘 Postgres Express 1.991s (~) 2.442s (+5.4% 🔺) 0.451s 37 1.37x
💻 Local Next.js (Turbopack) 2.675s 3.008s 0.333s 30 1.84x
💻 Local Express 3.019s (~) 3.609s (-5.1% 🟢) 0.590s 25 2.08x
💻 Local Nitro 3.057s (~) 3.967s (+6.4% 🔺) 0.910s 23 2.11x
🌐 MongoDB Next.js (Turbopack) 5.215s 6.011s 0.796s 15 3.60x

▲ Production (Vercel)

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Express 31.588s (-6.6% 🟢) 33.229s (-7.2% 🟢) 1.641s 3 1.00x
▲ Vercel Nitro 32.111s (-2.2%) 35.414s (+1.0%) 3.302s 3 1.02x
▲ Vercel Next.js (Turbopack) ⚠️ missing - - - -

🔍 Observability: Express | Nitro

workflow with 50 sequential data payload steps (10KB)

💻 Local Development

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
🐘 Postgres 🥇 Nitro 2.959s (-23.0% 🟢) 3.253s (-20.2% 🟢) 0.293s 37 1.00x
🌐 Redis Next.js (Turbopack) 3.277s 4.009s 0.732s 30 1.11x
🐘 Postgres Next.js (Turbopack) 3.731s 4.011s 0.280s 30 1.26x
🐘 Postgres Express 4.148s (+2.2%) 4.892s (+7.1% 🔺) 0.744s 25 1.40x
💻 Local Next.js (Turbopack) 8.708s 9.018s 0.309s 14 2.94x
💻 Local Express 9.243s (+1.2%) 9.941s (+1.6%) 0.698s 13 3.12x
💻 Local Nitro 9.266s (+3.9%) 10.020s (+7.4% 🔺) 0.753s 12 3.13x
🌐 MongoDB Next.js (Turbopack) 10.531s 11.019s 0.488s 11 3.56x

▲ Production (Vercel)

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Nitro 86.353s (-2.6%) 88.202s (-3.6%) 1.848s 2 1.00x
▲ Vercel Express 93.877s (+3.8%) 95.692s (+3.1%) 1.815s 2 1.09x
▲ Vercel Next.js (Turbopack) ⚠️ missing - - - -

🔍 Observability: Nitro | Express

workflow with 10 concurrent data payload steps (10KB)

💻 Local Development

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
🐘 Postgres 🥇 Nitro 0.223s (-22.8% 🟢) 1.008s (~) 0.785s 60 1.00x
🐘 Postgres Next.js (Turbopack) 0.257s 1.008s 0.751s 60 1.16x
🐘 Postgres Express 0.294s (+4.4%) 1.008s (~) 0.714s 60 1.32x
🌐 Redis Next.js (Turbopack) 0.402s 1.004s 0.602s 60 1.81x
💻 Local Nitro 0.590s (+4.4%) 1.005s (~) 0.415s 60 2.65x
💻 Local Next.js (Turbopack) 0.602s 1.005s 0.403s 60 2.70x
💻 Local Express 0.603s (+2.7%) 1.005s (~) 0.401s 60 2.71x
🌐 MongoDB Next.js (Turbopack) 1.668s 2.109s 0.441s 29 7.49x

▲ Production (Vercel)

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Express 1.710s (-14.3% 🟢) 3.823s (~) 2.113s 16 1.00x
▲ Vercel Nitro 2.095s (+18.2% 🔺) 4.155s (+9.3% 🔺) 2.060s 15 1.22x
▲ Vercel Next.js (Turbopack) ⚠️ missing - - - -

🔍 Observability: Express | Nitro

workflow with 25 concurrent data payload steps (10KB)

💻 Local Development

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
🐘 Postgres 🥇 Nitro 0.368s (-27.6% 🟢) 1.007s (~) 0.638s 90 1.00x
🐘 Postgres Next.js (Turbopack) 0.465s 1.007s 0.543s 90 1.26x
🐘 Postgres Express 0.509s (+1.4%) 1.009s (~) 0.500s 90 1.38x
🌐 Redis Next.js (Turbopack) 1.140s 2.006s 0.866s 45 3.09x
💻 Local Nitro 2.502s (+7.9% 🔺) 3.010s (~) 0.508s 30 6.79x
💻 Local Express 2.582s (+0.7%) 3.010s (~) 0.427s 30 7.01x
💻 Local Next.js (Turbopack) 2.622s 3.009s 0.386s 30 7.12x
🌐 MongoDB Next.js (Turbopack) 4.662s 5.230s 0.568s 18 12.66x

▲ Production (Vercel)

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Nitro 3.144s (+4.6%) 4.645s (-4.5%) 1.501s 20 1.00x
▲ Vercel Express 3.301s (+14.4% 🔺) 5.161s (+12.0% 🔺) 1.860s 18 1.05x
▲ Vercel Next.js (Turbopack) ⚠️ missing - - - -

🔍 Observability: Nitro | Express

workflow with 50 concurrent data payload steps (10KB)

💻 Local Development

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
🐘 Postgres 🥇 Nitro 0.586s (-24.3% 🟢) 1.007s (~) 0.421s 120 1.00x
🐘 Postgres Next.js (Turbopack) 0.744s 1.008s 0.264s 120 1.27x
🐘 Postgres Express 0.799s (+0.8%) 1.010s (~) 0.210s 119 1.36x
🌐 Redis Next.js (Turbopack) 2.658s 3.007s 0.349s 40 4.53x
🌐 MongoDB Next.js (Turbopack) 9.946s 10.432s 0.486s 12 16.96x
💻 Local Next.js (Turbopack) 10.662s 11.210s 0.548s 11 18.18x
💻 Local Express 11.278s (+0.6%) 11.937s (~) 0.659s 11 19.23x
💻 Local Nitro 11.299s (+9.1% 🔺) 12.030s (+10.8% 🔺) 0.731s 10 19.27x

▲ Production (Vercel)

World Framework Workflow Time Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Express 6.990s (-18.7% 🟢) 8.772s (-18.2% 🟢) 1.782s 14 1.00x
▲ Vercel Nitro 8.025s (-7.1% 🟢) 9.805s (-7.3% 🟢) 1.780s 13 1.15x
▲ Vercel Next.js (Turbopack) ⚠️ missing - - - -

🔍 Observability: Express | Nitro

Stream Benchmarks (includes TTFB metrics)
workflow with stream

💻 Local Development

World Framework Workflow Time TTFB Slurp Wall Time Overhead Samples vs Fastest
🐘 Postgres 🥇 Nitro 0.159s (-22.9% 🟢) 0.999s (~) 0.001s (~) 1.010s (~) 0.851s 10 1.00x
💻 Local Next.js (Turbopack) 0.172s 1.002s 0.012s 1.018s 0.846s 10 1.08x
🌐 Redis Next.js (Turbopack) 0.178s 1.000s 0.002s 1.008s 0.830s 10 1.12x
🐘 Postgres Next.js (Turbopack) 0.187s 1.000s 0.001s 1.011s 0.824s 10 1.17x
💻 Local Express 0.202s (-1.8%) 1.003s (~) 0.011s (~) 1.017s (~) 0.815s 10 1.27x
💻 Local Nitro 0.211s (+1.5%) 1.003s (~) 0.013s (+35.7% 🔺) 1.020s (~) 0.809s 10 1.33x
🐘 Postgres Express 0.234s (+15.1% 🔺) 0.997s (~) 0.001s (-16.7% 🟢) 1.012s (~) 0.778s 10 1.47x
🌐 MongoDB Next.js (Turbopack) 0.504s 0.950s 0.002s 1.009s 0.505s 10 3.17x

▲ Production (Vercel)

World Framework Workflow Time TTFB Slurp Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Express 1.859s (+5.5% 🔺) 2.822s (-4.8%) 0.544s (+60.0% 🔺) 4.349s (+7.0% 🔺) 2.490s 10 1.00x
▲ Vercel Nitro 1.928s (+17.0% 🔺) 3.252s (+19.1% 🔺) 0.479s (-16.1% 🟢) 4.265s (+6.0% 🔺) 2.337s 10 1.04x
▲ Vercel Next.js (Turbopack) ⚠️ missing - - - - -

🔍 Observability: Express | Nitro

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.480s 1.000s 0.004s 1.012s 0.531s 60 1.00x
🐘 Postgres Nitro 0.495s (-17.9% 🟢) 1.009s (+0.8%) 0.004s (-19.5% 🟢) 1.025s (~) 0.530s 59 1.03x
🐘 Postgres Next.js (Turbopack) 0.596s 1.007s 0.004s 1.023s 0.426s 59 1.24x
🐘 Postgres Express 0.629s (+2.1%) 1.001s (~) 0.004s (-11.8% 🟢) 1.026s (~) 0.397s 59 1.31x
💻 Local Next.js (Turbopack) 0.662s 1.009s 0.009s 1.024s 0.362s 59 1.38x
💻 Local Express 0.732s (+1.3%) 1.009s (~) 0.008s (-7.8% 🟢) 1.021s (~) 0.290s 59 1.52x
💻 Local Nitro 0.733s (-2.8%) 1.010s (~) 0.009s (-7.6% 🟢) 1.024s (~) 0.291s 59 1.53x
🌐 MongoDB Next.js (Turbopack) 1.324s 1.949s 0.003s 2.012s 0.688s 30 2.75x

▲ Production (Vercel)

World Framework Workflow Time TTFB Slurp Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Express 4.164s (-1.3%) 5.608s (~) 0.412s (+14.7% 🔺) 6.746s (~) 2.581s 9 1.00x
▲ Vercel Nitro 4.329s (~) 5.548s (-6.1% 🟢) 0.295s (-49.0% 🟢) 6.423s (-12.3% 🟢) 2.094s 10 1.04x
▲ Vercel Next.js (Turbopack) ⚠️ missing - - - - -

🔍 Observability: Express | Nitro

10 parallel streams (1MB each)

💻 Local Development

World Framework Workflow Time TTFB Slurp Wall Time Overhead Samples vs Fastest
🌐 Redis 🥇 Next.js (Turbopack) 0.880s 1.000s 0.000s 1.004s 0.125s 60 1.00x
🐘 Postgres Nitro 0.900s (-6.9% 🟢) 1.069s (-8.1% 🟢) 0.000s (+85.7% 🔺) 1.079s (-10.1% 🟢) 0.179s 56 1.02x
🐘 Postgres Next.js (Turbopack) 0.934s 1.110s 0.000s 1.120s 0.185s 54 1.06x
🐘 Postgres Express 0.943s (-4.2%) 1.169s (-5.9% 🟢) 0.000s (-100.0% 🟢) 1.189s (-5.6% 🟢) 0.246s 51 1.07x
💻 Local Express 1.245s (-1.1%) 2.019s (~) 0.000s (-33.3% 🟢) 2.023s (~) 0.778s 30 1.42x
💻 Local Nitro 1.256s (+2.7%) 2.021s (~) 0.000s (-36.4% 🟢) 2.024s (~) 0.769s 30 1.43x
💻 Local Next.js (Turbopack) 1.261s 2.020s 0.000s 2.024s 0.763s 30 1.43x
🌐 MongoDB Next.js (Turbopack) 2.344s 2.949s 0.000s 3.007s 0.664s 20 2.66x

▲ Production (Vercel)

World Framework Workflow Time TTFB Slurp Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Nitro 2.881s (+0.9%) 3.906s (+1.5%) 0.000s (+Infinity% 🔺) 5.164s (+11.9% 🔺) 2.283s 12 1.00x
▲ Vercel Express 3.195s (-5.0%) 4.499s (+1.4%) 0.000s (+100.0% 🔺) 5.219s (~) 2.024s 12 1.11x
▲ Vercel Next.js (Turbopack) ⚠️ missing - - - - -

🔍 Observability: Nitro | Express

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.545s 2.002s 0.000s 2.006s 0.461s 30 1.00x
🐘 Postgres Nitro 1.715s (-2.0%) 2.142s (+2.1%) 0.000s (+3.6%) 2.152s (+1.9%) 0.438s 28 1.11x
🐘 Postgres Express 1.785s (-1.3%) 2.100s (-1.6%) 0.000s (~) 2.114s (-2.7%) 0.329s 29 1.16x
🐘 Postgres Next.js (Turbopack) 1.827s 2.181s 0.000s 2.191s 0.364s 28 1.18x
💻 Local Express 3.519s (-3.5%) 4.034s (-3.2%) 0.001s (+55.6% 🔺) 4.038s (-3.2%) 0.519s 15 2.28x
💻 Local Next.js (Turbopack) 3.716s 4.231s 0.000s 4.237s 0.521s 15 2.40x
💻 Local Nitro 3.729s (+9.7% 🔺) 4.167s (+4.9%) 0.001s (+30.4% 🔺) 4.172s (+4.9%) 0.443s 15 2.41x
🌐 MongoDB Next.js (Turbopack) 4.378s 4.955s 0.000s 5.010s 0.632s 12 2.83x

▲ Production (Vercel)

World Framework Workflow Time TTFB Slurp Wall Time Overhead Samples vs Fastest
▲ Vercel 🥇 Nitro 4.006s (-1.9%) 5.471s (+1.2%) 0.000s (-50.0% 🟢) 6.435s (+3.0%) 2.429s 10 1.00x
▲ Vercel Express 4.114s (-14.1% 🟢) 5.146s (-13.7% 🟢) 0.000s (+Infinity% 🔺) 6.457s (-4.1%) 2.343s 10 1.03x
▲ Vercel Next.js (Turbopack) ⚠️ missing - - - - -

🔍 Observability: Nitro | Express

Summary

Fastest Framework by World

Winner determined by most benchmark wins

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

Winner determined by most benchmark wins

Framework 🥇 Fastest World Wins
Express 🐘 Postgres 17/21
Next.js (Turbopack) 🐘 Postgres 10/21
Nitro 🐘 Postgres 20/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: success
  • Postgres: success
  • Vercel: failure

Check the workflow run for details.

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-node-module-error esbuild plugin’s identifier usage detection so that references inside multi-line block comments (including JSDoc) are ignored, improving the accuracy of reported violation locations.

Changes:

  • Reworked findIdentifierUsage to track and skip multi-line block comments across lines while preserving column alignment via space replacement.
  • Added tests covering JSDoc multi-line comments and single-line /* ... */ comments.
  • Added a changeset to publish the fix as a patch for @workflow/builders.

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 1 comment.

File Description
packages/builders/src/node-module-esbuild-plugin.ts Implements stateful block-comment skipping in findIdentifierUsage and preserves original lineText in returned locations.
packages/builders/src/node-module-esbuild-plugin.test.ts Adds regression tests ensuring violations point to real code usage instead of block/JSDoc comments.
.changeset/fix-multiline-comment-skip.md Declares a patch release note for the plugin location fix.

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

Comment on lines +167 to +205
// Handle multi-line block comments (including JSDoc)
if (inBlockComment) {
const endIdx = line.indexOf('*/');
if (endIdx === -1) {
// Entire line is inside a block comment
continue;
}
// Replace everything up to and including */ with spaces
line = ' '.repeat(endIdx + 2) + line.slice(endIdx + 2);
inBlockComment = false;
}

// Skip comments (both // and /* */ style)
const withoutComments = line
.replace(/\/\*[\s\S]*?\*\//g, '')
.replace(/\/\/.*$/, '');
// Remove single-line block comments and detect block comment starts
let processed = '';
let j = 0;
while (j < line.length) {
if (line[j] === '/' && line[j + 1] === '/') {
// Rest of line is a comment
processed += ' '.repeat(line.length - j);
break;
}
if (line[j] === '/' && line[j + 1] === '*') {
const endIdx = line.indexOf('*/', j + 2);
if (endIdx !== -1) {
// Inline block comment - replace with spaces
const len = endIdx + 2 - j;
processed += ' '.repeat(len);
j = endIdx + 2;
} else {
// Block comment starts here, continues on next lines
processed += ' '.repeat(line.length - j);
inBlockComment = true;
break;
}
} else {
processed += line[j];
j += 1;
}
}
Copy link

Copilot AI Mar 30, 2026

Choose a reason for hiding this comment

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

findIdentifierUsage's comment scanning runs before string-literal stripping and doesn't track string state. If a line contains /* inside a string literal without a matching */ (e.g. const s = "/*";), the loop will incorrectly enter inBlockComment and then skip all subsequent lines until a */ is found (potentially never), causing real identifier usages later in the file to be missed and the violation to go unreported. Consider stripping/replacing strings with spaces before detecting ////* tokens, or extending the scanner to ignore comment delimiters while inside '"/` strings; adding a regression test for this case would help.

Copilot uses AI. Check for mistakes.
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.

This seems real

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

Fixed — moved string literal stripping before the comment scanner so /* inside strings no longer triggers block comment mode. Added a regression test for const pattern = "/* Writable */";.

Move string stripping before comment detection so that comment delimiters
inside string literals (e.g. `const s = "/*"`) don't incorrectly trigger
block comment mode. Adds regression test.

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.

4 participants