CEF Python v66.0
Installation
You can install pypi/cefpython3 package using pip tool. On Linux pip 8.1+ is required. You can also download packages for offline installation that are attached to this GitHub release. Command to install with pip:
pip install cefpython3==66.0
Support matrix
OS | Py2 | Py3 | 32bit | 64bit | Requirements |
---|---|---|---|---|---|
Windows | 2.7 | 3.4 / 3.5 / 3.6 / 3.7 | Yes | Yes | Windows 7+ |
Linux | 2.7 | 3.4 / 3.5 / 3.6 / 3.7 | Yes | Yes | Debian 8+, Ubuntu 14.04+, Fedora 24+, openSUSE 13.3+ |
Mac | 2.7 | 3.4 / 3.5 / 3.6 / 3.7 | No | Yes | MacOS 10.9+ |
Thanks to the sponsor
Many thanks to Lampix for sponsoring this release. Lampix is the first hardware and software solution that turns any surface into a smart, augmented reality or interactive surface. Please visit its website here: https://lampix.com/
Changes and notes for this release
- Update to CEF/Chromium 66.0.3359.181. (#403) See also the "Notable changes in upstream CEF" section further down on this release page.
- Support for Python 3.7 (#433)
- Debian 7 and Ubuntu 12/13 are no more supported due to upstream Chromium/CEF no more supporting these (#401)
- Add Fedora 24+ and openSUSE 13.3+ to officially supported OSes (#466)
- Bundle MSVCP dependencies on Windows [msvcp140.dll, msvcp100.dll, msvcp90.dll]. Previously these were not included and it was required for Visual C++ redistributables to be already installed on a system. (#359)
- Add easy to understand code snippets in the "examples/snippets/" directory. These snippets show how to use various CEF features:
- javascript_bindings.py - Communicate between Python and Javascript asynchronously using inter-process messaging with the use of Javascript Bindings.
- javascript_errors.py - Two ways for intercepting Javascript errors.
- mouse_clicks.py - Perform mouse clicks and mouse movements programmatically.
- network_cookies.py - Implement interfaces to block or allow cookies over network requests.
- onbeforeclose.py - Implement interface to execute custom code before browser window closes.
- ondomready.py - Execute custom Python code on a web page as soon as DOM is ready.
- onpagecomplete.py - Execute custom Python code on a web page when page loading is complete.
- There were multiple changes in upstream CEF that are backward incompatible and thus require modifications to your code. See the Migration Guide document or see the "Breaking changes.." section further down on this release page.
- A known issue: qt.py PyQt4 and PySide examples crash during browser creation on Linux. This is an upstream CEF issue and needs to be resolved in upstream first. (#452) PyQt5 example works fine on Linux.
- A known issue: tkinter.py example hangs on exit and during window resize with Tk 8.5 on Windows (#441)
- A known issue: "blob_storage/" and "webrtc_event_logs/" directories are created in current working directory when using in-memory cache (#432)
- Add accessibility support. See
Browser
.SetAccessibilityState for both windowed and OSR browsers. See AccessibilityHandler for OSR browsers. (#449) - Add
DisplayHandler
.OnLoadingProgressChange - Support for loading certificate revocation lists. See
cefpython
.LoadCrlSetsFile for loading the existing "Certificate Revocation Lists" file that is managed by Google Chrome - Add
RequestHandler
.CanGetCookies and CanSetCookie to allow or block cookies over network requests - Add
Browser
.GetImage method to get browser visible contents as image. Available only on Linux. (#427) - Add
Browser
.Invalidate to force frame to be painted in OSR mode - Add
CookieManager
.GetBlockingManager - Add
CookieManager
.FlushStore to flush cookies to disk manually - Add
BrowserSettings
.inherit_client_handlers_for_popups option. This is enabled by default and makes client handlers/callbacks to be inherited by popup browsers created implicitilly e.g. via "window.open" in js - Handle more keyboard shortcuts on Mac and fix double Paste bug (#161)
- Fix cookies not flushed to disk when closing app immediately (#365)
- Fix High DPI support on Windows. Support High DPI in the wxpython.py example (#399)
- Add
DpiAware
.Scale which is reliable with any DPI settings. TheDpiAware.CalculateWindowSize
method is deprecated. FixDpiAware.GetSystemDpi
. (#398) - Add DragData Image APIs on Windows and Mac (Linux was already supported):
GetImage
,GetImageHotspot
,HasImage
(#251) - Fix crashes on websites with multiple frames when closing app during loading (#431)
- Fix two crashes when closing app immediately during initial loading (#454, #455)
- Fix
Request.SetPostData
andGetPostData
not working. All strings are expected to be byte strings. (#228) - Fix window glitchiness during initial loading on Mac by setting
setWantsLayer:YES
in the wxpython.py example (#371) - Fix process sometimes hanging when exiting app in the qt.py PySide example (#360)
- Fix exception message sometimes not printed on Mac, an issue with
cef.ExceptHook
(#382) - Fix crash when closing print dialog on Linux (#435)
- Fix creation of "GPUCache/" directory when using in-memory cache (#419)
- Add
RenderHandler
.OnTextSelectionChanged - Add
Browser
.SetAutoResizeEnabled - Add
DisplayHandler
.OnAutoResize - Support linking to GTK 3 when building CEF from sources and when building cefpython module. Patch is available in comments in Issue #446.
- Add
--enable-profiling
and--enable-linetracing
flags tobuild.py
tool to allow for profiling cefpython code with cProfile module (#424) - Add
--no-depot-tools
update flag toautomate.py
to allow of building old unsupported versions of Chromium. Update build instructions, see for more details. (#428) - Add
Browser
.GetSetting - Add
Browser
.HasDevTools - Add
cefpython
.SetGlobalClientHandler - Add
cefpython
.GetBrowserByIdentifier - Add
cefpython
.GetDataUrl - Linux patch that fixed HTTPS cache problems on pages with certificate errors was disabled, see here
- Add unit tests for off-screen rendering mode, see osr_test.py (#59)
- See Milestone v66 for all issues related with this release
- Upstream CEF prebuilt binaries for this release are available in release tagged v66-upstream.
Breaking changes that are described in details in Migration Guide document
- Changes to Mac apps that integrate into existing message loop (Qt, wxPython), see here
RequestHandler.OnBeforeBrowse
has a new param 'user_gesture', see hereLifespanHandler.OnBeforePopup
is now called on UI thread, see hereDisplayHandler.OnConsoleMessage
has a new param 'level', see hereRequestHandler.GetCookieManager
not getting called in some cases, see herecef.Request.Flags
changed,AllowCachedCredentials
was removed and others were added, see here- Window transparency changes, see here
- Threads removed:
TID_DB
,TID_PROCESS_LAUNCHER
,TID_CACHE
, see here BrowserSettings.javascript_open_windows_disallowed
option was removed, see here
Notable changes in upstream CEF
- Windows: Add per monitor DPI support (upstream #2313)
- Add support for WebRTC screen sharing (upstream #1065)
- Fix IndexedDB quota (upstream #2070)
- OSR: Fix GPU->CPU readback performance issues (upstream #2046)
- Enable Brotli encoding (upstream #2303)
- Support for SwiftShader, a high-performance CPU-based implementation of the OpenGL ES and Direct3D 9 graphics APIs
- Remove geolocation API support (upstream #2380)
- Add support for component=shared_library builds (upstream #1617)
- Add support for automate-git.py --fast-update (upstream #2435)
- Support for Chrome Extensions with partial API support (not yet exposed to cefpython, see #457)
- Add CefServer API for handling HTTP/WebSocket requests (not yet exposed to cefpython, see #445)
- Add support for V8 ArrayBuffers (not yet exposed to cefpython, see #450)