You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
As title said, the script does not work on Windows when headless: true
Switching it to: headless: false makes it work.
In particular the script stuck at networkidle2: await page.goto('https://web.microsoftstream.com/', { waitUntil: 'networkidle2' });
After 30s I got timeout exception.
I tried changing it into: await page.goto('https://web.microsoftstream.com/', { waitUntil: 'domcontentloaded' });
but the script goes on a bit and then it stuck after on this line: await page.waitForSelector('input[id="login"]'
with another timeout exception.
It seems that the browser have a different behavior when is in headless mode: puppeteer/puppeteer#665 (comment)
The comment above suggest to change user agent when you are in headless mode.
Maybe an additional window appears, or Polimi prevents bots from login (???)
The text was updated successfully, but these errors were encountered:
As title said, the script does not work on Windows when
headless: true
Switching it to:
headless: false
makes it work.In particular the script stuck at networkidle2:
await page.goto('https://web.microsoftstream.com/', { waitUntil: 'networkidle2' });
After 30s I got timeout exception.
I tried changing it into:
await page.goto('https://web.microsoftstream.com/', { waitUntil: 'domcontentloaded' });
but the script goes on a bit and then it stuck after on this line:
await page.waitForSelector('input[id="login"]'
with another timeout exception.
It seems that the browser have a different behavior when is in headless mode:
puppeteer/puppeteer#665 (comment)
The comment above suggest to change user agent when you are in headless mode.
Maybe an additional window appears, or Polimi prevents bots from login (???)
The text was updated successfully, but these errors were encountered: