Repository navigation
fix(code-node): handle regex literals in JavaScript defaults - #44409
Open
mikamikasuki wants to merge 10 commits into
Open
mikamikasuki wants to merge 10 commits into
mikamikasuki wants to merge 10 commits into
Conversation
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #44409 +/- ##
=======================================
Coverage 88.80% 88.80%
=======================================
Files 5558 5558
Lines 332910 333008 +98
Branches 66663 66721 +58
=======================================
+ Hits 295635 295723 +88
- Misses 32093 32103 +10
Partials 5182 5182
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
mikamikasuki
force-pushed
the
fix/js-code-node-regex-default-44407
branch
from
October 20, 2026 08:11
0286908 to
27452a8
Compare
mikamikasuki
force-pushed
the
fix/js-code-node-regex-default-44407
branch
from
October 20, 2026 08:16
27452a8 to
c8002c1
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
The JavaScript Code node parameter scanner counts delimiters inside regex literals as signature structure. A valid default such as
/[(]/can therefore make extraction return no parameters; applying generated code then drops the node inputs. This change skips regex literal contents while scanning the main signature and top-level parameters, while preserving ordinary division. Regression cases cover regexes after operators, arrow defaults, control-flow bodies, and standalone blocks.Fixes #44407
Validation
../node_modules/.bin/vp test --project unit app/components/workflow/nodes/code/__tests__/code-parser.spec.ts— 67 passed.../node_modules/.bin/vp test --project unit --coverage --coverage.include=app/components/workflow/nodes/code/code-parser.ts --coverage.reporter=text app/components/workflow/nodes/code/__tests__/code-parser.spec.ts— 67 passed; 98.42% line coverage and 93.75% branch coverage forcode-parser.ts.../node_modules/.bin/vp check app/components/workflow/nodes/code/code-parser.ts app/components/workflow/nodes/code/__tests__/code-parser.spec.ts— formatting, lint, and type checks passed.git diff --check— passed.aa35579b66615a9620c6dfb0410b1d6cd99a4fea, regression cases for regexes afterelse,catch,finally, andswitchblocks fail; they pass on this branch.3e2e886: 35 successful, 9 skipped. Codecov reports 99.10% patch coverage with one changed line uncovered; its report is one commit behind the current head.Review gate
At least one approving review from a reviewer with write access is required; both requested code-owner reviews are pending.
Checklist
From Codex