-
-
Notifications
You must be signed in to change notification settings - Fork 569
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
cef hangs while resizing in certain conditions #484
Comments
Could be this: cztomczak/cefpython#464 |
I have reproduced it and it looks like a race condition issue to me. At least adding a debug print statement somewhere in an execution chain seem to eliminate the problem. I will look into it. |
This issue is stale because it has been open 30 days with no activity. Remove stale label or comment or this will be closed in 5 days |
Is there any news? |
I gave it a try, but did not make any progress. The problem is that as soon as I add any debugging statements, the problem is gone. For example This hangs
This does not
Similarly adding print statements elsewhere in the CEF code eliminates the problem. Breakpoints set in sub threads are not invoked either. A dumb solution would be add a short sleep noop. The second example in the original post did not result in hanging on my machine. |
This problem is fixed in cefpython repo in dev branch (I hope so), but I had no luck in building it on Win 10 so I made changes to
|
Have you tested if this fixes the problem?
|
Not a single hang after this patch, tried to resize window with mouse in different ways for a long time. |
Nice one. Would you mind creating a PR?
|
Ok I'll try, but this is temporary solution until cefpython release 66.1 version (after that Browser.SetBounds method will be available on Win and we should use it to resize window) |
@MarkusFF Can you verify if @ikhmyz PR fixes this problem for you? |
Actual PR contains code using ctypes windll instead of win32gui as you suggested and it still hangs, need to check it and if the problem reproduced check win32gui version then. |
@ikhmyz Would you share an example that results in a hanging? I could not reproduce it with this code
|
I'll try it out. |
I've checked out and installed ikhmyz:win_cef_resize_hang. I didn't manage to crash either of my minimal examples, nor the app I observed the problem in the first place. Seems like it works! (at 4b53046) |
Dont have acces to Windows machine right now. It hangs when you resize the window with mouse very fast in random directions, not programatically with |
I'm also having problems with CEF windows hanging if resized with the mouse. Usually it only happens when there is background activity on the Python end. Same on Windows 10 Home and Windows Server 2019. |
Maybe it is the reason, I had another thread with socketio running when it happened. |
url = 'http://localhost' |
The pull request is merged into master. Can this be closed or are there any issues left? |
This issue is stale because it has been open 30 days with no activity. Remove stale label or comment or this will be closed in 5 days |
Thanks! |
Specification
Description
Observed reproducible hang during use of cef gui, if triggering some kind of update while resizing the window. Minimally this code usually (but not 100% of the time) hangs on my machine:
or while manually resizing something more like this:
This may be a cefpython issue.
The text was updated successfully, but these errors were encountered: