Closed aminecmi closed 2 years ago
On the latest version of npm, the build fails a little later.
🚨 Build failed.
@parcel/optimizer-terser: You must provide the URL of lib/mappings.wasm by calling SourceMapConsumer.initialize({ 'lib/mappings.wasm': ... }) before using SourceMapConsumer
Error: You must provide the URL of lib/mappings.wasm by calling SourceMapConsumer.initialize({ 'lib/mappings.wasm': ... }) before using SourceMapConsumer
at readWasm (/var/www/amine/selfoss/assets/node_modules/terser/node_modules/source-map/lib/read-wasm.js:8:13)
at wasm (/var/www/amine/selfoss/assets/node_modules/terser/node_modules/source-map/lib/wasm.js:25:16)
at /var/www/amine/selfoss/assets/node_modules/terser/node_modules/source-map/lib/source-map-consumer.js:264:14
at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
at async SourceMap (/var/www/amine/selfoss/assets/node_modules/terser/dist/bundle.min.js:19362:20)
at async minify (/var/www/amine/selfoss/assets/node_modules/terser/dist/bundle.min.js:27714:41)
at async Object.optimize (/var/www/amine/selfoss/assets/node_modules/@parcel/optimizer-terser/lib/TerserOptimizer.js:131:16)
at async PackagerRunner.optimize (/var/www/amine/selfoss/assets/node_modules/@parcel/core/lib/PackagerRunner.js:364:20)
at async PackagerRunner.getBundleResult (/var/www/amine/selfoss/assets/node_modules/@parcel/core/lib/PackagerRunner.js:255:15)
at async PackagerRunner.getBundleInfo (/var/www/amine/selfoss/assets/node_modules/@parcel/core/lib/PackagerRunner.js:239:9)
I have seen some serialization issues when there was assets/.parcel-cache
from a different Node version (probably a bug in Parcel). Try deleting the directory.
The latter is caused by source-map package not being compatible with latest Node.js, it is possible to work around it with https://github.com/parcel-bundler/parcel/issues/8005#issuecomment-1120149358.
Thanks for this.
Everything works now !
https://github.com/fossar/selfoss/commit/143eef57f0723eab11f68ba27dff920695428acf bumps the terser that bumps the source-map so hopefully that fixes the second issue.
Hello,
I'm trying to install selfoss from scratch. I'm up-to-date with the master branch, and I keep having an issue with parcel.
Here is the error message I keep having.
I tried downgrading my npm version from 18 to 16, and then 14, but that didn't work.
Any idea on how to solve this ?