1

Using puppeteer: 1.3.0

Puppeteer navigates to the page using goto(url, {timeout: 0, waitUntil: 'load'}).

It then never resolved simply leaving me on the page. I can open the console in the dev tools and type in document.readyState and get "completed".

Anyone have any idea why goto is not resolving?

readyState documentation: http://www.w3schools.com/jsref/prop_doc_readystate.asp

EDIT

  1. Changed waitFor to waitUntil

  2. After further investigation I've realized that the problem is in fact with the web page I am on. The navigation does not trigger any lifecycle events which is what the goto() method relies on in order to complete.

Niklas
  • 31
  • 4
  • Seems to work in this [demo](https://puppeteersandbox.com/U5KqyOkY). Can you provide a repro in puppeteersandbox? – tony19 Apr 21 '18 at 05:42

1 Answers1

2

According to the original API, The correct syntax/argument for the loading confirmation is waitUntil and not waitFor.

goto(url, {timeout: 0, waitUntil: 'load'})
Md. Abu Taher
  • 17,395
  • 5
  • 49
  • 73