CEF communication with Chromedriver blocked

Having problems with building or using CEF's C/C++ APIs? This forum is here to help. Please do not post bug reports or feature requests here.

CEF communication with Chromedriver blocked

Postby stparkin » Tue Sep 26, 2017 4:38 pm

Hi,

We're automating a CEF-based application using Selenium and Chromedriver. This works for the most part. However, alert dialogs do not appear to be supported. To work around this, we've setup our own way of communicating the status of alert dialog. While our dialog is up, we're inside of a tight message pump loop, but what we're finding is that while in this loop, communication between CEF and Chromedriver appears to be blocked. Once we exit this loop and control is returned back to CEF, the communication continues to flow. Is there a way that we can continue to pump this communication while we're inside of the windows message pump for the alert (or confirm) dialog?

More generally, is there a way to support alert and confirm dialogs in a CEF-based application so that they can be automated by Selenium and Chromedriver?

Thanks,
--Sp
stparkin
Newbie
 
Posts: 5
Joined: Wed Nov 30, 2016 7:09 pm

Re: CEF communication with Chromedriver blocked

Postby stparkin » Tue Sep 26, 2017 4:49 pm

I'm going to try the "multi-threaded-message-loop" option with the idea that maybe this will keep the CEF-to-Chromedriver communication in its own thread.

?
stparkin
Newbie
 
Posts: 5
Joined: Wed Nov 30, 2016 7:09 pm

Re: CEF communication with Chromedriver blocked

Postby magreenblatt » Wed Sep 27, 2017 4:26 am

You can use CefJSDialogHandler to provide your own dialog implementation. For example, instead of showing a native dialog you could just execute the dialog completion callback based on a signal from your application.
magreenblatt
Site Admin
 
Posts: 12409
Joined: Fri May 29, 2009 6:57 pm

Re: CEF communication with Chromedriver blocked

Postby stparkin » Wed Sep 27, 2017 10:48 am

We are using that class to implement our own dialog. The problem is, until we return control back to CEF, communication between CEF and Chromedriver appears to be stalled.

Note that this only started to happen recently. I'm not sure why we were seeing this when I got it all working several months ago. I'm just not sure what's going on.
stparkin
Newbie
 
Posts: 5
Joined: Wed Nov 30, 2016 7:09 pm


Return to Support Forum

Who is online

Users browsing this forum: Google [Bot] and 80 guests