modernweb-dev / web

Guides, tools and libraries for modern web development.
https://modern-web.dev
MIT License
2.16k stars 271 forks source link

Error while reading source maps #2673

Open justinfagnani opened 4 months ago

justinfagnani commented 4 months ago

I'm getting this error in one project with @web/test-runner-core@0.13.1 (depending on source-map@0.7.3).

~I'm not getting it in another project with the same versions.~ (edit: I am) Opening this issue in case someone here has seen it. I'll try to reduce and close this if it's not related to WTR.

Error while reading source maps for /Users/justin/Projects/Web/stampino-element/node_modules/@lit/reactive-element/development/reactive-element.js
Error: You must provide the URL of lib/mappings.wasm by calling SourceMapConsumer.initialize({ 'lib/mappings.wasm': ... }) before using SourceMapConsumer
    at readWasm (/Users/justin/Projects/Web/stampino-element/node_modules/source-map/lib/read-wasm.js:8:13)
    at wasm (/Users/justin/Projects/Web/stampino-element/node_modules/source-map/lib/wasm.js:25:16)
    at /Users/justin/Projects/Web/stampino-element/node_modules/source-map/lib/source-map-consumer.js:264:14
    at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
    at async /Users/justin/Projects/Web/stampino-element/node_modules/@web/test-runner-core/dist/server/plugins/api/createSourceMapFunction.js:61:30
    at async mapStackLocation (/Users/justin/Projects/Web/stampino-element/node_modules/@web/test-runner-core/dist/server/plugins/api/parseBrowserResult.js:8:27)
    at async formatLocation (/Users/justin/Projects/Web/stampino-element/node_modules/@web/browser-logs/dist/parseStackTrace.js:69:26)
    at async parseStackTrace (/Users/justin/Projects/Web/stampino-element/node_modules/@web/browser-logs/dist/parseStackTrace.js:111:23)
    at async replaceErrorStack (/Users/justin/Projects/Web/stampino-element/node_modules/@web/test-runner-core/dist/server/plugins/api/parseBrowserErrors.js:8:23)
    at async /Users/justin/Projects/Web/stampino-element/node_modules/@web/test-runner-core/dist/server/plugins/api/parseBrowserErrors.js:39:17