juliancwirko / nft-art-maker

NFT Art Maker - generates images and metadata files, packs them into IPFS CAR files, and uploads them using nft.storage. All from provided PNG layers.
MIT License
98 stars 36 forks source link

Syntax Error #27

Closed caderyn19 closed 1 year ago

caderyn19 commented 2 years ago

I'm following the tutorial video you posted on YT, and I'm getting a syntax error. I'm not quite sure what I'm doing wrong:

file:///usr/local/lib/node_modules/nft-art-maker/node_modules/@web-std/fetch/src/index.js:110
            response_?.emit("error", err);
                      ^

SyntaxError: Unexpected token '.'
    at Loader.moduleStrategy (internal/modules/esm/translators.js:140:18)

If I try the minimum recommended node, 14.14.0, or higher it gives me:

Error: The module '/usr/local/lib/node_modules/nft-art-maker/node_modules/canvas/build/Release/canvas.node'
was compiled against a different Node.js version using
NODE_MODULE_VERSION 72. This version of Node.js requires
NODE_MODULE_VERSION 93. Please try re-compiling or re-installing
the module (for instance, using `npm rebuild` or `npm install`).

If I downgrade to version 72, it throws the SyntaxError... I'm running Ubuntu 22.04.1 LTS.

juliancwirko commented 2 years ago

You may need to reinstall it:

npm remove nft-art-maker -g
npm install nft-art-maker -g

Make sure that you use proper version of Node: node -v to check

on which version of Node would you like to run it?

caderyn19 commented 2 years ago

Ahhh that helped! Now I got to configuring layers, so I'm back on track. Thank you!

I uninstalled npm, did a clean install to make sure it was fresh, used nvm to install 14.14.0 (was on 12.22.12 apparently, but that was the "NODE_MODULE_VERSION 72" it was throwing at me), then did the removal and install of nft-art-maker and it brought me to the next step.

Thank you for that simple solution! I thought I did that, but I did rebuild instead of remove and install. :facepalm:

On Thu, Sep 29, 2022 at 11:42 AM Julian Ćwirko @.***> wrote:

You may need to reinstall it:

npm remove nft-art-maker -g

npm install nft-art-maker -g

Make sure that you use proper version of Node: node -v to check

on which version of Node would you like to run it?

— Reply to this email directly, view it on GitHub https://github.com/juliancwirko/nft-art-maker/issues/27#issuecomment-1262464957, or unsubscribe https://github.com/notifications/unsubscribe-auth/A3K6DQYJPULGCOBM3XGHBN3WAW2FPANCNFSM6AAAAAAQY4PI2Q . You are receiving this because you authored the thread.Message ID: @.***>

juliancwirko commented 2 years ago

Great, I'm glad that it worked :+1: