TheNetsky / Microsoft-Rewards-Script

Automated Microsoft Rewards script, using TypeScript, Cheerio and Playwright.
133 stars 33 forks source link

The "path" argument must be of type string. #95

Closed xunilalala closed 3 months ago

xunilalala commented 3 months ago

I'm using version microsoft-rewards-script@1.4.5, and I've done a correct npm install. However, the terminal is returning me this error:


D:\SoftWare\Node\npm.cmd run start

> microsoft-rewards-script@1.4.5 start > node ./dist/index.js

[2024/4/18 21:35:43] [PID: 12772] [LOG] [MAIN] Bot started with 1 clusters [2024/4/18 21:35:43] [PID: 12772] [LOG] [MAIN-WORKER] Started tasks for account undefined D:\Downloads\Microsoft-Rewards-Script-main\dist\util\Load.js:58 throw new Error(error); ^

Error: TypeError [ERR_INVALID_ARG_TYPE]: The "path" argument must be of type string. Received undefined at loadSessionData (D:\Downloads\Microsoft-Rewards-Script-main\dist\util\Load.js:58:15) at Browser.createBrowser (D:\Downloads\Microsoft-Rewards-Script-main\dist\browser\Browser.js:33:62) at async MicrosoftRewardsBot.Desktop (D:\Downloads\Microsoft-Rewards-Script-main\dist\index.js:99:25) at async MicrosoftRewardsBot.runTasks (D:\Downloads\Microsoft-Rewards-Script-main\dist\index.js:83:13)

Node.js v18.12.0


I'd like to ask what's going on and how to fix it.

Additionally, I've also tried the Docker version of this release, but I'm still encountering the same error.

serzak51 commented 3 months ago

Try to delete your session files. From what i understand it fails at loading a sessiondata, maybe one is corrupted