Hi all,
I'm trying to use Headless Chrome (v60) to do some automated testing on an internal site that opens a popup window (using window.open).
I'm doing this from NodeJS using this excellent library https://github.com/cyrus-and/chrome-remote-interface that opens a websocket to headless Chrome.
All my operations work fine on the main window, but have trouble operating on the popup window. I am able to detect the "Target.targetCreated" event that tells me the new window has popup up, and I can connect to the page using the new URL ws://localhost:9222/devtools/page/<popup_target_id>.
However, I don't get any DOM events in the popup and calls to "Runtime.evaluate" that operate on the DOM don't return anything. "Page.captureScreenshot" doesn't return anything either.
I noticed that if I use the remote debugger to connect to headless Chrome, and go to a site that shows a pop-up, e.g.: http://www.popuptest.com/goodpopups.html, and then click on one of the "Good PopUp" links shows the popup window, and then I go to inspect the newly popped up page, the rendering of the page on the left is empty, although the HTML does show up in the DOM Debugger.
I'm running on MacOS, with this command line to start Chrome Canary:
/Applications/Google\ Chrome\ Canary.app/Contents/MacOS/Google\ Chrome\ Canary --disable-gpu --headless --disable-popup-blocking --remote-debugging-port=9222
But I also get the same results using the Docker Linux image here: https://github.com/yukinying/chrome-headless-browser-docker
Is this a known issue?
Thanks,
--Samir
--
You received this message because you are subscribed to the Google Groups "headless-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to headless-dev...@chromium.org.
To post to this group, send email to headle...@chromium.org.
To view this discussion on the web visit https://groups.google.com/a/chromium.org/d/msgid/headless-dev/05e66b47-4799-4426-a97c-8918a46f76d9%40chromium.org.