Skip to content

TypeError: Failed to parse URL @wasm-codecs/mozjpeg/lib/mozjpeg.wasm #70

Open
@fmal

Description

@fmal

Hi @cyrilwanner,

was using your codecs through optimized-images-loader and they worked like a charm, but i'm not able to build my project anymore with Node v18.12 due to the following error:

RuntimeError: abort(TypeError: Failed to parse URL from /project/.yarn/cache/@wasm-codecs-mozjpeg-npm-1.0.1-a340d1b48f-d73b371858.zip/node_modules/@wasm-codecs/mozjpeg/lib/mozjpeg.wasm). Build with -s ASSERTIONS=1 for more info.
    at process.abort (/Users/fima/Code/wave/.yarn/cache/@wasm-codecs-mozjpeg-npm-1.0.1-a340d1b48f-d73b371858.zip/node_modules/@wasm-codecs/mozjpeg/lib/mozjpeg.js:9:11556)
    at process.emit (node:events:525:35)
    at process.emit (/Users/fima/Code/wave/.pnp.cjs:36638:25)
    at process.processEmit [as emit] (/Users/fima/Code/wave/.yarn/__virtual__/next-virtual-c4b8a7b060/0/cache/next-npm-13.0.6-d05b793bd2-2de1d9975f.zip/node_modules/next/dist/compiled/ora/index.js:1:13595)
    at emit (node:internal/process/promises:149:20)
    at processPromiseRejections (node:internal/process/promises:283:27)
    at process.processTicksAndRejections (node:internal/process/task_queues:96:32)

Node.js v18.12.1

Seems like this is an issue of emscripten that was fixed in emscripten-core/emscripten#16917.

This issue was reported in other repo too: cyrilwanner/react-optimized-image#31

Is there any chance you could make this codecs compatible with Node 18?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions