linkedtales / scrapedin

LinkedIn Scraper (currently working 2020)
Apache License 2.0
597 stars 174 forks source link

FIX: Node is either not visible or not an HTMLElement for page.click() #108

Closed gautierdag closed 4 years ago

gautierdag commented 4 years ago

Fixes #101.

This is a PR to fix the bug I was getting when the .pv-accomplishments-block.courses button was not visible and thus not able to be clicked. It is related to a puppeteer issue: https://github.com/puppeteer/puppeteer/issues/2977.

The fix was simply to wrap the .click() into the page.evaluate() function. This also allows the removal of the timeout/wait.

leonardiwagner commented 4 years ago

Thank you @gautierdag for the contribution!