Open babaz8 opened 10 months ago
in fetchJobLinksUser.ts before await page.type(selectors.keywordInput, keywords); , add await page.waitForSelector(selectors.keywordInput); .
I also have another suggestion to work around this as the above solution wasn't helping and the issue for me as occurring in login -> index.ts.
The selectors specified in selectors -> index.ts wasn't being found so I made the following changes to the login process:
Changed index.ts:14 await page.goto('https://www.linkedin.com', { waitUntil: 'load' });
to await page.goto('https://www.linkedin.com/login', { waitUntil: 'load' });
Updated my selectors in selectors -> index.ts from line 25 to:
// Login captcha: "#captcha-internal", emailInput: "#username", passwordInput: "#password", loginSubmit: "button[class*='btnprimary--large frombutton--floating']", skipButton: "button[text()='Skip']",
If you're still running into the issue, try what ismaelrodino2 mentioned above and set the wait for selectors for login selectors etc on the login selectors: await page.waitForSelector(selectors.emailInput);
No element found for selector: #session_key at assert (/Users//linkedin-easy-apply-bot/node_modules/puppeteer-core/src/util/assert.ts:29:11) at IsolatedWorld.type (/Users//linkedin-easy-apply-bot/node_modules/puppeteer-core/src/common/IsolatedWorld.ts:348:11) at processTicksAndRejections (node:internal/process/task_queues:95:5) at async login (/Users//linkedin-easy-apply-bot/login/index.ts:17:3) at async /Users//linkedin-easy-apply-bot/scripts/apply.ts:45:3