Open zarigata opened 1 year ago
See if the fix from this comment works for you.
https://github.com/TychoTheTaco/Twitch-Drops-Bot/issues/238#issuecomment-1284550648
no, ive done this before and did not resolve
Hi @zarigata, since you are getting this message [2022-11-17 16:03:33] [info] Waiting for cookies to be created...
, it means you don't have the cookies.json
.
If you have the cookies.json
then try running this:
C:\Users\fuher\Twitch-Drops-Bot>node dist/index.js --cookies-path C:/Users/fuher/Twitch-Drops-Bot/cookies.json
instead of npm run start
.
Describe the bug The BOt When Opens the chrome it automaticly detects that it has an bot behindf and twitch wont allow to log in
Screenshots
Logs [2022-11-17 16:00:44] [error] Uncaught exception: Error: Page closed! at onPageClosed (file:///C:/Users/fuher/Twitch-Drops-Bot/dist/pages/login.js:36:23) at C:\Users\fuher\Twitch-Drops-Bot\node_modules\puppeteer-core\lib\cjs\third_party\mitt\index.js:3:232 at Array.map ()
at Object.emit (C:\Users\fuher\Twitch-Drops-Bot\node_modules\puppeteer-core\lib\cjs\third_party\mitt\index.js:3:216)
at CDPPage.emit (C:\Users\fuher\Twitch-Drops-Bot\node_modules\puppeteer-core\lib\cjs\puppeteer\common\EventEmitter.js:87:22)
at C:\Users\fuher\Twitch-Drops-Bot\node_modules\puppeteer-core\lib\cjs\puppeteer\common\Page.js:187:18
at processTicksAndRejections (node:internal/process/task_queues:96:5)
[2022-11-17 16:00:47] [error] Error: Protocol error (Network.getCookies): Session closed. Most likely the page has been closed.
at CDPSessionImpl.send (C:\Users\fuher\Twitch-Drops-Bot\node_modules\puppeteer-core\lib\cjs\puppeteer\common\Connection.js:316:35)
at next (C:\Users\fuher\Twitch-Drops-Bot\node_modules\puppeteer-extra-plugin-stealth\evasions\sourceurl\index.js:34:41)
at CDPSessionImpl.send (C:\Users\fuher\Twitch-Drops-Bot\node_modules\puppeteer-extra-plugin-stealth\evasions\sourceurl\index.js:67:18)
at CDPPage.cookies (C:\Users\fuher\Twitch-Drops-Bot\node_modules\puppeteer-core\lib\cjs\puppeteer\common\Page.js:724:91)
at LoginPage. (file:///C:/Users/fuher/Twitch-Drops-Bot/dist/pages/login.js:65:53)
at Generator.next ()
at fulfilled (file:///C:/Users/fuher/Twitch-Drops-Bot/dist/pages/login.js:4:58)
C:\Users\fuher\Twitch-Drops-Bot>npm run start
[2022-11-17 16:03:19] [info] Loading config file: config.json [2022-11-17 16:03:19] [info] Logging in... [2022-11-17 16:03:30] [info] Waiting for cookies to be created... [2022-11-17 16:03:33] [info] Waiting for cookies to be created... [2022-11-17 16:03:36] [info] Waiting for cookies to be created... [2022-11-17 16:03:39] [info] Waiting for cookies to be created... [2022-11-17 16:03:42] [info] Waiting for cookies to be created... [2022-11-17 16:03:45] [info] Waiting for cookies to be created... [2022-11-17 16:03:48] [info] Waiting for cookies to be created... [2022-11-17 16:03:51] [info] Waiting for cookies to be created... [2022-11-17 16:03:54] [info] Waiting for cookies to be created... [2022-11-17 16:03:57] [info] Waiting for cookies to be created... [2022-11-17 16:04:00] [info] Waiting for cookies to be created... [2022-11-17 16:04:03] [info] Waiting for cookies to be created... [2022-11-17 16:04:06] [info] Waiting for cookies to be created... [2022-11-17 16:04:09] [info] Waiting for cookies to be created... [2022-11-17 16:04:12] [info] Waiting for cookies to be created... [2022-11-17 16:04:15] [info] Waiting for cookies to be created... [2022-11-17 16:04:18] [info] Waiting for cookies to be created... [2022-11-17 16:04:21] [info] Waiting for cookies to be created... [2022-11-17 16:04:24] [info] Waiting for cookies to be created... [2022-11-17 16:04:27] [info] Waiting for cookies to be created... [2022-11-17 16:04:30] [info] Waiting for cookies to be created... [2022-11-17 16:04:33] [info] Waiting for cookies to be created... [2022-11-17 16:04:36] [info] Waiting for cookies to be created... [2022-11-17 16:04:39] [info] Waiting for cookies to be created... [2022-11-17 16:04:42] [info] Waiting for cookies to be created... [2022-11-17 16:04:45] [info] Waiting for cookies to be created... [2022-11-17 16:04:48] [info] Waiting for cookies to be created... Terminate batch job (Y/N)? y
C:\Users\fuher\Twitch-Drops-Bot>