Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Difficulty running getAppState #4

Open
Switcherag opened this issue Sep 3, 2022 · 2 comments
Open

Difficulty running getAppState #4

Switcherag opened this issue Sep 3, 2022 · 2 comments

Comments

@Switcherag
Copy link

Hey, can't log in messenger bot so i tried your script 👍

const timeoutError = new Errors_js_1.TimeoutError(waiting for ${options.title} failed: timeout ${options.timeout}ms exceeded);
^

TimeoutError: waiting for selector div[role=feed] failed: timeout 30000ms exceeded
at new WaitTask (AAAAAAAAAAAAA-main\node_modules\puppeteer\lib\cjs\puppeteer\common\DOMWorld.js:509:34)
at DOMWorld.waitForSelectorInPage (D:\Users\Switcherag\Bureau\AAAAAAAAAAAAA-main\node_modules\puppeteer\lib\cjs\puppeteer\common\DOMWorld.js:420:26)
at Object.internalHandler.waitFor (AAAAAAAAAAAAA-main\node_modules\puppeteer\lib\cjs\puppeteer\common\QueryHandler.js:31:77)
at DOMWorld.waitForSelector (AAAAAAAAAAAAA-main\node_modules\puppeteer\lib\cjs\puppeteer\common\DOMWorld.js:313:29)
at Frame.waitForSelector (AAAAAAAAAAAAA-main\node_modules\puppeteer\lib\cjs\puppeteer\common\FrameManager.js:841:51)
at Page.waitForSelector (AAAAAAAAAAAAA-main\node_modules\puppeteer\lib\cjs\puppeteer\common\Page.js:1333:33)
at AAAAAAAAAAAAA-main\getAppstate.js:19:13
at processTicksAndRejections (node:internal/process/task_queues:96:5)

I constantly get this error. I also tried to put await page.setUserAgent('Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/100.0.4896.88 Safari/537.36')

Don't throw error but don't give the json file.

Any help would be appreciated

@Th3OnlyN00b
Copy link

Change this line to be page.waitForNavigation(), that should fix your issue and let you login.

@shellmage
Copy link
Owner

heyy @Switcherag @Th3OnlyN00b , it's been a while since I last logged in to github,
If this issue is solved and you guys wanna contribute to this open-source project,
feel free to open a pull request so that I can mark the issue as closed/completed for future users,
this was just a weekend project to mess around with friends from OpenMindsClub on a messenger group back when I was still on facebook, I didn't think other people will use it, it means a lot to me

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants