shihabmridha / educative.io-downloader

Free Palestine. 📖 This tool is to download course from educative.io for offline usage. It uses your login credentials and download the course.
218 stars 130 forks source link

SyntaxError: Unexpected token #82

Closed mod-ali closed 10 months ago

mod-ali commented 10 months ago

Hi,

When I run 'pnpm start' I get the following error

C:\educative.io-downloader-master\node_modules\.pnpm\puppeteer-core@21.5.2\node_modules\puppeteer-core\lib\cjs\puppeteer\api\ElementHandle.js:176
        static {
               ^

SyntaxError: Unexpected token '{'
    at Object.compileFunction (node:vm:352:18)
    at wrapSafe (node:internal/modules/cjs/loader:1031:15)
    at Module._compile (node:internal/modules/cjs/loader:1065:27)
    at Object.Module._extensions..js (node:internal/modules/cjs/loader:1153:10)
    at Module.load (node:internal/modules/cjs/loader:981:32)
    at Function.Module._load (node:internal/modules/cjs/loader:822:12)
    at Module.require (node:internal/modules/cjs/loader:1005:19)
    at require (node:internal/modules/cjs/helpers:102:18)
    at Object.<anonymous> (C:\Users\Max\Documents\Benutzerdefinierte Office-Vorlagen\educative.io-downloader-master\node_modules\.pnpm\puppeteer-core@21.5.2\node_modules\puppeteer-core\lib\cjs\puppeteer\api\api.js:35:14)
    at Module._compile (node:internal/modules/cjs/loader:1101:14)
 ELIFECYCLE  Command failed with exit code 1.
shihabmridha commented 10 months ago

Did you compile the project?

mod-ali commented 10 months ago

Did you compile the project?

Yes, I installed the packages, compiled then started.

shihabmridha commented 10 months ago

As you can see in the screenshot, I could not reproduce the error. I would suggest you delete the node_modules and build folders. Then run the following commands.

pnpm install
pnpm compile
pnpm start

Make sure to update the config\default.json file.

image

mod-ali commented 10 months ago

Thanks, solved after upgrading node and npm to the latest versions