-
-
Notifications
You must be signed in to change notification settings - Fork 474
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
Review commits by sidreesshah who updated cefpython to the latest CEF #195
Comments
Hi Czarek, How will an empty function prevents the crash? |
Also i have updated my repo to support fedora 23 recently. |
Hi Syed, The idea is to keep the API backwards compatible. Python is a dynamic language and API changes can't be easily detected, as there is no compilation process. I just don't want user's code to break after updating - whenever possible. Regarding that specific function - ParentWindowWillClose() - never did anything on some of the OS'es, don't remember exactly but it probably only affected one OS. Regarding the crash. What kind of checks? Does it only occur in Debug mode? How are you running the Debug mode? |
Ok. Got your point about keeping that function. Thanks for that. Here are the checks i have to disable in CEF:
bool CefBrowserInfo::RenderIDManager::is_render_id_match( #ifndef NDEBUG
@@ -198,6 +198,6 @@ void CefBrowserMainParts::PostDestroyThreads() { #ifndef NDEBUG
Yes, it occurs only in Debug mode. I just compile the CEF in Debug/Release mode and stick it into CefPython using the steps you have mentioned on your sources. Since you are using only CEF Release builds, you may not see them. |
These reports seem to be related:
Looks like an issue in upstream CEF. |
To me it seems more like cefpython or my application not releasing the references. I could not reproduce the crashes with cefclient. How do we release the reference in Python? |
What was the earliest branch of CEF you've been testing? In which branch did the crash start happening? Does the crash occur in one of official cefpython examples? See the wxpython.py example > OnClose function for an example on how to release CEF references (use the del operator on a CEF object):
Browser is not the only object that needs to be released. This applies also to request objects and probably others. In the wxpython-response.py example we keep strong references to the ResourceHandler class which keeps CEF references to request objects and others - these need to be released when work is done. See:
|
It was branch 2272 and i started seeing crashes very early on. I think i did not see any crash in pygtk_.py at that time. Thanks for the reference links, i am not taking these steps for sure onClose. Will include them definitely. There is one more thing that i did not pay attention to is that pygtk_.py started crashing after CEF release 2454, i guess. Luckily my own application was and is working fine, so i did not pay any attention to the pygtk_.py crash. Here is the crash what i am getting with pygtk_.py: |
What is the stack trace in GDB? |
Maybe this is a non-fatal error that should be ignored? See xlib error handler in cefclient: https://bitbucket.org/chromiumembedded/cef/src/c3d80a5658b8636964981da23b455c3c85b3259e/tests/cefclient/cefclient_gtk.cc?at=master&fileviewer=file-view-default#cefclient_gtk.cc-104 |
I think you are right. I am using xlib in my application. And just removing the calls to that started crashing my application(although with different stack). Here is the backtrace for pygtk_.py anyhow:
|
You referenced many issues with your |
Not the greatest idea by GitHub to treat every hash followed by a number as an issue.. |
Ohhh...i idid not realize it :-) Thanks for fixing the comments. So you are merging my changes with some of your updates? |
Like I said earlier, I will add comments and ask some questions on bitbucket. I haven't yet reviewed it. |
Sorry i did not understand your previous comment about "embraced code with three backticks". My english :-). Its clear now. |
I tried to test your code on ubuntu, 64bit. I had to remove a semicolon in
The compilation succeeded (the
I used the prebuilt CEF binaries from branch 2526. Any ideas? |
I started reviewing the code. Added a bunch of comments to the fd7f932 commit. @allestuetsmerweh You won't be happy about this - Idris removed OSR support ;) See window_info_cef3.pyx. |
@sidreesshah What is missing and I think is important is example usage for many of the new functions. I see you've updated to Cython 0.23.4 - didn't you have any issues with that update? Last time I've checked there were incompatibilities - see Issue #110. |
@sidreesshah I haven't found xlib error handler in pygtk_.py and from what you've said earlier it's important to set it to avoid crashes. Are you using c++ code or do you make the calls using python, in such case can you share it? Were there any other issues of importance? |
There is an ongoing big refactoring, so hold on with any pull requests. See Issue #208 - "Big code cleanup and refactoring with the upcoming Chrome 47 release". |
Sorry man, just saw your comments now. I was too busy for last week. I will look at your comments today and not push anything new till you are done with the upgrade. I will be as active as i can on #208 to help the upgrade. As for as your previous queries, i did not experience any major issue with upgrade of Cython. My application uses python but it also uses C calls to X functions via Cython. Its not my own product, but i will see if i can reduce it to bare minimum open source and publish it. |
Regarding X11 error handler - I will expose cefpython.x11.InstallErrorHandlers() using the cefclient code that sets the error handlers. That's best I think. Issues with Cython may not be obvious - those are subtle bugs that may reveal in some of the functions. |
Btw. thanks for sharing code. It gave me an overall look what needs to be done and how. |
you are wellcome.:-) So far we have not hit any issue with Cython but there On Tue, Feb 16, 2016 at 11:14 AM, Czarek Tomczak notifications@github.com
|
In Issue #216 I've outlined modifications and new features added in your fork. Also listed several changes in upstream cefclient that need action. |
Syed's repository is available on bitbucket:
https://bitbucket.org/idrissha/cefpython
His work is tested only on Linux (Fedora 21). Some features may have been removed. Some functions were removed and that breaks BC - eg. ParentWindowWillClose() should stay and do just nothing.
Review his code: ask questions and add comments on bitbucket.
The text was updated successfully, but these errors were encountered: