Skip to content

Conversation

@depfu
Copy link
Contributor

@depfu depfu bot commented Mar 3, 2021

Here is everything you need to know about this upgrade. Please take a good look at what changed and the test results before merging this pull request.

What changed?

✳️ electron (^8.2.5 → ^12.0.0) · Repo

Release Notes

12.0.0

Release Notes for v12.0.0

Stack Upgrades

Breaking Changes

  • Changed the default of crashReporter.start({ compress }) from false to true. #25288
  • Changed the default value of contextIsolation to true. #27949
  • Changed the default value of worldSafeExecuteJavaScript to be true. #27502
  • Deprecated the remote module. It is replaced by @electron/remote. [#25293]

Features

Additions

  • Added APIs to enable/disable spell checker. #26276
  • Added Serial API support. #25237
  • Added BrowserWindow.isTabletMode API. #25209
  • Added displayFrequency to the Display object to allow getting information about the refresh rate on Windows. #26472
  • Added event.senderFrame property returning the originating webFrameMain of the IPC message. #27047
  • Added exitCode to render-process-gone details. #27677
  • Added frame and webContents properties to the details object in webRequest handlers. #27334
  • Added net.online for detecting whether there is currently internet connection. #21004
  • Added osProcessId / name properties to webFrameMain. #26093
  • Added powerMonitor.onBatteryPower. #26494
  • Added session.setSSLConfig() to allow configuring SSL. #25461
  • Added webFrameMain.send() / webFrameMain.postMessage(). #27366
  • Added webFrameMain API for accessing sub-frames of a WebContents instance from the main process. #25464
  • Added webPreferences.preferredSizeMode to allow sizing views according to their document's minimum size. #25874
  • Added a disabledCipherSuites option to Session.setSSLConfig. #25818
  • Added a new credentials option for net.request(). #25284
  • Added a new asynchronous shell.trashItem() API, replacing the synchronous shell.moveItemToTrash(). #25114
  • Added display-capture API for session.setPermissionRequestHandler. #27696
  • Added missing webFrameMain.executeJavaScriptInIsolatedWorld(). #27195
  • Added non-localized serviceName to 'child-process-gone' / app.getAppMetrics(). #25975
  • Added read/write support for Toast Activator CLSID in shortcuts. #25493
  • Added setWindowOpenHandler API for renderer-created child windows, and deprecate new-window event. #24517
  • Added spellcheck API to renderer. #25060
  • Added support for explicitly specifying direct, auto_detect or system modes in session.setProxy(). #24937
  • Added support for showing macOS share menu. #25629
  • Added fast user switching event to powerMonitor on macOS. #25321
  • Added extension-loaded, extension-unloaded, and extension-ready events to Session. #25385
  • Allowed ContextBridge exposeInMainWorld method to expose non-object APIs. #26834
  • Allowed setting the origin header and sec-fetch-* headers in net.request(). #26135
  • Implemented Electron Fuses for customizing certain Electron features at package time. #24241
  • The launchInfo of app event ready is now populated with information from UNNotificationResponse when the app is launched via a notification presented by UNUserNotificationCenter (in a native node module). #25950

Also in earlier versions...

  • Added allowFileAccess option to loadExtension() API. #27702 (Also in 11)
  • Added win.setTopBrowserView() so that BrowserViews can be raised. #27713 (Also in 10, 11)
  • Added support for some chrome.management APIs. #25098 (Also in 9, 10, 11)
  • Made win.setAspectRatio() work on Windows. #27202 (Also in 11)

Improvements

  • Implemented custom Toast XML notifications on Windows
    • Added failure reporting of notifications on Window. #25401
  • Improved dark mode support on Windows. #25373 (Also in 10, 11)

Removed/Deprecated

  • Deprecated the remote module. It is replaced by @electron/remote. #25293
  • Removed deprecated crashReporter APIs. #26709
  • Removed links to the Electron website from the default 'Help' menu in packaged apps. #25831
  • Removed private API usage that was blocking Mac App Store releases. #26491 (Also in 11)
  • Removed the desktopCapturer.getMediaSourceIdForWebContents() API. #25414 (Also in 11)

Fixes

  • Apps requesting the CAMERA_PAN_TILT_ZOOM permission will have the permission request handler called with a permission string of "media" instead of "font-access". #27422
  • Backported fix for https://crbug.com/1125165. #27596
  • BrowserWindow.fromWebContents() now returns an accurate result for WebContents in a BrowserView or webview. #25408
  • Deprecated the use of the vm module in the renderer process. #26087
  • Enabled support for new Chromium experimental PDF viewer UI. #26010
  • Fixed BrowserWindow.fromBrowserView throwing an error when there were multiple BrowserViews in a window. #26493
  • Fixed PDF viewer failing to load resources. #27747
  • Fixed PDFs not loading in the PDF viewer. #27241
  • Fixed ses.setCertificateVerifyProc canceling requests in unrelated sessions. #26517
  • Fixed a crash in renderer process when loading non-context-aware modules with app.allowRendererProcessReuse enabled. #27317
  • Fixed a crash when calling crypto.createDiffieHellman() with certain parameters. #27700
  • Fixed a use-after-free error that could occur when destroying a WebContents during the did-stop-loading event. #26733
  • Fixed an issue that file length is not available in will-download event when file is downloaded thourgh intercepted request. #25324
  • Fixed an issue where IsMaximized would incorrectly return false for some windows on Windows. #26772
  • Fixed an issue where events on webview elements were missing properties if contextIsolation was enabled. #26289
  • Fixed an issue where net.request would continue downloading data even when the consuming stream was throttled. #25531
  • Fixed an issue where the buffer returned by NativeImage.getBitmap() could point to freed memory. #25782
  • Fixed an issue where the zoom button was missing for windows with titleBarStyle: hiddenInset on macOS. #27462
  • Fixed bug in which WebContents.mainFrame would sometimes return undefined. #27663
  • Fixed crash while exiting Electron after using the Web Serial API. #25969
  • Fixed error handling on write failure in the protocol module. #26296
  • Fixed intermittent access violation during redirects (intercepted requests). #25393
  • Fixed main process's console output not printing to devtools on Windows. #25765
  • Fixed menubar not clickable on Windows and Linux. #27555
  • Fixed missing presentation mode option in PDF viewer. #27262
  • Fixed using navigator.setAppBadge and navigator.clearAppBadge in Electron. #27431
  • Fixed webRequest module not recognizing the encoding of the filename in Content-Disposition header. #25961
  • Fixed window with customButtonsOnHover option not having rounded corner on macOS. #26960
  • Fixed chrome.runtime.getPlatformInfo crashing the background process upon being invoked. #25357
  • Backported fix for https://crbug.com/952922. #27598
  • Fixed ECDH.setPrivateKey() not updating the key. #27856
  • Fixed issue where window.open() would not return an object with a location.href setter when contextIsolation is enabled and nativeWindowOpen is disabled. #27940
  • Fixed race condition in electron.net implementation. #27938
  • Updated internal memory allocation logic such that you no longer need to use the com.apple.security.cs.allow-unsigned-executable-memory codesign entitlement on macOS. #26331
  • Updated the ICU time zone database to the latest 2020f version. #27370

Also in earlier versions....

  • Added Electron DLLs like libGLESv2.dll to symbol server. #26966 (Also in 9, 10, 11)
  • Added default Bluetooth permission strings to info.plist. #26769 (Also in 11)
  • BrowserViews will properly resize within windows. #25951 (Also in 9, 10, 11)
  • Fixed "screen" methods to be reassignable again. #26868 (Also in 11)
  • Fixed CSP with unsafe-eval detection with Trusted Types. #27471 (Also in 9, 10, 11)
  • Fixed GdiTextPrinting when used with silent printing. #25679 (Also in 9, 10, 11)
  • Fixed OS-level shortcuts on macOS (e.g. Ctrl + F2, ⌘ + ~). #27769 (Also in 11)
  • Fixed <webview> not working with Trusted Types. #27467 (Also in 9, 10, 11)
  • Fixed LC_ALL environment variable getting changed in Electron. #26507 (Also in 9, 10, 11)
  • Fixed contentTracing.stopRecording() not rejecting when there is no trace in progress. #26656 (Also in 11)
  • Fixed protocol methods not being accessible via remote.protocol. #27043 (Also in 11)
  • Fixed readdir/readdirSync (w/ withFileTypes) failing on a deep directory within archive. #27011 (Also in 10, 11)
  • Fixed screen methods not being accessible via remote.screen. #26661 (Also in 11)
  • Fixed systemPreferences.effectiveAppearance returning systemPreferences.getAppLevelAppearance(). #26879 (Also in 9, 10, 11)
  • Fixed a crash seen when printing. #25989 (Also in 11)
  • Fixed a crash that could occur on app quit when using the remote module. #27070 (Also in 11)
  • Fixed a crash when calling webContents.fromId with an unknown ID. #26651 (Also in 11)
  • Fixed a memory leak in desktopCapturer.getSources. #27058 (Also in 9, 10, 11)
  • Fixed a memory leak when creating BrowserWindows. #27641 (Also in 11)
  • Fixed an Uncaught TypeError when opening DevTools. #26474 (Also in 10, 11)
  • Fixed an erroneous enableBlinkFeatures warning shown webviews which enabled no Blink features. #27790 (Also in 10, 11)
  • Fixed an issue that a message box in GTK contains no buttons. #26917 (Also in 10, 11)
  • Fixed an issue where BrowserViews couldn't be effectively reparented. #27187 (Also in 11)
  • Fixed an issue where SIGINT was improperly handled in Node.js processes. #26971 (Also in 10, 11)
  • Fixed an issue where Save as PDF from PDF Viewer Print dialog failed and sometimes crashed. #25959 (Also in 9, 10, 11)
  • Fixed an issue where event.reply could sometimes not deliver a reply to an IPC message when cross-site iframes were present. #26925 (Also in 9, 10, 11)
  • Fixed an issue where deleted download directories would be sometimes recreated by the operating system. #27806 (Also in 10, 11)
  • Fixed an issue where draggable regions did not work exclusively on BrowserViews on Windows. #26775 (Also in 10, 11)
  • Fixed an issue where draggable regions in BrowserWindow causes BrowserView to become draggable in non-correspondent places. #26755 (Also in 10, 11)
  • Fixed an issue where non-draggable regions on BrowserViews could have incorrectly calculated bounds. #27184 (Also in 10, 11)
  • Fixed an issue where renderer process stack traces were broken with contextIsolation enabled. #26912 (Also in 11)
  • Fixed an issue where some async_hooks were not properly emitted after an error in the renderer process. #26990 (Also in 11)
  • Fixed an issue where some buttons were un-clickable in some BrowserViews with draggable regions enabled. #26496 (Also in 9, 10, 11)
  • Fixed an issue where some draggable regions were not clickable when loaded into BrowserViews on Windows. #27177 (Also in 10, 11)
  • Fixed an issue whereby remote.screen EventEmitter methods are undefined in the renderer. #26988 (Also in 11)
  • Fixed an occasional crash on Windows related to NativeViewHost::SetParentAccessible. #26952 (Also in 9, 10, 11)
  • Fixed an occasional white flicker present when rendering BrowserViews in close succession. #27658 (Also in 10, 11)
  • Fixed callbacks passed via the remote module not being released after all references are dropped. #26833 (Also in 11)
  • Fixed crash when a keyboard event immediately precedes calling browserWindow.close() on Windows. #27359 (Also in 10, 11)
  • Fixed crash when destroying WebContents in the crashed event. #27756 (Also in 10, 11)
  • Fixed crash when extension fails to load. #27589 (Also in 10, 11)
  • Fixed detection of launch on login items
    • Fixed detection of enabled state set by TaskManager. #26515 (Also in 11)
  • Fixed import of unpacked node modules. #26750 (Also in 11)
  • Fixed issue where quitAndInstall() would not restart the app upon update completion on macOS Big Sur. #25864 (Also in 11)
  • Fixed maximized frameless window bleeding to other monitors. #25940 (Also in 8, 9, 10, 11)
  • Fixed memory leak when creating "Services" menu. #25617 (Also in 9, 10, 11)
  • Fixed memory leak when sending non-primitives over the context bridge. #27636 (Also in 10, 11)
  • Fixed native window freeze on Windows when Electron app is sent to tray and external display changes. #27668 (Also in 11)
  • Fixed native window.open() to not use windowName/frameName as title by default. #27552 (Also in 10, 11)
  • Fixed regression that crashed Electron when processing an invalid icon. #27463 (Also in 11)
  • Fixed shutdown crash when quitting with in-progress downloads. #27418 (Also in 10, 11)
  • Fixed the pretty-print JavaScript feature in DevTools not functioning correctly. #25780 (Also in 11)
  • Fixed uncaught promise rejection when creating webContents with javascript disabled. #26869 (Also in 10, 11)
  • Fixed chrome.webRequest extensions API not intercepting any requests. #27098 (Also in 10, 11)
  • Fixed crash when loading wasm modules in child node process with mac arm64 > 11.2. #27685 (Also in 11)
  • Fixed slow child process spawning on macOS Big Sur. #27656 (Also in 10, 11)
  • Fixed an issue where libuv might hang with multiple subframes when nodeIntegrationInSubframes is enabled. #27879 (Also in 10, 11)
  • Fixed an out-of-bounds access in WebContents.sendInputEvent. #27855 (Also in 10, 11)
  • Fixed navigator.bluetooth.requestDevice. #27927 (Also in 11)
  • Fixed background color not being applied for child windows created by native window.open path. #27942 (Also in 10, 11)
  • Fixed a potential crash when resetting BrowserViews. #27947
  • Increase stack size on windows x64 to 8MB. #27384 (Also in 10, 11)
  • Stopped using private API CTFontDescriptorIsSystemUIFont in MAS build. #26548 (Also in 11)
  • Updated setPermissionRequestHandler to correctly recognize permissions being requested. #26172 (Also in 11)

Other Changes

  • Windows 10 versions 2004 and later support WDA_EXCLUDEFROMCAPTURE and will now exclude a window entirely from screen capture when setContentProtection is enabled. Older Windows versions will continue to show a black window as before. #24274
  • Re-enable Rosetta on Apple Silicon devices. #26568 (Also in 7.3, 8, 9, 10, 11)

Documentation

End of Support for 9.x.y

Electron 9.x.y has reached end-of-support as per the project's support policy. Developers and applications are encouraged to upgrade to a newer version of Electron.

Does any of this look wrong? Please let us know.

Commits

See the full diff on Github.

Sorry, we couldn't find anything useful about this release.


Depfu Status

Depfu will automatically keep this PR conflict-free, as long as you don't add any commits to this branch yourself. You can also trigger a rebase manually by commenting with @depfu rebase.

All Depfu comment commands
@​depfu rebase
Rebases against your default branch and redoes this update
@​depfu recreate
Recreates this PR, overwriting any edits that you've made to it
@​depfu merge
Merges this PR once your tests are passing and conflicts are resolved
@​depfu close
Closes this PR and deletes the branch
@​depfu reopen
Restores the branch and reopens this PR (if it's closed)
@​depfu pause
Ignores all future updates for this dependency and closes this PR
@​depfu pause [minor|major]
Ignores all future minor/major updates for this dependency and closes this PR
@​depfu resume
Future versions of this dependency will create PRs again (leaves this PR as is)

@depfu depfu bot added the depfu label Mar 3, 2021
@depfu
Copy link
Contributor Author

depfu bot commented Mar 12, 2021

Closed in favor of #79.

@depfu depfu bot closed this Mar 12, 2021
@depfu depfu bot deleted the depfu/update/npm/electron-12.0.0 branch March 12, 2021 01:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant