evanw / evanw/node-source-map-support
RangeError Maximum call stack size exceeded when testing Vue project
- Dominant language
- JavaScript
- Stars
- 2.2k
- Forks
- 223
- PR merge metrics
- No merged PRs in 30d
Description
Hi, this is somewhat of a duplicate of these issues: #252, #249, and #86. But I wanted to call more attention to it.
I am getting this error when attempting to test our Vue project using vue-cli-service :
```
RangeError: Maximum call stack size exceeded
at RegExp.exec ()
at retrieveSourceMapURL (D:\a\_work\1\s\common\temp\node_modules\.pnpm\source-map-support@0.5.21\node_modules\source-map-support\source-map-support.js:174:21)
at Array. (D:\a\_work\1\s\common\temp\node_modules\.pnpm\source-map-support@0.5.21\node_modules\source-map-support\source-map-support.js:186:26)
at D:\a\_work\1\s\common\temp\node_modules\.pnpm\source-map-support@0.5.21\node_modules\source-map-support\source-map-support.js:85:24
at mapSourcePosition (D:\a\_work\1\s\common\temp\node_modules\.pnpm\source-map-support@0.5.21\node_modules\source-map-support\source-map-support.js:216:21)
at wrapCallSite (D:\a\_work\1\s\common\temp\node_modules\.pnpm\source-map-support@0.5.21\node_modules\source-map-support\source-map-support.js:397:20)
at Function.prepareStackTrace (D:\a\_work\1\s\common\temp\node_modules\.pnpm\source-map-support@0.5.21\node_modules\source-map-support\source-map-support.js:446:39)
at maybeOverridePrepareStackTrace (node:internal/errors:141:29)
at prepareStackTrace (node:internal/errors:115:5)
at TestRunner.Reporter.onLoadingException (D:\a\_work\1\s\common\temp\node_modules\.pnpm\mochapack@2.1.4_mocha@8.4.0+webpack@5.72.0\node_modules\mochapack\src\runner\testRunnerReporter.ts:104:13)
```
The version of our source-map-support is `0.5.21`.
I believe the issue is coming from having large source maps that are being pulled in during the test, and the regex trying to scan through it. Is there a way to fix this to help further avoid this error?
Let me know if there's anything I can help out with in terms of solving this, or if there's anything more I should understand about the current state of the code and why this issue is happening.
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.