Compare commits

...

1131 Commits

Author SHA1 Message Date
Keeley Hammond
ea87f0b76e fix: remove macwebcontentsocclusion patch 2026-02-16 17:22:08 -08:00
Shelley Vohr
eb29568e45 feat: introduce os_crypt_async in safeStorage (#49054)
* feat: support Freedesktop Secret Service OSCrypt client

Refs https://issues.chromium.org/issues/40086962
Refs https://issues.chromium.org/issues/447372315

* chore: rework to async interface

* refactor: allow customizing freedesktop config

* docs: add more async impl info

* refactor: reject when temporarily unavailable

* chore: feedback from review

* chore: push_back => emplace_back
2026-02-15 19:54:50 +01:00
Shelley Vohr
dcdbb0397e feat: allow defaulting to printer default page size (#49523)
Co-authored-by: Edvan de Matos <edvan.santos@querodelivery.com>
2026-02-13 07:40:14 -05:00
electron-roller[bot]
3a5f9e0a33 chore: bump node to v24.13.1 (main) (#49744)
* chore: bump node in DEPS to v24.13.1

* chore: fixup patches

refs:
* https://github.com/nodejs/node/pull/60425
* https://github.com/nodejs/node/pull/61270
* https://github.com/nodejs/node/pull/61044

* fix: generate_config_gypi needs to generate valid JSON

https://github.com/nodejs/node/pull/60794

* doc: align Buffer.concat documentation with behavior

https://github.com/nodejs/node/pull/60405

* src: fix off-thread cert loading in bundled cert mode

https://github.com/nodejs/node/pull/60764

* build: fix extraneous includes

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
2026-02-13 09:48:05 +01:00
Keeley Hammond
f90e35cb45 chore: cherry-pick e045399a1ecb from chromium (#49788)
* chore: cherry-pick e045399a1ecb from chromium

* chore: update patch
2026-02-12 19:24:19 -08:00
Shelley Vohr
74fd10450f feat: improve Windows Toast actions support (#48132)
* feat: improve Windows Toast actions support

* fix: ensure MSIX compatibility

* test: add bad clsid format test
2026-02-12 17:25:20 -05:00
electron-roller[bot]
a65cfed500 chore: bump chromium to 146.0.7666.0 (main) (#49528)
* chore: bump chromium in DEPS to 146.0.7652.0

* fix(patch-conflict): update mas_avoid_private_macos_api_usage context for constrainFrameRect method

The upstream CL added a new constrainFrameRect:toScreen: method override to
NativeWidgetMacNSWindow as part of headless mode window zoom implementation.
The MAS patch's #endif for frameViewClassForStyleMask now correctly appears
after that method, since constrainFrameRect is a public API override that
doesn't need to be guarded.

Ref: https://chromium-review.googlesource.com/c/chromium/src/+/7487666

* fix(patch-conflict): update printing.patch for base::DictValue rename

Updated printing.patch to use the new base::DictValue type name instead of
base::Value::Dict following Chromium's type renaming change. This affects
CompleteUpdatePrintSettings() signature and related code.

Ref: https://chromium-review.googlesource.com/c/chromium/src/+/7509820

* fix(patch-conflict): update accessibility_ui patch for base::DictValue/ListValue rename

Updated adjust_accessibility_ui_for_electron.patch to use the new
base::DictValue and base::ListValue type names instead of base::Value::Dict
and base::Value::List following Chromium's type renaming change.

Ref: https://chromium-review.googlesource.com/c/chromium/src/+/7509820

* chore: update patches

* 6625736: Rename DURABLE_STORAGE to PERSISTENT_STORAGE for consistency | https://chromium-review.googlesource.com/c/chromium/src/+/6625736

* chore: bump chromium in DEPS to 146.0.7653.0

* chore: update patches

* 7000847: add type tag to v8::External for gin_helper function templates

The upstream gin function templates now use v8::ExternalPointerTypeTag
for type safety when using v8::External. Updated Electron's forked
gin_helper function template to use the same kGinInternalCallbackHolderBaseTag
that Chromium's gin uses.

Ref: https://chromium-review.googlesource.com/c/chromium/src/+/7000847

* fix(patch-update): extend V8 Object API deprecation patch for Node.js

Extended the existing patch to cover additional files that use
GetAlignedPointerFromInternalField and SetAlignedPointerInInternalField:
- src/stream_base-inl.h
- src/udp_wrap.cc
- src/js_udp_wrap.cc
- src/node_process_methods.cc
- src/node_snapshotable.cc
- src/base_object.cc

These APIs now require an EmbedderDataTypeTag parameter.

Ref: https://chromium-review.googlesource.com/c/v8/v8/+/7087956

* 7000847: add type tag to v8::External calls in shared_texture

Updated v8::External::New and v8::External::Value calls to use the
kExternalPointerTypeTagDefault tag as required by the V8 API change
that deprecates the tagless versions.

Ref: https://chromium-review.googlesource.com/c/chromium/src/+/7000847

* 7508687: use ChildProcessId for file permission APIs

The ChildProcessSecurityPolicy::CanReadFile and GrantReadFile APIs
now require ChildProcessId instead of int. Updated to use GetID()
instead of GetDeprecatedID() for these specific calls.

Ref: https://chromium-review.googlesource.com/c/chromium/src/+/7508687

* 7000847: add type tag to v8::External calls in callback and osr_converter

The v8::External API now requires an EmbedderPointerTypeTag parameter
for both New() and Value() methods to improve V8 sandbox type safety.

Updated calls in:
- callback.cc: TranslatorHolder constructor and CallTranslator
- osr_converter.cc: OffscreenSharedTextureValue converter

Ref: https://chromium-review.googlesource.com/c/v8/v8/+/7000847

* fixup! 7087956: [api] Promote deprecation of v8::Context and v8::Object API methods

Extended the Node.js patch to cover histogram.cc which also uses
SetAlignedPointerInInternalField and GetAlignedPointerFromInternalField
APIs that now require the EmbedderDataTypeTag parameter.

Ref: https://chromium-review.googlesource.com/c/v8/v8/+/7087956

* chore: bump chromium in DEPS to 146.0.7655.0

* chore: update patches

* 7509043: update WebSpellingMarker type for API change

The upstream Chromium API changed - WebSpellingMarker was moved from a
nested type within WebTextCheckClient to a standalone type in the blink
namespace.

Ref: https://chromium-review.googlesource.com/c/chromium/src/+/7509043

* 7498491: update process_id to use OriginatingProcess type

The upstream Chromium API changed - URLLoaderFactoryParams::process_id
was changed from an integer to a union type network::OriginatingProcess
that distinguishes between browser and renderer processes.

- For browser process requests, use OriginatingProcess::browser()
- For renderer process lookups, check !is_browser() and use
  renderer_process().value() to get the child_id

Ref: https://chromium-review.googlesource.com/c/chromium/src/+/7498491

* 5710330: Add crash keys to debug NativeWidgetMacNSWindowBorderlessFrame exception | https://chromium-review.googlesource.com/c/chromium/src/+/5710330

5710330 added a new NSNextStepFrame interface extension and
implementations for NativeWidgetMacNSWindowTitledFrame and
NativeWidgetMacNSWindowBorderlessFrame. These use private macOS APIs
that are not available in Mac App Store builds.

* chore: update patches

* chore: bump chromium in DEPS to 146.0.7661.0

* chore: bump chromium in DEPS to 146.0.7663.0

* fix(patch-conflict): update accessibility_ui for string_view API change

Upstream removed redundant std::string(default_api_type) conversion as part
of a string_view optimization cleanup. Updated patch context to match.

Ref: https://chromium-review.googlesource.com/c/chromium/src/+/7514107

* fix(patch-conflict): update service process launch options for sandbox API refactor

Upstream removed content/common/sandbox_init_win.cc and
content/public/common/sandbox_init_win.h, moving the functionality directly
into ChildProcessLauncherHelper. Updated patch to call
sandbox::policy::SandboxWin::StartSandboxedProcess directly with the
LaunchOptions pointer instead of going through the removed helper.

Ref: https://chromium-review.googlesource.com/c/chromium/src/+/7528253

* fix(patch-conflict): update MAS safestorage for keychain API refactor

Upstream refactored KeychainPassword::GetPassword() to use a new
GetPasswordImpl() helper function with improved error tracking via
base::expected<std::string, OSStatus>. Adapted patch to use the new
GetPasswordImpl with the suffixed account name and handle migration
from legacy accounts through the new API.

Ref: https://chromium-review.googlesource.com/c/chromium/src/+/7516438

* chore: update patches

* chore: bump chromium in DEPS to 146.0.7663.0

* fix: base::Value::Dict -> base::DictValue
https://chromium-review.googlesource.com/c/chromium/src/+/7513889

* fix: include new cookie exclusion reason
https://chromium-review.googlesource.com/c/chromium/src/+/7486527

* fix: enable libc++ ABI flag for trivially copyable std::vector<bool>

Required for changes introduced in the following CL
https://chromium-review.googlesource.com/c/chromium/src/+/7513653

* fixup! fix: base::Value::Dict -> base::DictValue https://chromium-review.googlesource.com/c/chromium/src/+/7513889

* fix: spellcheck not working in tests
https://chromium-review.googlesource.com/c/chromium/src/+/7452579

* fix: cookie test failing due to multiple rejection reasons
https://chromium-review.googlesource.com/c/chromium/src/+/7506629

* fix: macos sizing unmaximized window incorrectly
https://chromium-review.googlesource.com/c/chromium/src/+/7487666

Changes to headless mode caused the unmaximized window to subtract
the height of the menubar.

* fix: skip tests for incompatible BoringSSL ML-DSA crypto
https://boringssl-review.googlesource.com/c/boringssl/+/84929

* test: fix pseudonymization registration in utility process on Linux

Ref: 7486913: Pass pseudonymization salt via shared memory at process launch | https://chromium-review.googlesource.com/c/chromium/src/+/7486913

* fix: restore MAS patch-outs

Restores some `#if !IS_MAS_BUILD()` gates dropped in 773054ad59

* fixup! 7508687: use ChildProcessId for file permission APIs

* fixup! fix(patch-conflict): update MAS safestorage for keychain API refactor

* chore: add note about parallel upstream change

* fixup! Merge remote-tracking branch 'origin/main' into roller/chromium/main

* Revert "fixup! 7508687: use ChildProcessId for file permission APIs"

This reverts commit 05c43e4e5d.

The _impl version has the signature, but not the public interface. :oof:

* fixup! fix(patch-conflict): update MAS safestorage for keychain API refactor

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: Keeley Hammond <khammond@slack-corp.com>
Co-authored-by: Samuel Maddock <samuelmaddock@electronjs.org>
Co-authored-by: clavin <clavin@electronjs.org>
2026-02-12 12:37:56 -05:00
Calvin
e9faa14cc0 test: drag region tests (#49266) 2026-02-12 01:50:02 -06:00
Niklas Wenzel
ce47542ccd feat: add support for long-animation-frame script attribution (#49706)
* feat: add support for `long-animation-frame` script attribution

* docs: document `AlwaysLogLOAFURL`

* chore: add test

* docs: adjust docs as per PR comment

* fix: test failures

* chore: simplify test

* fix: tests on Windows and Linux
2026-02-11 09:34:22 -08:00
dependabot[bot]
ff2df2c98a build(deps): bump diff from 3.5.0 to 3.5.1 in the npm_and_yarn group across 1 directory (#49666)
build(deps): bump diff in the npm_and_yarn group across 1 directory

Bumps the npm_and_yarn group with 1 update in the / directory: [diff](https://github.com/kpdecker/jsdiff).


Updates `diff` from 3.5.0 to 3.5.1
- [Changelog](https://github.com/kpdecker/jsdiff/blob/master/release-notes.md)
- [Commits](https://github.com/kpdecker/jsdiff/compare/v3.5.0...v3.5.1)

---
updated-dependencies:
- dependency-name: diff
  dependency-version: 3.5.1
  dependency-type: indirect
  dependency-group: npm_and_yarn
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-02-11 16:52:05 +01:00
John Kleinschmidt
0284b9afcc build: fixup attestation for release assets (#49732)
* build: fixup attestation for release assets

* Generate artifact attestation for generated artifacts

* set id-token for attestation

* Add artifact-metadata permission for attestation

* add permissions for testing attestations

* Revert "add permissions for testing attestations"

This reverts commit 0284bed175.

* Revert "set id-token for attestation"

This reverts commit 69a1b13a18.

* Revert "Generate artifact attestation for generated artifacts"

This reverts commit ee0536eceb.
2026-02-11 07:17:59 -05:00
David Sanders
52061b4c28 ci: add markdownlint problem matcher (#49751) 2026-02-11 13:17:29 +01:00
David Sanders
ec6d2fe549 build(dev-deps): update micromark-core-commonmark to 2.0.3 (#49749) 2026-02-11 13:11:58 +01:00
Ronald Eddy Jr
1c621cc982 docs: fix typos across documentation (#49734)
Fix 40 typos across 25 documentation files including misspellings,
missing words, doubled words, wrong words, and grammatical errors.
2026-02-11 12:45:46 +01:00
Shelley Vohr
57a6e43025 fix: revoke Read access after removing file via FileSystemAccess API (#49620)
Refs https://chromium-review.googlesource.com/6677249
2026-02-10 15:48:05 +01:00
dependabot[bot]
ef5b232e9f build(deps): bump github/codeql-action from 4.32.1 to 4.32.2 (#49735)
Bumps [github/codeql-action](https://github.com/github/codeql-action) from 4.32.1 to 4.32.2.
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](6bc82e05fd...45cbd0c69e)

---
updated-dependencies:
- dependency-name: github/codeql-action
  dependency-version: 4.32.2
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-02-10 15:06:42 +01:00
Bug-Reaper
99fce5b6ca fix: address upstream Chromium shift to enable CoreAudio Tap API for audio capture used in electron's desktopCapturer (🍏 macOS). (#49717)
* fix: Enable CoreAudio Tap API for Audio Capture (🍏 macOS)

* fix: addressed markdown issue which caused pre-commit hook failure

🧑‍🔧 : Ref : https://github.com/electron/electron/pull/49717#issuecomment-3874660013

* fix: updated docs to cover `desktopCapturer` nuances with macOS

📝 : PR https://github.com/electron/electron/pull/49717
2026-02-10 15:06:21 +01:00
Rushikesh Bobade
7c66112e88 docs: link unlinked type references in API documentation (#49651)
docs: add missing type links in menu.md and shared-texture.md
2026-02-09 23:08:52 -08:00
John Kleinschmidt
fd0108907a build: fixup build attestation (#49730) 2026-02-09 11:50:17 -05:00
reito
3fa3e91f90 docs: fix framerate limit when osr with shared texture (#49705) 2026-02-09 15:18:06 +01:00
David Sanders
a3563422c4 ci: fix patches changes detected in apply patches workflow (#49701) 2026-02-06 13:48:30 -08:00
Keeley Hammond
9db2290bcd fix: restore macos 12 support in Node 24 (#49697) 2026-02-06 07:48:37 -08:00
Samuel Attard
60d35bbaf4 feat: add support for disclaiming utility processes (#49128)
* feat: add support for disclaiming utility processes

* chore: update patches

---------

Co-authored-by: Keeley Hammond <vertedinde@electronjs.org>
2026-02-05 14:37:24 -08:00
Michaela Laurencin
15dc7170ef ci: fix ai-pr label commenting (#49685) 2026-02-05 14:27:46 -05:00
Keeley Hammond
59e434a27f refactor: use ComPtr pattern for MSIX to avoid exception handling (#49645)
* Revert "fix: fix Windows MSIX release build errors (#49613)"

This reverts commit 4b5d5f9dd5.

* refactor: use WRL ComPtr pattern for MSIX to avoid exception handling

The MSIX auto-updater code was using C++/WinRT (winrt::* namespace), which requires exception handling (/EHsc). Mixing exception and non-exception handling code in the same binary is problematic at runtime. This commit refactors electron_api_msix_updater.cc to use an upstream Chromium pattern and eliminates the need for special exception handling build flags

* build: import correct packages

* build: consolidate IPackage declarations

* refactor: use IPackageManager/IPackageManager5/IPackageManager9 and
IPackage/IPackage2/IPackage4/IPackage6 interfaces as needed for
different API methods.

Also consolidates duplicate completion handler logic, fixes a bug in
RegisterRestartOnUpdate where the command line string could go out of
scope, and removes unused includes.
2026-02-05 10:42:28 -08:00
Samuel Attard
dec7f937ae build: generate artifact attestions for released assets (#48239)
* build: generate artifact attestions for released assets

* chore: address review feedback

---------

Co-authored-by: John Kleinschmidt <kleinschmidtorama@gmail.com>
2026-02-05 09:37:17 -05:00
Noah Gregory
50381a6d57 refactor: don't log error just for unsigned code (#49654) 2026-02-05 15:26:17 +09:00
David Sanders
41c7e9bb21 ci: use squash merge for apply patches workflow (#49667) 2026-02-04 15:51:49 -08:00
Shelley Vohr
9740c989da fix: default accelerator for role-based menu items (#49558)
fix: apply default accelerator for role-based menu items

Co-authored-by: Kimgun3383 <tygob5247@gmail.com>
2026-02-04 16:45:29 -05:00
John Kleinschmidt
4ea2d816b8 revert(ci): use new case syntax in workflows (#49665)
Revert "ci: use new case syntax in workflows (#49590)"

This reverts commit def7854848.
2026-02-04 14:55:20 -05:00
Noah Gregory
6a47bb4731 fix: use temp directory for singleton test and clean up at end (#49604)
* fix: create directory for singleton test in `temp` instead of `home`

* fix: remove directory for singleton test at test end

* refactor: avoid extraneous declarations in singleton test

* refactor: reintroduce `userDataFolder` declaration in singleton test

* refactor: move cleanup before app exit in singleton test

* style: add missing semicolon

* refactor: set the user data path after pre-test cleanup in singleton test

* fix: release lock before cleanup in singleton test
2026-02-04 14:43:36 -05:00
David Sanders
ef11669b67 ci: handle PRs with no checks in rerun apply patches (#49630) 2026-02-04 16:13:27 +01:00
Shelley Vohr
d7378d96a5 docs: add Wayland note to win.getPosition() and win.getBounds() (#49632)
docs: add Wayland note to win.getPosition()
2026-02-04 16:13:11 +01:00
Keeley Hammond
431f77ca1c fix: remove menu observer before destroying menu_controller_ (#49648)
* fix: remove menu observer before destroying menu_controller_

* fix: resolves private inheritance conflict
2026-02-04 16:11:00 +01:00
Shelley Vohr
51a9101c3d build: remove Core Graphics private macOS APIs on MAS (#49633) 2026-02-03 12:02:06 -05:00
Shelley Vohr
def7854848 ci: use new case syntax in workflows (#49590)
ci: use new case synta in workflows
2026-02-03 11:57:14 -05:00
Niklas Wenzel
28858ecb85 chore: add "I have built and tested this PR" box to PR template (#49434) 2026-02-03 11:39:07 -05:00
Shelley Vohr
8fdb7549bb fix: alt-space should route through 'system-context-menu' (#49619)
fix: alt-space should route through system-context-menu
2026-02-03 11:34:58 -05:00
dependabot[bot]
c3428fa413 build(deps): bump lodash from 4.17.21 to 4.17.23 in the npm_and_yarn group across 1 directory (#49577)
build(deps): bump lodash in the npm_and_yarn group across 1 directory

Bumps the npm_and_yarn group with 1 update in the / directory: [lodash](https://github.com/lodash/lodash).

Updates `lodash` from 4.17.21 to 4.17.23
- [Release notes](https://github.com/lodash/lodash/releases)
- [Commits](https://github.com/lodash/lodash/compare/4.17.21...4.17.23)

---
updated-dependencies:
- dependency-name: lodash
  dependency-version: 4.17.23
  dependency-type: indirect
  dependency-group: npm_and_yarn
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-02-03 11:05:40 -05:00
loc
233caf8469 fix(squirrel.mac): clean up old staged updates before downloading new update (#49365)
fix: clean up old staged updates before downloading new update

When checkForUpdates() is called while an update is already staged,
Squirrel creates a new temporary directory for the download without
cleaning up the old one. This can lead to disk usage growth when
new versions are released while the app hasn't restarted.

This adds a force parameter to pruneUpdateDirectories that bypasses
the AwaitingRelaunch state check. This is called before creating a
new temp directory, ensuring old staged updates are cleaned up.
2026-02-03 11:04:06 -05:00
Shelley Vohr
86209f60eb fix: possible crash in FileSystem API (#49578)
Refs https://chromium-review.googlesource.com/6880247

Fixes a crash that can arise in the File System Access API in the
following scenario:

1. Create fileHandle1 at path1.
2. Call fileHandle1.remove() or user manually delete the file.
3. Create fileHandle2 at path2.
4. fileHandle2.move(path1).
2026-02-03 15:15:54 +01:00
dependabot[bot]
bdf2b67462 build(deps): bump github/codeql-action from 4.32.0 to 4.32.1 (#49629)
Bumps [github/codeql-action](https://github.com/github/codeql-action) from 4.32.0 to 4.32.1.
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](b20883b0cd...6bc82e05fd)

---
updated-dependencies:
- dependency-name: github/codeql-action
  dependency-version: 4.32.1
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-02-03 15:03:22 +01:00
Mr.Chaofan
4413a0f642 fix: wrong cause and removed flag in cookie change listener (#49103) 2026-02-03 10:19:35 +01:00
Shelley Vohr
3776731f4a fix: menu state in macOS dock menus (#49574) 2026-02-02 17:01:34 -05:00
Robo
db5606b4b3 fix: handle out of order recording errors in skia graphite (#49608) 2026-02-02 14:20:19 +01:00
Calvin
1159de52e7 docs: app.getGPUInfo() may reject (#49580) 2026-02-02 10:00:05 +01:00
Keeley Hammond
4b5d5f9dd5 fix: fix Windows MSIX release build errors (#49613)
* fix: fix MSIX release build

* fix: add C++/WinRT headers

* build: modify include paths

* fix: compile msix as seperate source set

* build: add additional needed deps for msix
2026-02-01 22:27:42 -08:00
Prachi Maskar
0cbf3c2918 docs: add jsign instructions for Azure Trusted Signing on Linux/macOS (#49345)
* docs: add jsign instructions for Azure Trusted Signing on Linux/macOS

* docs: add clickable jsign link for Azure Trusted Signing
2026-01-30 15:24:08 -05:00
axolotl
f272723a33 feat: Allow View.setBounds to animate (#48812)
* feat: allow View::SetBounds to animate

* fix: support width/height animations

* fix: jumping on subsequent animations

* fix: segfault race condition

* fix: remove layer background

* fix: layer clips not being reset

* refactor: use gfx tween gin converter

* fix: layer cleanups causing flickering views

* chore: merge artifact

* fix: missing private method in header

* fix: return type

* fix: do not set layer opacity

* refactor: update animate parameter format

* refactor: move animate into options object

* chore: typo

* docs: update

* spec: add view animation test
2026-01-30 15:18:56 -05:00
Shelley Vohr
331d1e16f5 refactor: address PathProvider TODO (#49563) 2026-01-30 14:16:39 -05:00
Shelley Vohr
6825a522e9 fix: duplicate fullscreen macOS menu item (#49074) 2026-01-30 13:23:43 -05:00
Shelley Vohr
e033c10075 fix: issues with xdg activation on Linux (#49499) 2026-01-30 10:53:04 -05:00
Shelley Vohr
64872a6cb8 fix: macOS menu item accelerators when item disabled (#49553)
fix: macOS menu item acceerators when item disabled
2026-01-30 10:07:16 +01:00
Jan Hannemann
d74fcfcecb feat: msix auto-updater (#49230)
* feat: native auto updater for MSIX on Windows

* doc: added MSIX debug documentation

* fix: allow downgrade with json release file and emit update-available

* test: msix auot-update tests

* doc: API documentation

* test: add package version validation

* fix: docs typo

* fix: don't allow auto-updating when using appinstaller manifest

* fix: getPackageInfo interface implementation

* fix: review feedback, add comment

* fix: missed filename commit

* fix: install test cert on demand

* fix: time stamp mismatch in tests

* fix: feedback - rename to MSIXPackageInfo

* fix: update and reference windowsStore property

* fix: remove getPackagInfo from public API

* fix: type error bcause of removed API
2026-01-29 16:38:26 -05:00
Michaela Laurencin
92a3f7d6c1 ci: add workflow for commenting with new 'ai-pr' label (#49564)
* add workflow for commenting with new 'ai-pr' label

* Update .github/workflows/pull-request-labeled.yml

Co-authored-by: David Sanders <dsanders11@ucsbalum.com>

* add pr autoclose

* replace with specific secret

Co-authored-by: David Sanders <dsanders11@ucsbalum.com>

* specify repo

Co-authored-by: David Sanders <dsanders11@ucsbalum.com>

* update wording of comment

* chore: use GH app token

* chore: fix indentation

---------

Co-authored-by: David Sanders <dsanders11@ucsbalum.com>
2026-01-29 13:12:42 -05:00
David Sanders
0e161c18eb ci: rework reapply patches (#49552) 2026-01-29 11:19:07 -05:00
David Sanders
3d76d3a469 build(dev-deps): bump @electron/lint-roller to 3.2.0 (#49565) 2026-01-29 16:06:47 +01:00
Kanishk Ranjan
82d350524e test: fix flaky BrowserView test (#49316)
* test: fix flaky BrowserWindow test

* fix: improved as per review
2026-01-28 11:54:35 -08:00
Shelley Vohr
e6be04a7a0 fix: chrome://accessibility drift (#49547)
https://chromium-review.googlesource.com/c/chromium/src/+/6870052
2026-01-28 12:07:14 +01:00
David Sanders
a7de47084b test: remove split dependency (#49551) 2026-01-28 10:47:43 +01:00
Kanishk Ranjan
3820d3ae6c test: fix flaky BrowserWindow test (#49364)
test: fix flaky BrowserWindow test
2026-01-27 21:47:02 -08:00
Charles Kerr
8364b62f68 fix: potential dangling pointer in api::Screen (#49536)
fixes a regression from #49506
2026-01-27 16:27:38 -05:00
dependabot[bot]
441729c3a0 build(deps): bump actions/checkout from 6.0.1 to 6.0.2 (#49541)
Bumps [actions/checkout](https://github.com/actions/checkout) from 6.0.1 to 6.0.2.
- [Release notes](https://github.com/actions/checkout/releases)
- [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md)
- [Commits](8e8c483db8...de0fac2e45)

---
updated-dependencies:
- dependency-name: actions/checkout
  dependency-version: 6.0.2
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-01-27 11:37:15 +01:00
Shelley Vohr
c521c2b868 test: update/fix Node.js disabled specs (#49467) 2026-01-27 11:03:09 +01:00
Shelley Vohr
b2c5093542 docs: correct type for process.noDeprecation (#49524)
* docs: correct type for process.noDeprecation

* docs: mark `noDeprecation` as optional instead

Co-authored-by: René <contact.9a5d6388@renegade334.me.uk>

---------

Co-authored-by: David Sanders <dsanders11@ucsbalum.com>
Co-authored-by: René <contact.9a5d6388@renegade334.me.uk>
2026-01-27 11:02:51 +01:00
dependabot[bot]
ec5eb64788 build(deps): bump github/codeql-action from 4.31.10 to 4.32.0 (#49540)
Bumps [github/codeql-action](https://github.com/github/codeql-action) from 4.31.10 to 4.32.0.
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](cdefb33c0f...b20883b0cd)

---
updated-dependencies:
- dependency-name: github/codeql-action
  dependency-version: 4.32.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-01-27 11:00:13 +01:00
David Sanders
0cc15a6386 ci: reapply patches if PR base branch updates them (#49516) 2026-01-26 15:13:34 -05:00
David Sanders
4aa89b9c3c ci: add pipeline segment to run clang-tidy (#49072)
* ci: add pipeline segment to run clang-tidy

* chore: set -header-filter='' for clang-tidy

Breaking change in `clang-tidy` 22.0.0:

> clang-tidy now displays warnings from all non-system headers by default.
> Previously, users had to explicitly opt-in to header warnings using
> -header-filter=’.*’. To disable warnings from non-system, set
> -header-filter to an empty string.
2026-01-26 14:37:01 -05:00
Felix Rieseberg
ae43f17b79 build: Run gh workflows only on e/e (#49521) 2026-01-26 14:35:11 -05:00
electron-roller[bot]
b847299f19 chore: bump chromium to 146.0.7650.0 (main) (#49496)
* chore: bump chromium in DEPS to 146.0.7650.0

* 7496671: WaaP: Control hung delay for Initial WebUI

Refs https://chromium-review.googlesource.com/c/chromium/src/+/7496671

* 7494302: [//media] Rename renderable_gpu_memory_buffer_video_frame_pool*

Refs https://chromium-review.googlesource.com/c/chromium/src/+/7494302

* chore: update patches

* 7502996: [DevTools] Add ability to toggle Chromium feature flags from DevTools

Refs https://chromium-review.googlesource.com/c/chromium/src/+/7502996

* 7456200: Vectorize StringImpl::CopyChars and EqualIgnoringASCIICase using Highway.

Refs https://chromium-review.googlesource.com/c/chromium/src/+/7456200

* 7236627: spellcheck: supply full spelling marker info, incld. marker type

Refs https://chromium-review.googlesource.com/c/chromium/src/+/7236627

* chore: rm dependency on wtf::string from blink public headers

Refs https://chromium-review.googlesource.com/c/chromium/src/+/7456200
added a public dependency on //third_party/highway for
//third_party/blink/renderer/platform/wtf:wtf which will not be
inherited by //content/renderer since wtf is internal dependency of
blink leading to the following compilation error

```
In file included from ../../content/public/renderer/window_features_converter.cc:5:
In file included from ../../content/public/renderer/window_features_converter.h:10:
In file included from ../../third_party/blink/public/web/web_window_features.h:38:
In file included from ../../third_party/blink/renderer/platform/wtf/text/wtf_string.h:40:
../../third_party/blink/renderer/platform/wtf/text/string_impl.h:27:10: fatal error: 'hwy/highway.h' file not found
   27 | #include <hwy/highway.h>
      |          ^~~~~~~~~~~~~~~
1 error generated.
```

Use `gn desc out/Testing content/renderer:renderer_sources --blame`
to verify the inherited config and dependency list.

* 7493995: Restore directive part of wasm-eval error message

Refs https://chromium-review.googlesource.com/c/chromium/src/+/7493995

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: David Sanders <dsanders11@ucsbalum.com>
Co-authored-by: deepak1556 <hop2deep@gmail.com>
2026-01-26 11:18:09 -08:00
Charles Kerr
6766343173 refactor: simplify NativeWindow-to-BaseWindow lookup (#49520)
refactor: simplify native window to base window lookup
2026-01-26 12:28:57 +01:00
Sourav Bera
75be2fe8d6 docs: add type reference links in Menu and MenuItem API documentation (#49437)
* docs: add type reference links in Menu and MenuItem API documentation

* docs: revert type links in Menu return types to fix parser
2026-01-26 12:22:28 +01:00
Charles Kerr
30f365d9d8 refactor: use gin::Wrappable for electron::api::PowerMonitor (#49509)
* refactor: use `gin::Wrappable` for `electron::api::PowerMonitor`

* chore: update patches
2026-01-25 22:51:31 -06:00
Charles Kerr
e8250f9955 refactor: use gin::Wrappable for electron::api::Screen (#49506) 2026-01-25 13:46:25 -06:00
Kyle Cutler
d5de8883a2 feat: add focusOnNavigation flag to WebPreferences (#49425)
* feat: add focusOnNavigation webPreference

* WebContentsView tests

* fix

* fix
2026-01-23 14:29:34 -05:00
David Franco
8a11d5afb1 fix: avoid startup crash when V8 sandbox is disabled (#49210)
* fix: avoid startup crash when V8 sandbox is disabled

* chore: update patch

---------

Co-authored-by: David Franco <davidfrsan@gmail.com>
2026-01-23 11:49:15 -05:00
Shelley Vohr
89963618d9 fix: second argument to shell.writeShortcutLink is optional (#49476)
fix: second argument to shell.writeShortcutLink is optional
2026-01-23 11:24:47 -05:00
Charles Kerr
8c5c6a6088 refactor: use gin::Wrappable for electron::api::DataPipeHolder (#49495)
* refactor: make `DataPipeHolder` inherit from `gin::Wrappable`

* test: add a test to ensure GC clears the data pipe holder

* chore: e patches all

* chore: e patches all (trivial only)

* refactor: make AllDataPipeHolders a base::flat_map of WeakPersistent
2026-01-23 20:29:01 +09:00
Szymon Kurek
24526ccd39 docs: correct yarn part of tutorial-5-packaging (#49401)
docs: fix yarn part of `tutorial-5-packaging` - adding electron forge
2026-01-23 11:14:19 +01:00
Keeley Hammond
1134d95c6d chore: update main patches (#49498)
chore: update patches
2026-01-22 20:30:32 -08:00
Charles Kerr
d76608b945 refactor: use gin::Wrappable in electron::api::PowerSaveBlocker (#49381)
* refactor: PowerSaveBlocker subclasses gin::Wrappable

* chore: update chore_add_electron_objects_to_wrappablepointertag.patch

* chore: e patches all
2026-01-22 17:31:38 -06:00
electron-roller[bot]
d689f76ff9 chore: bump chromium to 146.0.7645.0 (main) (#49453)
* chore: bump chromium in DEPS to 146.0.7643.0

* chore: bump chromium in DEPS to 146.0.7645.0

* chore: update patches

* 7402162: Refactor app shims to call ContentMain

Refs https://chromium-review.googlesource.com/c/chromium/src/+/7402162

* 7454282: Add master key management for HTTP Cache Encryption

Refs https://chromium-review.googlesource.com/c/chromium/src/+/7454282

* 7490440: Reland "Delete unused base::Contains()"

Refs https://chromium-review.googlesource.com/c/chromium/src/+/7490440

* chore: update patches

* 7414864: Pass CSSParserLocalContext down to CSSMathExpressionNodeParser

Refs https://chromium-review.googlesource.com/c/chromium/src/+/7414864

* 7460969: Move child_process_id.h to common

Refs https://chromium-review.googlesource.com/c/chromium/src/+/7460969

* 7474608: [api] Remove deprecated v8::PropertyCallbackInfo<T>::This()

Refs https://chromium-review.googlesource.com/c/v8/v8/+/7474608

* 7461067: [Viz] Rename kPreferGpuMemoryBuffer

Refs https://chromium-review.googlesource.com/c/chromium/src/+/7461067

* 7487174: Remove GLHelper

Refs https://chromium-review.googlesource.com/c/chromium/src/+/7487174

* 7457538: Set timeout from multi source page context fetcher

Refs https://chromium-review.googlesource.com/c/chromium/src/+/7457538

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: David Sanders <dsanders11@ucsbalum.com>
2026-01-22 17:01:09 -05:00
reito
e3142865b2 fix: offscreen rendering with correct screen info. (#48730)
fix: osr use correct screen info.
2026-01-22 14:58:54 -05:00
David Sanders
1f8e4079cd test: fix version color output when running prebuilt Electron (#49491) 2026-01-22 16:17:56 +01:00
Shelley Vohr
bad88c6ed4 fix: potential devtools crash on empty (#49468) 2026-01-21 17:05:26 -08:00
Noah Gregory
534cb33465 fix: return early from platform_util::Beep() on Linux if there is no default GDK display (#49442)
fix: return early from beep on linux if there is no default gdk display
2026-01-21 15:55:24 -05:00
Soobin Rho
51e7753ae9 docs: clearer wording performance common pitfalls (#45308)
docs: clearer wording (performance common pitfalls)

Signed-off-by: Soobin Rho <soobinrho@gmail.com>
2026-01-21 14:46:02 -05:00
sam marshall
d141934885 docs: document that shell.trashItem requires backslashes (#49038)
docs: Update shell.md: Document that shell.trashItem requires backslashes

In Windows many functions relating to files (e.g. shell.openItem, the Node fs functions, as well as native Win32 APIs) will accept either type of slash / or \ as a folder separator.

shell.trashItem does not work with / as folder separator in Windows. This documentation change explains that.

See also:
https://github.com/electron/electron/issues/28831
2026-01-21 13:21:01 -05:00
Erick Zhao
22e8cf9416 docs: add a few API history fragments (#49340)
* docs: add a few API history fragments

* manual fixes
2026-01-21 12:57:02 -05:00
David Sanders
5856b2e01c ci: trigger website docs update on release published (#49429) 2026-01-21 10:44:18 -05:00
Shelley Vohr
49d91dd02b revert: use deprecated setAllowedFileTypes in macOS dialogs (#49444)
* revert: use deprectated setAllowedFileTypes in macOS dialogs

Closes https://github.com/electron/electron/issues/48191

* chore: remove stray import
2026-01-21 13:08:04 +01:00
David Franco
2f20d287d1 feat: import shared texture supports p010le (#49272)
feat: import shared texture supports p010le.
2026-01-20 11:50:30 +01:00
Shelley Vohr
73377af79e build: try removing zero-fill sandbox patch component (#49452) 2026-01-20 09:40:33 +01:00
dependabot[bot]
47766801e4 build(deps): bump actions/setup-node from 6.1.0 to 6.2.0 (#49456)
Bumps [actions/setup-node](https://github.com/actions/setup-node) from 6.1.0 to 6.2.0.
- [Release notes](https://github.com/actions/setup-node/releases)
- [Commits](395ad32622...6044e13b5d)

---
updated-dependencies:
- dependency-name: actions/setup-node
  dependency-version: 6.2.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-01-20 09:40:02 +01:00
dependabot[bot]
bf0510dc22 build(deps): bump electron/github-app-auth-action from 1.1.1 to 2.0.0 (#49457)
Bumps [electron/github-app-auth-action](https://github.com/electron/github-app-auth-action) from 1.1.1 to 2.0.0.
- [Release notes](https://github.com/electron/github-app-auth-action/releases)
- [Commits](384fd19694...e14e47722e)

---
updated-dependencies:
- dependency-name: electron/github-app-auth-action
  dependency-version: 2.0.0
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-01-20 09:39:47 +01:00
electron-roller[bot]
486a9a61d2 chore: bump chromium to 146.0.7635.0 (main) (#49408)
* chore: bump chromium in DEPS to 146.0.7635.0

* chore: update patch hunk headers

* 7078551: [wasm] Refactor caching API

https://chromium-review.googlesource.com/c/v8/v8/+/7078551

* 7141498: [api] Remove unused context parameter from FixedArray::Get

https://chromium-review.googlesource.com/c/v8/v8/+/7141498

* 7454865: Add timeouts to content API for CopyFromSurface

https://chromium-review.googlesource.com/c/chromium/src/+/7454865

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
2026-01-19 15:37:02 +01:00
Niklas Wenzel
7851a34c2d docs: fix webContents.hostWebContents types (#49424) 2026-01-19 10:45:23 +01:00
Shelley Vohr
faa21a748f fix: MAS rejection for private APIs (#49391) 2026-01-18 10:34:16 +01:00
Shelley Vohr
5bd2938f6a fix: try clearing InspectableWebContents delegate earlier (#49406)
fix: try clearing InspectableWebContents delegate earlier
2026-01-16 21:36:34 +01:00
electron-roller[bot]
f149efe32e chore: bump node to v24.13.0 (main) (#49189)
* chore: bump node in DEPS to v24.12.0

* src: use CP_UTF8 for wide file names on win32

https://github.com/nodejs/node/pull/60575

* test,crypto: handle a few more BoringSSL tests

https://github.com/nodejs/node/pull/59030

* chore: fixup patch indices

* chore: re-add accidentally removed sslv23 test

* chore: fixup crypto patch rebase

* test: make buffer sizes 32bit-aware in test-internal-util-construct-sab

https://github.com/nodejs/node/pull/61026

* src: add internal binding for constructing SharedArrayBuffers

https://github.com/nodejs/node/pull/60497

* chore: bump node in DEPS to v24.13.0

* chore: fixup patch indices

* chore: fixup sandboxed pointers patch

* tls: route callback exceptions through error handlers

https://github.com/nodejs-private/node-private/pull/782

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
2026-01-16 11:08:38 -05:00
Daniel Gräfe
5dd509d2f4 fix: restore AXDocument accessibility attribute for representedFilename on macOS (#49346)
Starting from Chromium 134.0.6989.0 (Electron 35.0.0-beta.5), the
NativeWidgetMacNSWindow class overrides accessibilityDocument to return
the web content URL from the accessibility tree, but doesn't fall back
to NSWindow's default behavior when that URL is empty.

This broke Electron's setRepresentedFilename() API - the file path was
still set on the NSWindow, but no longer exposed via the AXDocument
accessibility attribute that screen readers use.

This fix adds an accessibilityDocument override in ElectronNSWindow that
checks representedFilename first, falling back to Chromium's behavior
for web content URLs.

Fixes: https://github.com/electron/electron/issues/XXXXX

Co-authored-by: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-16 10:27:29 +01:00
Alex Schwartz
bdd7730a24 fix: make toplevel icon Wayland protocol work (#49290) 2026-01-16 09:55:52 +01:00
dependabot[bot]
060e76f1b6 build(deps): bump actions/upload-artifact from 5.0.0 to 6.0.0 (#49220)
Bumps [actions/upload-artifact](https://github.com/actions/upload-artifact) from 5.0.0 to 6.0.0.
- [Release notes](https://github.com/actions/upload-artifact/releases)
- [Commits](330a01c490...b7c566a772)

---
updated-dependencies:
- dependency-name: actions/upload-artifact
  dependency-version: 6.0.0
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-01-16 09:55:38 +01:00
David Sanders
2fbf1f5c72 ci: detect patch needs update error with problem matcher (#49405) 2026-01-15 19:18:50 -08:00
Charles Kerr
c769361af2 fix: warning: default arguments on virtual or override methods (#49398)
fix: warning: default arguments on virtual or override methods are prohibited [google-default-arguments]

we never override these, so just make them nonvirtual
2026-01-15 16:09:43 -08:00
electron-roller[bot]
6ea7d6d5a4 chore: bump chromium to 146.0.7633.0 (main) (#49390)
* chore: bump chromium in DEPS to 146.0.7633.0

* chore: fixup patch indices

* chore: fix unsafe buffer usage in browser_linux.cc

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
2026-01-15 10:52:42 -05:00
Charles Kerr
27b3a32307 chore: update patches (#49399) 2026-01-14 22:33:23 -08:00
Charles Kerr
ddeb970f18 refactor: make ReplyChannel inherit from gin::Wrappable (#49339)
* refactor: make ReplyChannel inherit from gin::Wrappable

* chore: add kElectronReplyChannel to chore_add_electron_objects_to_wrappablepointertag.patch

* fix: use gin::PerIsolateData::DisposeObserver

* fix: lifetime issues

* chore: rm perisolatedata hook in favor of prefinalizer

---------

Co-authored-by: deepak1556 <hop2deep@gmail.com>
2026-01-14 18:35:01 -06:00
electron-roller[bot]
5d80264944 chore: bump chromium to 145.0.7628.0 (main) (#49331)
* chore: bump chromium in DEPS to 145.0.7620.0

* chore: bump chromium in DEPS to 145.0.7622.0

* chore: bump chromium in DEPS to 145.0.7624.0

* chore: bump chromium in DEPS to 145.0.7626.0

* chore: bump chromium in DEPS to 145.0.7628.0

* 7362759: Migrate various base::Contains() to contains() in ui | https://chromium-review.googlesource.com/c/chromium/src/+/7362759

* chore: update patches

* 7411324: url: Mark deprecated functions as UNSAFE_BUFFER_USAGE

https://chromium-review.googlesource.com/c/chromium/src/+/7411324

* 7366867: Store property info in CSSParserLocalContext for random()

https://chromium-review.googlesource.com/c/chromium/src/+/7366867

* 7277406: Exclude PiP from getDisplayMedia picker thumbnails

https://chromium-review.googlesource.com/c/chromium/src/+/7277406

* 7253489: activity_reporter: Create stub module owned by browser_process

https://chromium-review.googlesource.com/c/chromium/src/+/7253489

* 7404514: Create device parental controls delegate

https://chromium-review.googlesource.com/c/chromium/src/+/7404514

* 7269504: Update histograms to use the updated MediaStreamRequestResult enum

https://chromium-review.googlesource.com/c/chromium/src/+/7269504

* fixup! 7253489: activity_reporter: Create stub module owned by browser_process

* 7368549: Reland "Use native rollup"

https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/7368549

* 4803165: Enable suppressing input event dispatch while paint-holding.

https://chromium-review.googlesource.com/c/chromium/src/+/4803165

* chore: make device_parental_controls lazy

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: Keeley Hammond <khammond@slack-corp.com>
Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
2026-01-14 15:34:24 +01:00
Erick Zhao
dae76c2885 docs: remove stale example and standardize DevTools capitalization (#49321)
* docs: remove stale example and standardize `DevTools` capitalization

* Update docs/api/web-contents.md

Co-authored-by: Kilian Valkhof <kilian@kilianvalkhof.com>

---------

Co-authored-by: Kilian Valkhof <kilian@kilianvalkhof.com>
2026-01-14 10:35:53 +01:00
Erick Zhao
a368c5da0c docs: improve build-tools instructions (#49294)
* docs: improve build-tools instructions

* address comments

* update directory structure

* update

* nits

* node -> electron_node

* update macos build version

* Update docs/development/build-instructions-gn.md

Co-authored-by: David Sanders <dsanders11@ucsbalum.com>

---------

Co-authored-by: David Sanders <dsanders11@ucsbalum.com>
2026-01-14 09:51:55 +01:00
Keeley Hammond
1b2679b315 fix: revert os_crypt async cookie provider implementation (#49382)
* Revert "fix: provide explicit cookie encryption provider for cookie encryption (#49348)"

This reverts commit 95f097a392.

* Revert "fix: fix cookie encryption provider loading on Windows and Linux (#49371)"

This reverts commit 0e4ee9f03a.

* revert: 6996667: Reland "Port net::CookieCryptoDelegate to os_crypt async" | https://chromium-review.googlesource.com/c/chromium/src/+/6996667
2026-01-14 09:34:00 +01:00
Shelley Vohr
15acf70760 build: roll build-image to a82b87d (#49377)
build: roll build-image to a82b87d
2026-01-13 12:13:14 +01:00
dependabot[bot]
324eb0eb1c build(deps): bump github/codeql-action from 4.31.7 to 4.31.10 (#49376)
Bumps [github/codeql-action](https://github.com/github/codeql-action) from 4.31.7 to 4.31.10.
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](cf1bb45a27...cdefb33c0f)

---
updated-dependencies:
- dependency-name: github/codeql-action
  dependency-version: 4.31.10
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-01-13 10:25:10 +01:00
Keeley Hammond
0e4ee9f03a fix: fix cookie encryption provider loading on Windows and Linux (#49371)
* fix: support cookie encryption provider cross-platform

* fix: add async macos key provider
2026-01-12 19:39:29 -08:00
Charles Kerr
ae94cefdba refactor: add static ReplyChannel::SendError() helper (#49338)
* refactor: add static void ReplyChannel::SendError()

* refactor: use static SendError() instead of instantiating a temporary

* refactor: remove non-static version of SendError()

* refactor: remove redundant callback-is-non-null checks
2026-01-12 17:02:58 -06:00
Shelley Vohr
409c29b12b build: roll build-tools SHA to 4430e4a (#49362)
build: roll build-tools SHA to 4430e4a
2026-01-12 12:22:30 -05:00
Shelley Vohr
b0e012f14e build: update on-create-command for siso (#49357) 2026-01-12 14:30:48 +01:00
Calvin
9a5ffd920c feat: suppress devtools console logging (#49292)
* feat: suppress devtools console logging

* Emit messages as-is in testing builds

* Promote `DCHECK_IS_ON()` to preprocessor check
2026-01-12 11:31:33 +01:00
Charles Kerr
cf2e283332 fix: clang-tidy warnings, pt. 1 (#49083)
* fix: google-readability-casting warning about the uint32_t cast

* fix: modernize-use-equals-default warnings

* fix: readability-redundant-member-init warning

* fix: modernize-make-unique warnings

* fix: modernize-use-emplace

warning: use emplace_back instead of push_back

* refactor: address code review feedback
2026-01-09 22:57:38 -08:00
Niklas Wenzel
d6a6312fc8 build: update NMV to 145 (#49349) 2026-01-09 18:14:18 -08:00
Keeley Hammond
95f097a392 fix: provide explicit cookie encryption provider for cookie encryption (#49348)
fix: provide explicit cookie encryption provider

Fixes 6996667: Reland "Port net::CookieCryptoDelegate to os_crypt async" | https://chromium-review.googlesource.com/c/chromium/src/+/6996667
2026-01-09 11:53:58 -08:00
Niklas Wenzel
b380755514 chore: remove stakeholders mention from PR template (#49317) 2026-01-09 00:36:40 -08:00
David Sanders
3985daa81c chore: improvements to script/run-clang-tidy.ts (#49335)
* chore: disable color output for clang-tidy in CI

* chore: small QoL improvements to run-clang-tidy.ts

* chore: add --fix option to script/run-clang-tidy.ts
2026-01-08 22:05:44 -08:00
Erick Zhao
5901d8a6d8 docs: document ELECTRON_SKIP_BINARY_DOWNLOAD (#49320) 2026-01-07 14:54:22 -08:00
electron-roller[bot]
eee60f202c chore: bump chromium to 145.0.7618.0 (main) (#49314)
* chore: bump chromium in DEPS to 145.0.7618.0

* 7399531: [GTK] Don't preselect file dialog accept buttons | https://chromium-review.googlesource.com/c/chromium/src/+/7399531

* chore: update patches

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: Keeley Hammond <khammond@slack-corp.com>
2026-01-07 15:01:56 -05:00
Charles Kerr
b5a7d81c7d refactor: have GetXdgAppId() return a std::optional<std::string> (#49318)
* refactor: GetXdgAppId() now returns std::optional<std::string>

* refactor: slightly simplify app.setDesktopName() ts calls

* refactor: add better documentation for dekstop-entry in XDG notifications
2026-01-07 14:30:09 -05:00
dependabot[bot]
a89b2cd9bc build(deps): bump actions/download-artifact from 6.0.0 to 7.0.0 (#49221)
Bumps [actions/download-artifact](https://github.com/actions/download-artifact) from 6.0.0 to 7.0.0.
- [Release notes](https://github.com/actions/download-artifact/releases)
- [Commits](018cc2cf5b...37930b1c2a)

---
updated-dependencies:
- dependency-name: actions/download-artifact
  dependency-version: 7.0.0
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-01-06 15:48:38 -05:00
Niklas Wenzel
44fa30695f docs: update roundedCorners documentation (#49195) 2026-01-05 16:27:46 -05:00
Niklas Wenzel
2ab56adbbd test: remove outdated disabled test (#49196) 2026-01-05 16:27:01 -05:00
electron-roller[bot]
a1f0ef80d4 chore: bump chromium to 145.0.7616.0 (main) (#49279)
* chore: bump chromium in DEPS to 145.0.7605.0

* chore: bump chromium in DEPS to 145.0.7606.0

* chore: bump chromium in DEPS to 145.0.7608.0

* chore: update patches

* chore: bump chromium in DEPS to 145.0.7610.0

* chore: update patches

* [InputVizard] Fix missing touch cancel in InputTransferHandlerAndroid
using InputEventSource

Refs https://chromium-review.googlesource.com/c/chromium/src/+/7302368

* chore: bump chromium in DEPS to 145.0.7611.0

* chore: update patches

* chore: bump chromium in DEPS to 145.0.7614.0

* chore: bump chromium in DEPS to 145.0.7615.0

* chore: update patches

* chore: bump chromium in DEPS to 145.0.7616.0

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: deepak1556 <hop2deep@gmail.com>
2026-01-05 13:34:36 -05:00
dependabot[bot]
c1a031be83 build(deps): bump actions-cool/issues-helper from 3.7.3 to 3.7.5 (#49282)
Bumps [actions-cool/issues-helper](https://github.com/actions-cool/issues-helper) from 3.7.3 to 3.7.5.
- [Release notes](https://github.com/actions-cool/issues-helper/releases)
- [Changelog](https://github.com/actions-cool/issues-helper/blob/main/CHANGELOG.md)
- [Commits](3809910bc1...e2ff99831a)

---
updated-dependencies:
- dependency-name: actions-cool/issues-helper
  dependency-version: 3.7.5
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-01-05 12:26:03 -05:00
John Kleinschmidt
c8bb700509 build: fixup release notes generation (#49302) 2026-01-05 11:11:40 -05:00
Calvin
46922de638 fix: drag regions in child windows (#49231)
* fix: drag regions in child windows

* Update comments
2026-01-05 10:34:01 -05:00
Niklas Wenzel
75ea93a279 chore: remove quiet period mention from PR template (#49298) 2026-01-05 10:12:07 -05:00
John Kleinschmidt
ace0beaa3f build: add logging to notes generator (#49300) 2026-01-05 09:49:51 -05:00
electron-roller[bot]
9eb43f3286 chore: bump chromium to 145.0.7604.0 (main) (#49265)
* chore: bump chromium in DEPS to 145.0.7599.0

* chore: bump chromium in DEPS to 145.0.7600.0

* chore: bump chromium in DEPS to 145.0.7602.0

* chore: bump chromium in DEPS to 145.0.7604.0

* chore: update patches (trivial only)

* [bytesize] Migrate network data in Task Manager to ByteSize.

Xref: https://chromium-review.googlesource.com/c/chromium/src/+/7266090

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: Charles Kerr <charles@charleskerr.com>
2025-12-28 20:40:50 -08:00
electron-roller[bot]
809ab09b6f chore: bump chromium to 145.0.7596.0 (main) (#49224)
* chore: bump chromium in DEPS to 145.0.7588.0

* fix(patch-conflict): update scroll_bounce_flag for split overscroll methods

Chromium split IsElasticOverscrollEnabled() into two methods:
IsElasticOverscrollEnabledOnRoot() and IsElasticOverscrollSupported().
Updated patch to apply the scroll-bounce command-line switch to both
methods.

Ref: https://chromium-review.googlesource.com/c/chromium/src/+/7233733

* fix(patch-conflict): update exclusive_access patch context

Upstream refactored the profile variable declaration. Updated patch to
match new surrounding context with brace-style if statement.

Ref: https://chromium-review.googlesource.com/c/chromium/src/+/7239252

* fix(patch-conflict): update screen capture kit non-shareable filter

Upstream refactored PiP window exclusion to use GetWindowsToExclude()
helper function. Updated patch to combine non-shareable window filtering
with the new helper's output.

Ref: https://chromium-review.googlesource.com/c/chromium/src/+/7274596

* fix(patch-conflict): update corner smoothing CSS property id position

Upstream added new internal overscroll CSS properties. Updated patch to
add kElectronCornerSmoothing after the new entries.

Ref: https://chromium-review.googlesource.com/c/chromium/src/+/7234051

* fix(patch-conflict): update permission patches for new permission types

Upstream added new permission types: LOCAL_NETWORK, LOOPBACK_NETWORK,
and GEOLOCATION_APPROXIMATE. Updated Electron permission patches to
include these new types and renumber Electron-specific permissions.

Ref: https://chromium-review.googlesource.com/c/chromium/src/+/7231952

* fix(patch-conflict): update memory query fallback for new function signature

Upstream added AmountOfTotalPhysicalMemory() with PCHECK. Updated patch
to maintain fallback logic with correct ByteSize return type.

Ref: https://chromium-review.googlesource.com/c/chromium/src/+/7254886

* chore: update patch hunk headers

* fix(patch): update reclient-configs patch to use new file mode

The fix_add_python_remote_wrapper patch was using 'copy from' mode
which caused inconsistent behavior between local and CI git versions.
Changed to 'new file' mode for consistent patch application.

* fix(patch-conflict): remove duplicate GEOLOCATION_APPROXIMATE case

Upstream moved GEOLOCATION_APPROXIMATE earlier in the switch statement
in GetPermissionString(). The 3-way merge kept both the old and new
positions, causing a duplicate case error.

Ref: https://chromium-review.googlesource.com/c/chromium/src/+/6397637

* chore: update libcxx filenames for new headers

* chore: bump chromium in DEPS to 145.0.7590.0

* chore: update patch hunk headers

* fix(patch): update memory fallback return type to ByteSize

Upstream changed the return type from ByteCount to ByteSize.

* fix: suppress nodiscard warning in node_file.cc

libc++ added [[nodiscard]] to std::filesystem::copy_options operator|=
which causes build failures with -Werror.

* 7229082: update CopyFromSurface to use CopyFromSurfaceResult

Upstream changed CopyFromSurface callback to return
base::expected<viz::CopyOutputBitmapWithMetadata, std::string>
instead of SkBitmap, enabling better error handling.

Ref: https://chromium-review.googlesource.com/c/chromium/src/+/7229082

* 7254070: add ip_address_space param to OnLocalNetworkAccessPermissionRequired

Upstream added IPAddressSpace parameter to check address space for
proper permission handling in Local Network Access.

Ref: https://chromium-review.googlesource.com/c/chromium/src/+/7254070

* 7136679: add spelling_markers param to RequestCheckingOfText

Upstream added spelling_markers parameter to report misspelling
ranges from Blink to Spellcheck to IME.

Ref: https://chromium-review.googlesource.com/c/chromium/src/+/7136679

* 7240487: remove second param from RegisterWebSafeIsolatedScheme

Upstream removed the schemes_okay_to_appear_as_origin_headers_ parameter.

Ref: https://chromium-review.googlesource.com/c/chromium/src/+/7240487

* 7254577: use explicit WebElement constructor

WebElement default constructor now requires explicit construction
rather than brace initialization.

Ref: https://chromium-review.googlesource.com/c/chromium/src/+/7254577

* 7256335: remove override from CreateGlobalFeaturesForTesting

Upstream removed BrowserProcess::CreateGlobalFeaturesForTesting virtual
method so the override specifier is no longer valid.

Ref: https://chromium-review.googlesource.com/c/chromium/src/+/7256335

* chore: add missing SingleThreadTaskRunner include

A transitive include of SingleThreadTaskRunner was removed upstream,
requiring an explicit include.

Ref: Unable to locate specific CL (transitive include change)

* 7260483: add LOCAL_NETWORK, LOOPBACK_NETWORK permission type cases

Upstream added new permission types for Local Network Access split
permissions.

Ref: https://chromium-review.googlesource.com/c/chromium/src/+/7260483

* chore: update patch hunk headers

* 7264893: update postMessage tests for file: origin serialization change

Chromium now serializes file: origins as 'null' in MessageEvent per spec.
This is a security improvement aligning with the HTML spec behavior.

Ref: https://chromium-review.googlesource.com/c/chromium/src/+/7264893

* fix: add paths to custom scheme URLs in protocol tests

Custom scheme URLs without paths (e.g. test-scheme://foo) cause a
DCHECK crash in ASAN builds when CorsURLLoader tries to log the
request via GenerateRequestLine -> PathForRequest, which asserts
that the path is non-empty.

Adding trailing slashes ensures URLs have valid paths.

* chore: bump chromium in DEPS to 145.0.7592.0

* chore: update patches (trivial only)

* chore: bump chromium in DEPS to 145.0.7594.0

* chore: bump chromium in DEPS to 145.0.7596.0

* chore: update accelerator.patch

no manual changes; patch applied with fuzz 2 (offset 1 line)

* chore: update patches (trivial only)

* chore: node ./script/gen-libc++-filenames.js

---------

Co-authored-by: Alice Zhao <alicelovescake@anthropic.com>
Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: Charles Kerr <charles@charleskerr.com>
2025-12-25 17:15:53 -06:00
Samuel Attard
3df3a6a736 fix: webRequest.onBeforeSendHeaders not being able to modify reserved headers (#49226)
* fix: `webRequest.onBeforeSendHeaders` not being able to modify reserved headers

* chore: add unit test for reserved header
2025-12-19 23:08:40 +13:00
Samuel Attard
7433c14af5 chore: add CLAUDE.md and Chromium Upgrade claude skill (#49229)
* chore: add CLAUDE.md and Chromium Upgrade claude skill

* Update script/lint.js

Co-authored-by: David Sanders <dsanders11@ucsbalum.com>

---------

Co-authored-by: David Sanders <dsanders11@ucsbalum.com>
2025-12-19 13:07:58 +13:00
electron-roller[bot]
a90ccc753b chore: bump chromium to 145.0.7577.0 (main) (#49175)
* chore: bump chromium in DEPS to 145.0.7572.0

* chore: update patches (trivial only)

* chore(patch-conflict): feat_filter_out_non-shareable_windows_in_the_current_application_in.patch

Polished the edits and formatted the result. No real changes.

Ref: https://chromium-review.googlesource.com/c/chromium/src/+/7232079 "7232079: Use WindowsToExclude to exclude PiP window in macOS screencapture device"

* chore(patch-conflict): feat_add_support_for_missing_dialog_features_to_shell_dialogs.patch

Ref: https://chromium-review.googlesource.com/c/chromium/src/+/7214586 "7214586: Refactor SelectFileDialogLinuxPortal to request XDG portal on demand"
Ref: https://chromium-review.googlesource.com/c/chromium/src/+/7237910 "7237910: Remove g_gtk_ui global"

* 7228586: Migrate SystemMemoryInfo from ByteCount to ByteSize

Ref: https://chromium-review.googlesource.com/c/chromium/src/+/7228586

* 7207583: GlobalRenderFrameHostId to ChildProcessId

Ref: https://chromium-review.googlesource.com/c/chromium/src/+/7207583

* 7205548: Remove uses of BodyAsStringCallbackDeprecated (extensions/)

Ref: https://chromium-review.googlesource.com/c/chromium/src/+/7205548

* chore: bump chromium in DEPS to 145.0.7574.0

* chore: update libc++ filenames

* chore: update patches (trivial only)

* chore(patch-conflict): feat_filter_out_non-shareable_windows_in_the_current_application_in.patch

Ref: https://chromium-review.googlesource.com/c/chromium/src/+/7246150 "7246150: Fix crash in ScreenCaptureKitDeviceMac due to null PIPScreenCaptureCoordinator"

* fixup! chore(patch-conflict): feat_add_support_for_missing_dialog_features_to_shell_dialogs.patch

* fixup! chore(patch-conflict): feat_filter_out_non-shareable_windows_in_the_current_application_in.patch

* 7239572: [OOPIF PDF] Enable OOPIF PDF by default on Windows/macOS/Linux

Ref: https://chromium-review.googlesource.com/c/chromium/src/+/7239572

* chore: bump chromium in DEPS to 145.0.7576.0

* fixup! chore(patch-conflict): feat_add_support_for_missing_dialog_features_to_shell_dialogs.patch

* chore: update patches (trivial only)

* chore: add note to keep patch that was upstreamed but reverted

fix_restore_original_resize_performance_on_macos.patch was organically upstreamed but that change got reverted just after the current roll's cutoff.

I've added a note in the patch contents so the patch sticks around and so we can keep it after the revert is included.

Ref: https://chromium-review.googlesource.com/c/chromium/src/+/7255334 "7255334: Revert 'Fix jank when resizing browser window'"

* chore: bump chromium in DEPS to 145.0.7577.0

* chore: update patches (trivial only)

* chore(patch-conflict): keep patch after revert

Ref: https://chromium-review.googlesource.com/c/chromium/src/+/7255334 "7255334: Revert 'Fix jank when resizing browser window'"

* 7237910: Remove g_gtk_ui global

I tried to find a way to avoid the patch, but other approaches seemed complex and involved.

Ref: https://chromium-review.googlesource.com/c/chromium/src/+/7237910

* 7251900: Reland "Remove callback_helpers.h include from is_callback.h (try 5)"

Ref: https://chromium-review.googlesource.com/c/chromium/src/+/7251900

* 7170174: [LNA] Retry requests for cached local resources

Ref: https://chromium-review.googlesource.com/c/chromium/src/+/7170174

* fix: PDFs use OOPIF (behavior change)

* fixup! 7237910: Remove g_gtk_ui global

* fixup! 7251900: Reland "Remove callback_helpers.h include from is_callback.h (try 5)"

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: clavin <clavin@electronjs.org>
2025-12-16 12:32:38 -05:00
John Kleinschmidt
e181fd040f build: drop dugite as a dependency (#49194) 2025-12-12 13:43:12 -05:00
David Sanders
a486185e10 ci: disallow non-maintainer changes to Yarn files (#49186) 2025-12-11 09:25:29 -05:00
John Kleinschmidt
8cefc8425c build: upgrade yarn to 4.12.0 (#49176) 2025-12-10 14:04:14 -05:00
electron-roller[bot]
fe477ce3aa chore: bump chromium to 145.0.7568.0 (main) (#49145)
* chore: bump chromium in DEPS to 145.0.7562.0

* fix(patch-conflict): update code cache patch for PersistentCache refactor

Upstream refactored code cache to use PersistentCache with new class-based
implementation (NoopCodeCacheHost, LocalCodeCacheHost, CodeCacheWithPersistentCacheHost).
Updated patch to integrate custom scheme support into the new structure while
preserving ProcessLockURLIsCodeCacheScheme checks for embedder-registered schemes.

Ref: https://chromium-review.googlesource.com/c/chromium/src/+/7044986

Co-Authored-By: Claude <svc-devxp-claude@slack-corp.com>

* fix(patch-conflict): update dialog patch for RequestXdgDesktopPortal API

Upstream changed from SetSystemdScopeUnitNameForXdgPortal to RequestXdgDesktopPortal
API pattern. Updated OnServiceStarted signature and kept OnSystemdUnitStarted callback
that calls Electron's file_dialog::StartPortalAvailabilityTestInBackground().

Ref: https://chromium-review.googlesource.com/c/chromium/src/+/7204285

Co-Authored-By: Claude <svc-devxp-claude@slack-corp.com>

* fix(patch-conflict): remove reference to deleted AbortByPlaceholderLayout flag

Upstream removed the AbortByPlaceholderLayout runtime flag from
runtime_enabled_features.json5. Updated patch to only add ElectronCSSCornerSmoothing
without the removed flag reference.

Ref: https://chromium-review.googlesource.com/c/chromium/src/+/7226494

Co-Authored-By: Claude <svc-devxp-claude@slack-corp.com>

* chore: update patch hunk headers

Co-Authored-By: Claude <svc-devxp-claude@slack-corp.com>

* fix(build): guard media_file_system_registry for ChromeOS only

Upstream CL https://chromium-review.googlesource.com/c/chromium/src/+/7100719
moved media_file_system_registry to be ChromeOS-only since Media
Galleries is a Chrome Apps API and Chrome Apps are only available
on Chrome OS now.

Co-Authored-By: Claude <svc-devxp-claude@slack-corp.com>

* fix(build): update VideoPixelFormat API for SharedImageFormat

Upstream CL https://chromium-review.googlesource.com/c/chromium/src/+/7207153
removed VideoPixelFormatToGfxBufferFormat as part of migration to
SharedImageFormat. Update to use VideoPixelFormatToSharedImageFormat
which directly returns the SharedImageFormat.

Co-Authored-By: Claude <svc-devxp-claude@slack-corp.com>

* fix(build): extend profile methods patch for ShouldEnableXfaForms

The ShouldEnableXfaForms function uses Profile::FromBrowserContext()
which is not available in Electron. Wrap the profile-dependent code
in #if 0 to fall through to the feature flag default.

Co-Authored-By: Claude <noreply@anthropic.com>

* chore: bump chromium in DEPS to 145.0.7563.0

* chore: bump chromium in DEPS to 145.0.7565.0

* chore: bump chromium in DEPS to 145.0.7567.0

* chore: bump chromium in DEPS to 145.0.7568.0

* fix(patch-conflict): update content_main_delegate.h context for IsInitFeatureListEarly

Upstream added a new IsInitFeatureListEarly() virtual method to ContentMainDelegate
just before where our GetBrowserV8SnapshotFilename() method is added. Updated patch
context to account for this new method.

Ref: https://chromium-review.googlesource.com/c/chromium/src/+/7092856

Co-Authored-By: Claude <svc-devxp-claude@slack-corp.com>

* chore: update patch hunk headers

Co-Authored-By: Claude <svc-devxp-claude@slack-corp.com>

* fix(patch-update): include v8-cppgc.h for CppHeap complete type

The std::unique_ptr<v8::CppHeap> default argument in node.h requires
the complete CppHeap type definition for the destructor. Added the
v8-cppgc.h include to provide the full type definition.

Ref: Unable to locate CL - libc++ unique_ptr requires complete type for destructor

Co-Authored-By: Claude <svc-devxp-claude@slack-corp.com>

* chore: update patch hunk headers

Co-Authored-By: Claude <svc-devxp-claude@slack-corp.com>

* fix(build): move NativeAppWindowFrameViewMacClient before constructor

The std::unique_ptr<NativeAppWindowFrameViewMacClient> member requires
the complete type definition to be visible at the point of the constructor
because the unique_ptr destructor may be instantiated during exception
handling. Moved the class definition before the NativeWindowMac constructor.

Ref: Unable to locate CL - libc++ unique_ptr requires complete type for destructor

Co-Authored-By: Claude <svc-devxp-claude@slack-corp.com>

* fix(patch-conflict): update create_browser_v8_snapshot_file_name_fuse context for IsInitFeatureListEarly

The upstream added IsInitFeatureListEarly() virtual method declaration to
ContentMainDelegate class. Updated the patch context to account for this
new function being present before the GetBrowserV8SnapshotFilename()
declaration we add.

Ref: https://chromium-review.googlesource.com/c/chromium/src/+/7092856

Co-Authored-By: Claude <noreply@anthropic.com>

* chore: update patch hunk headers

Co-Authored-By: Claude <noreply@anthropic.com>

* fix(patch-update): remove reverted IsInitFeatureListEarly from v8 snapshot patch

The upstream added IsInitFeatureListEarly() was reverted, so the patch should
not include this declaration. Only GetBrowserV8SnapshotFilename() should be
added by the create_browser_v8_snapshot_file_name_fuse patch.

Ref: https://chromium-review.googlesource.com/c/chromium/src/+/7230430

Co-Authored-By: Claude <noreply@anthropic.com>

* 6171655: include single_thread_task_runner.h for complete type

Added include for base/task/single_thread_task_runner.h in osr_converter.cc
to resolve incomplete type error when using
base::SingleThreadTaskRunner::GetCurrentDefault().

Ref: https://chromium-review.googlesource.com/c/chromium/src/+/6171655

Co-Authored-By: Claude <noreply@anthropic.com>

* 7224136: use CHROMIUM_GIT_REVISION directly instead of removed function

Upstream removed GetChromiumGitRevision() function from embedder_support.
Updated to use CHROMIUM_GIT_REVISION macro directly via
build/util/chromium_git_revision.h as recommended in the Chromium CL.

Ref: https://chromium-review.googlesource.com/c/chromium/src/+/7224136

Co-Authored-By: Claude <noreply@anthropic.com>

* fixup! 7224136: use CHROMIUM_GIT_REVISION directly instead of removed function

* fix(build): add missing include

`components/dbus/xdg/systemd.h` for `void OnSystemdUnitStarted(dbus_xdg::SystemdUnitStatus)` in the same patch.

* fix(build): adapt to string-view-ification change in windows jump_list.cc

7186922: Fix unsafe buffer usage in base/win/win_util.cc
https://chromium-review.googlesource.com/c/chromium/src/+/7186922

* chore: update libc++ filenames

* fixup! fix(build): add missing include

* fixup! fix(build): extend profile methods patch for ShouldEnableXfaForms

* fixup! fix(build): guard media_file_system_registry for ChromeOS only

* fixup! fixup! fix(build): extend profile methods patch for ShouldEnableXfaForms

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: Keeley Hammond <khammond@slack-corp.com>
Co-authored-by: Claude <svc-devxp-claude@slack-corp.com>
Co-authored-by: Claude <noreply@anthropic.com>
Co-authored-by: clavin <clavin@electronjs.org>
2025-12-10 10:28:31 -05:00
John Kleinschmidt
bab6bd3dae build: use @electron-ci/dev-root for package.json default (#49154) 2025-12-09 14:49:12 -05:00
dependabot[bot]
33f6942565 build(deps): bump actions/stale from 10.1.0 to 10.1.1 (#49159)
Bumps [actions/stale](https://github.com/actions/stale) from 10.1.0 to 10.1.1.
- [Release notes](https://github.com/actions/stale/releases)
- [Changelog](https://github.com/actions/stale/blob/main/CHANGELOG.md)
- [Commits](5f858e3efb...997185467f)

---
updated-dependencies:
- dependency-name: actions/stale
  dependency-version: 10.1.1
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-12-09 12:14:50 -05:00
dependabot[bot]
a1b2e82778 build(deps): bump actions-cool/issues-helper from 3.7.2 to 3.7.3 (#49157)
Bumps [actions-cool/issues-helper](https://github.com/actions-cool/issues-helper) from 3.7.2 to 3.7.3.
- [Release notes](https://github.com/actions-cool/issues-helper/releases)
- [Changelog](https://github.com/actions-cool/issues-helper/blob/main/CHANGELOG.md)
- [Commits](9861779a69...3809910bc1)

---
updated-dependencies:
- dependency-name: actions-cool/issues-helper
  dependency-version: 3.7.3
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-12-09 12:14:13 -05:00
dependabot[bot]
1e06b74cd2 build(deps): bump github/codeql-action from 4.31.6 to 4.31.7 (#49155)
Bumps [github/codeql-action](https://github.com/github/codeql-action) from 4.31.6 to 4.31.7.
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](fe4161a26a...cf1bb45a27)

---
updated-dependencies:
- dependency-name: github/codeql-action
  dependency-version: 4.31.7
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-12-09 11:15:08 -05:00
dependabot[bot]
fe0caa0e0d build(deps): bump actions/checkout from 6.0.0 to 6.0.1 (#49158)
Bumps [actions/checkout](https://github.com/actions/checkout) from 6.0.0 to 6.0.1.
- [Release notes](https://github.com/actions/checkout/releases)
- [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md)
- [Commits](1af3b93b68...8e8c483db8)

---
updated-dependencies:
- dependency-name: actions/checkout
  dependency-version: 6.0.1
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-12-09 11:14:41 -05:00
dependabot[bot]
cd48083be8 build(deps): bump actions/setup-node from 6.0.0 to 6.1.0 (#49156)
Bumps [actions/setup-node](https://github.com/actions/setup-node) from 6.0.0 to 6.1.0.
- [Release notes](https://github.com/actions/setup-node/releases)
- [Commits](2028fbc5c2...395ad32622)

---
updated-dependencies:
- dependency-name: actions/setup-node
  dependency-version: 6.1.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-12-09 11:13:56 -05:00
John Kleinschmidt
8d5b104c17 build: upgrade github-app-auth to 3.2.0 (#49152) 2025-12-09 09:49:37 -05:00
John Kleinschmidt
6e134a8ad9 build: use powershell for Electron build step (#49144) 2025-12-08 16:03:40 -05:00
electron-roller[bot]
95e87e46ab chore: bump chromium to 144.0.7547.0 (main) (#49058)
* chore: bump chromium in DEPS to 144.0.7543.0

* Pass PipScreenCaptureCoordinatorProxy to ScreenCaptureKitDeviceMac

https://chromium-review.googlesource.com/c/chromium/src/+/7157590

* chore: update patches

* chore: update filenames.libcxx.gni

* 7142359: Spanification of process_singleton_posix.cc

https: //chromium-review.googlesource.com/c/chromium/src/+/7142359
Co-Authored-By: Charles Kerr <70381+ckerr@users.noreply.github.com>

* Move logging::LoggingSettings to base/logging/logging_settings.h

https://chromium-review.googlesource.com/c/chromium/src/+/7173024

* chore: bump chromium in DEPS to 144.0.7545.0

* 7159368: update PluginService API for sync GetPlugins

Upstream removed async PluginService APIs:
- GetPluginsAsync() removed, use synchronous GetPlugins()
- RegisterInternalPlugin() now takes single argument (remove add_at_beginning)
- RefreshPlugins() removed entirely

Updated ElectronPluginInfoHostImpl to use synchronous plugin loading and
simplified ElectronBrowserMainParts internal plugin registration.

Ref: https://chromium-review.googlesource.com/c/chromium/src/+/7159368
Ref: https://chromium-review.googlesource.com/c/chromium/src/+/7159328
Ref: https://chromium-review.googlesource.com/c/chromium/src/+/7159056
(cherry picked from commit 88cdf50b0a)

* 7159184: add missing base/files/file_path.h include

Add explicit include for base/files/file_path.h in electron_browser_context.h.
After removal of superfluous Mojo includes from content headers, base::FilePath
is no longer transitively included via content/public/browser/browser_context.h.

Ref: https://chromium-review.googlesource.com/c/chromium/src/+/7159184
(cherry picked from commit 6ca8ea03ec)

* 7126479: add ShouldForceRefreshTextCheckService parameter to SpellCheckClient

Upstream added a force-refresh parameter to WebTextCheckClient::RequestCheckingOfText
to bypass spell check cache. Add the new ShouldForceRefreshTextCheckService
parameter to SpellCheckClient's override (currently unused in Electron).

Ref: https://chromium-review.googlesource.com/c/chromium/src/+/7126479
(cherry picked from commit 879c0401c4)

* 7083663: remove fingerprinting_protection_ruleset_service override

Upstream deleted external references to Fingerprinting Protection Filter (FPF)
component. Remove the fingerprinting_protection_ruleset_service() override
from BrowserProcessImpl as the method no longer exists in the base class.

Ref: https://chromium-review.googlesource.com/c/chromium/src/+/7083663
(cherry picked from commit 8350d152f9)

* 7155287: implement WebContentsView::GetSize and Resize

Upstream delegated WebContents::GetSize() and Resize() to WebContentsView,
making them pure virtual. Add const qualifier to GetSize() and implement
the Resize() override in OffScreenWebContentsView (no-op for offscreen).

Ref: https://chromium-review.googlesource.com/c/chromium/src/+/7155287
(cherry picked from commit 084eaa568e)

* 7184238: add OnUnconfirmedTapConvertedToTap override

Upstream added OnUnconfirmedTapConvertedToTap as a pure virtual method
to RenderWidgetHostViewBase to inform root view when child frame converts
an unconfirmed tap. Add empty override for offscreen rendering.

Ref: https://chromium-review.googlesource.com/c/chromium/src/+/7184238
(cherry picked from commit ef03400d9a)

* 7143586: add widget parameter to OnCommandsChanged

GlobalAcceleratorListener::OnCommandsChanged gained a gfx::AcceleratedWidget
parameter for window association in the GlobalShortcutListenerLinux
implementation. Pass gfx::kNullAcceleratedWidget for Electron's usage.

Ref: : Pass parent handle to GlobalAcceleratorListenerLinux::BindShortcuts | https://chromium-review.googlesource.com/c/chromium/src/+/7143586
(cherry picked from commit 38306e2bfc)
Co-Authored-By: Samuel Attard <MarshallOfSound@users.noreply.github.com>

* chore: update patches

Co-Authored-By: Samuel Attard <MarshallOfSound@users.noreply.github.com>

* chore: bump chromium in DEPS to 144.0.7547.0

* chore: update patches

* 7189232: Add support for UnownedUserData in GlobalFeatures

https: //chromium-review.googlesource.com/c/chromium/src/+/7189232

* Refactor: Use std::u16string for extension load error messages

https://chromium-review.googlesource.com/c/chromium/src/+/7185844

* fixup Add support for UnownedUserData in GlobalFeatures

* 7165650: Remove ResourceContext

https://chromium-review.googlesource.com/c/chromium/src/+/7165650

* fixup BUILD.gn for lint

* 7202164: Reland "Reland "Remove GenericScopedHandle:IsValid""

https://chromium-review.googlesource.com/c/chromium/src/+/7202164

* advance deprecation of v8::ReturnValue<void>::Set(Local<S>).

7168624: [runtime][api] Relax requirements for setter/definer/deleter callbacks | https://chromium-review.googlesource.com/c/v8/v8/+/7168624

* fixup advance deprecation of v8::ReturnValue<void>::Set(Local<S>)

* chore: skip setting LPAC ACLs

* Revert "chore: skip setting LPAC ACLs"

This reverts commit e187aec488.

* chore: revert Convert to UNSAFE_TODO in sandbox

revert https://chromium-review.googlesource.com/c/chromium/src/+/7131661 to see if it fixes the Windows sandbox issue.

* Revert "chore: revert Convert to UNSAFE_TODO in sandbox"

This reverts commit 57afbfefe5.

* chore: Revert "Enable network sandbox by default on Windows"

see if this fixes the Windows sandbox issue

* Enable network sandbox by default on Windows

https://chromium-review.googlesource.com/c/chromium/src/+/7204292

* Revert "chore: Revert "Enable network sandbox by default on Windows""

This reverts commit 530ab6af82.

* fixup! Enable network sandbox by default on Windows | https://chromium-review.googlesource.com/c/chromium/src/+/7204292

* fixup!: Correct flag name, add kLocalNetworkAccessChecks to all platforms

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: John Kleinschmidt <jkleinsc@electronjs.org>
Co-authored-by: Charles Kerr <70381+ckerr@users.noreply.github.com>
Co-authored-by: Samuel Attard <sattard@anthropic.com>
Co-authored-by: Samuel Attard <MarshallOfSound@users.noreply.github.com>
Co-authored-by: John Kleinschmidt <kleinschmidtorama@gmail.com>
Co-authored-by: Keeley Hammond <khammond@slack-corp.com>
2025-12-04 16:40:04 -08:00
Jan Hannemann
90e338df50 fix: run toast creation on background thread (#49106)
* fix: run toast creation on background thread

notes: attempts to fix app freeze when triggering notifications and the COM server in WindowsShellExperienceHost hangs

* fix: comments
2025-12-02 15:27:22 -08:00
dependabot[bot]
1b3fc9c174 build(deps): bump actions/checkout from 4.2.2 to 6.0.0 (#49125)
Bumps [actions/checkout](https://github.com/actions/checkout) from 4.2.2 to 6.0.0.
- [Release notes](https://github.com/actions/checkout/releases)
- [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md)
- [Commits](https://github.com/actions/checkout/compare/v4.2.2...1af3b93b6815bc44a9784bd300feb67ff0d1eeb3)

---
updated-dependencies:
- dependency-name: actions/checkout
  dependency-version: 6.0.0
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-12-02 14:02:06 -05:00
dependabot[bot]
c51018281f build(deps): bump github/codeql-action from 4.31.5 to 4.31.6 (#49124)
Bumps [github/codeql-action](https://github.com/github/codeql-action) from 4.31.5 to 4.31.6.
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](fdbfb4d275...fe4161a26a)

---
updated-dependencies:
- dependency-name: github/codeql-action
  dependency-version: 4.31.6
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-12-02 14:01:21 -05:00
Samuel Attard
8ce97df569 build: gate brew commands in free-space-macos action (#49123)
fix: gate brew commands in free-space-macos action

The brew uninstall and autoremove commands now only run if
brew is available on the machine. This prevents failures on
runners where Homebrew is not installed.

Co-authored-by: Claude <noreply@anthropic.com>
2025-12-01 17:32:46 -08:00
John Kleinschmidt
7aafe66717 chore: reclaim macOS disk space (#49118) 2025-12-01 13:34:06 -08:00
Samuel Attard
ba5f7d272f fix: rename RUNNER_NAME to MATRIX_RUNNER in disk cleanup workflow (#49120)
RUNNER_NAME is a reserved environment variable in GitHub Actions.
Renamed to MATRIX_RUNNER to avoid conflicts.

Co-authored-by: Claude <noreply@anthropic.com>
2025-12-01 13:33:45 -08:00
Samuel Attard
6b50b5e816 ci: add nightly macOS disk space cleanup workflow (#49119)
Add a scheduled GitHub Action that runs every night to:
- Run the existing disk space reclaimer on macOS runners
- Log disk space metrics (before/after cleanup, space freed) to Datadog

This helps monitor disk space trends and proactively maintain
runner health after recent "No space left on device" failures.

Co-authored-by: Claude <noreply@anthropic.com>
2025-12-01 13:07:28 -08:00
Niklas Wenzel
06044b50f4 chore: mention quiet period in PR template (#49117)
* chore: mention quiet period in PR template

* fix: remove trailing spaces
2025-12-01 11:55:13 -05:00
Robo
4adfc212b3 fix: crash when attempting to resolve modules during process exit (#49090)
* fix: crash when attempting to resolve modules during process exit

* chore: fix build
2025-11-27 10:30:09 +01:00
David Sanders
640c7bb908 ci: use clang problem matcher with nan spec runner (#49096) 2025-11-26 16:55:44 -08:00
David Sanders
0767b42cb8 ci: fix import in issue opened workflow (#49095) 2025-11-26 13:33:45 -05:00
Shelley Vohr
555f507c17 fix: ensure menu-did-close is emitted for application menus (#49075)
fix: ensure menu-did-close is emitted for application menus
2025-11-26 09:44:20 -06:00
David Sanders
1ff8e8014a ci: use yarn workspace for workflow dependencies (#48246) 2025-11-26 10:31:01 +01:00
John Kleinschmidt
20c7042a20 ci: don't build yarn modules for linux arm (#49031)
This should fix the oom errors
2025-11-26 10:25:16 +01:00
David Sanders
4786e80f33 ci: ignore Dependabot workflow failures in audit (#49080) 2025-11-25 17:06:36 -08:00
dependabot[bot]
64326e296b build(deps): bump actions/checkout from 5.0.1 to 6.0.0 (#49070)
Bumps [actions/checkout](https://github.com/actions/checkout) from 5.0.1 to 6.0.0.
- [Release notes](https://github.com/actions/checkout/releases)
- [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md)
- [Commits](93cb6efe18...1af3b93b68)

---
updated-dependencies:
- dependency-name: actions/checkout
  dependency-version: 6.0.0
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-11-25 14:44:17 -05:00
dependabot[bot]
2f67242030 build(deps): bump github/codeql-action from 4.31.3 to 4.31.5 (#49071)
Bumps [github/codeql-action](https://github.com/github/codeql-action) from 4.31.3 to 4.31.5.
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](014f16e7ab...fdbfb4d275)

---
updated-dependencies:
- dependency-name: github/codeql-action
  dependency-version: 4.31.5
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-11-25 12:44:10 -06:00
David Sanders
e6844a3640 test: remove already disabled nan tests from our disable list (#49050) 2025-11-25 12:04:52 -06:00
Luke Horwell
fdb7fc7794 docs: Clarify that menus use non-native styles (#45033)
* docs: Clarify menus use non-native styles

Addresses #42262

* empty commit to kick ci

* fix: make linter happy

* Strip trailing space for lint

---------

Co-authored-by: George Xu <george.xu@slack-corp.com>
Co-authored-by: John Kleinschmidt <jkleinsc@electronjs.org>
Co-authored-by: Niklas Wenzel <dev@nikwen.de>
2025-11-25 18:27:46 +01:00
John Kleinschmidt
e601d05cbd docs: update linux build instructions (#49030)
* docs: update linux build instructions

* Update docs/development/build-instructions-linux.md

Co-authored-by: Erick Zhao <ezhao@slack-corp.com>

* Update docs/development/build-instructions-linux.md

Co-authored-by: Erick Zhao <ezhao@slack-corp.com>

---------

Co-authored-by: Erick Zhao <ezhao@slack-corp.com>
2025-11-24 14:36:32 -05:00
electron-roller[bot]
66367e9db4 chore: bump chromium to 144.0.7527.0 (main) (#48959)
* chore: bump chromium in DEPS to 144.0.7527.0

* 7106405: [video pip] Fix gesture handling issues

https://chromium-review.googlesource.com/c/chromium/src/+/7106405

* 7130938: Reland "Remove some dependencies from the custom_handlers component"

https://chromium-review.googlesource.com/c/chromium/src/+/7130938

* 7139361: Rename PluginService's GetPlugins methods

https://chromium-review.googlesource.com/c/chromium/src/+/7139361

* chore: fixup patch indices

* test: fix macos webgl test | 7128438: Reland "Flip SwiftShader deprecation to launched." | https://chromium-review.googlesource.com/c/chromium/src/+/7128438

* test: update webgl test to skip on fallback adapters

* Fixup spec runner to properly fail on linux when tests fail

* test: fixup dbus tests

* test: convert shared-texture-spec from old done callback to async

Fixes Error: done() called multiple times in test <sharedTexture module import shared texture produced by osr successfully imported and rendered with subtle api> of file /__w/electron/electron/src/electron/spec/api-shared-texture-spec.ts

* test: fixup shared texture spec

* Revert "test: fixup dbus tests"

This reverts commit 3e2e720003.

* test: fixup dbus tests

* test: disable context menu spellcheck tests on linux

https://github.com/electron/electron/pull/48657 broke those tests

* disable sharedTexture tests on platforms other than macOS arm64

They were not working on other platforms previously but now they error out.

Also removed extraneous debugging.

* fix: use github.sha for yarn cache key to avoid hashFiles() composite action bug

* Use --immutable-cache to allow native module builds

* fix: wait for devtools blur event in focus test to avoid race condition

* fix: wait for devtools blur event in focus test to avoid race condition

* fix allow native module builds in spec workspace

* test:rebuild native modules

* Revert "fix allow native module builds in spec workspace"

This reverts commit ffda3be98c.

* Revert "Use --immutable-cache to allow native module builds"

This reverts commit 2e6eea4348.

* Revert "fix: use github.sha for yarn cache key to avoid hashFiles() composite action bug"

This reverts commit 33560ba0de.

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
Co-authored-by: Keeley Hammond <khammond@slack-corp.com>
Co-authored-by: John Kleinschmidt <jkleinsc@electronjs.org>
Co-authored-by: Alice Zhao <alicelovescake@anthropic.com>
2025-11-24 12:30:57 -05:00
Teo Yu Qi
05233b4962 docs: explain how to create transparent window using BaseWindow (#48921)
docs: clarify how to create transparent BaseWindow
2025-11-23 21:40:42 +01:00
Shelley Vohr
e4f02faa0a fix: only call popup closecallback for top-level menu (#49017) 2025-11-21 10:37:46 -05:00
Robo
d890ebd9fa chore: backport 744f40f from devtools-frontend (#49027) 2025-11-21 10:35:41 -05:00
Robo
79e17ce4be fix: exception when reading system certificates via nodejs (#49028) 2025-11-21 10:35:05 -05:00
reito
2200a70e8d feat: import shared texture supports nv12. (#48922) 2025-11-21 10:32:29 -05:00
John Kleinschmidt
203540c8aa build: automatically install git for dugite (#49022) 2025-11-20 10:12:02 -05:00
BILL SHEN
8f9637fde4 fix: revert the parent window remained interactive after the modal window was opened (#48977) 2025-11-19 18:24:12 +01:00
dependabot[bot]
5b5b24775e build(deps): bump github/codeql-action from 4.31.2 to 4.31.3 (#48997)
Bumps [github/codeql-action](https://github.com/github/codeql-action) from 4.31.2 to 4.31.3.
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](0499de31b9...014f16e7ab)

---
updated-dependencies:
- dependency-name: github/codeql-action
  dependency-version: 4.31.3
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-11-19 09:45:40 +01:00
dependabot[bot]
eb4b7bb82f build(deps): bump actions/checkout from 5.0.0 to 5.0.1 (#48998)
Bumps [actions/checkout](https://github.com/actions/checkout) from 5.0.0 to 5.0.1.
- [Release notes](https://github.com/actions/checkout/releases)
- [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md)
- [Commits](08c6903cd8...93cb6efe18)

---
updated-dependencies:
- dependency-name: actions/checkout
  dependency-version: 5.0.1
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-11-19 09:45:28 +01:00
Shelley Vohr
13e84e6868 fix: abort more descriptively for beforeunload (#48960) 2025-11-18 12:16:08 -05:00
electron-roller[bot]
54a617caab chore: bump node to v24.11.1 (main) (#48917)
* chore: bump node in DEPS to v24.11.1

* src: add a default branch for module phase

https://github.com/nodejs/node/pull/60261

* src: conditionally disable source phase imports by default

https://github.com/nodejs/node/pull/60364

* chore: update patches

* src: update locks to use DictionaryTemplate and other minor cleanups

https://github.com/nodejs/node/pull/60061

* deps: update simdjson to 4.0.7

https://github.com/nodejs/node/pull/59883

* test: move sea tests into test/sea

https://github.com/nodejs/node/pull/60250

* fixup deps: update simdjson to 4.0.7a

* src: conditionally disable source phase imports by default

https://github.com/nodejs/node/pull/60364

* module: handle null source from async loader hooks in sync hooks

https://github.com/nodejs/node/pull/59929

* Revert "src: conditionally disable source phase imports by default"

This reverts commit 5f85b84262.

* src: allow disabling JS source phase imports

https://github.com/nodejs/node/pull/60364

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: John Kleinschmidt <jkleinsc@electronjs.org>
Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
2025-11-18 09:34:51 -05:00
Robo
530be28bc5 fix: handle empty event scenario in ipc callbacks (#48987) 2025-11-17 15:28:25 -05:00
Samuel Attard
537fd7b10b build: update to yarn v4 (#48243) 2025-11-17 15:18:14 -05:00
Keeley Hammond
3809093511 build: add header for SetStackDumpFirstChanceCallback in renderer client (#48978) 2025-11-15 11:32:08 +01:00
Keeley Hammond
71be38f87f fix: revert enabling WASM trap handlers in all Node.js processes (#48973)
Revert "fix: enable wasm trap handlers in all Node.js  processes (#48788)"

This reverts commit ca0b46b413.
2025-11-14 15:23:15 -08:00
Samuel Attard
925966fde4 build: limit workflow gh token permissions (#48237) 2025-11-14 12:11:42 -08:00
Noah Gregory
2d5597b1b0 feat: validate integrity of ASAR Integrity dictionary on macOS (#48587) 2025-11-14 11:24:08 -08:00
Shelley Vohr
e3a0ac06e2 test: add view.getBounds|setBounds tests (#48936)
test: add view.getBounds|setBounds tests
2025-11-14 14:46:21 +01:00
Keeley Hammond
b66bf5db0c build: correct uploader copy for tar files (#48953) 2025-11-13 20:07:52 -08:00
Charles Kerr
16f1ec9001 refactor: use std::map::extract() in api::WebRequest (#48929)
refactor: use std::map::extract() in api::WebRequest

Small readability refactor to api::WebRequest::blocked_requests_:
use extract() when we want to pull a BlockedRequest from the map
and then process it.
2025-11-13 16:50:13 -05:00
Keeley Hammond
c896ab80fe fix: handle tar.xz files in uploaders, add to breaking changes (#48941)
* fix: handle tar.xz files in uploaders, add to breaking changes

* docs: add additional file extension info
2025-11-13 13:03:24 -08:00
Shelley Vohr
40b6738735 test: fix types in chromium-spec (#48943) 2025-11-13 15:25:09 -05:00
Niklas Wenzel
05b9a5bfc7 docs: fix docs for app.isHardwareAccelerationEnabled() (#48925) 2025-11-13 14:39:59 -05:00
Fedor Indutny
b9d3f15265 fix: crash on windows when UTF-8 is in path (#48898)
In 6399527761 we changed the path strings
that `node_modules.cc` operates on from single-byte to wide strings.
Unfortunately this means that `generic_path()` that the
"fix: ensure TraverseParent bails on resource path exit" patch was
calling was no longer a safe method to call on Windows if the underlying
string has unicode characters in it.

Here we fix it by using `ConvertGenericPathToUTF8` from the Node.js
internal utilities.
2025-11-13 19:09:34 +01:00
electron-roller[bot]
8ecd064d2c chore: bump chromium to 144.0.7526.0 (main) (#48932)
* chore: bump chromium in DEPS to 144.0.7526.0

* 7138583: [Partitioned Popins Removal] IPC

https://chromium-review.googlesource.com/c/chromium/src/+/7138583

* chore: fixup patch indices

* 7139794: Partially remove check for global handlers in plugin mime_type code

https://chromium-review.googlesource.com/c/chromium/src/+/7139794

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
2025-11-13 11:09:51 -05:00
Niklas Wenzel
511809ef63 docs: explain how to load SF Symbols with nativeImage (#48908)
* docs: explain how to load SF Symbols with `nativeImage`

* fix: use single quotes

* fix: use single quotes
2025-11-13 10:41:00 -05:00
Nilay Arya
32ae696ee0 feat: add --disable-geolocation command-line flag for macOS (#45934)
* feat(macos): add --disable-geolocation-mac command-line flag

* internally deny geolocation requests if flag set

e

* wrap PermissionRequestHandler instead

* wrap custom handler and deny regardless of response

* Update docs/api/command-line-switches.md

Co-authored-by: Will Anderson <will@itsananderson.com>

* resolving conflicts during rebase

* tests added

* tests added: minor changes

* move IsGeolocationDisabledViaCommandLine inside ElectronPermissionManager as a static member

* test: inject fixturesPath via --boot-eval

* Update shell/browser/electron_permission_manager.cc

Co-authored-by: Robo <hop2deep@gmail.com>

* chore: Fixup after merge

* fixup after merge

---------

Co-authored-by: Will Anderson <will@itsananderson.com>
Co-authored-by: Robo <hop2deep@gmail.com>
Co-authored-by: John Kleinschmidt <jkleinsc@electronjs.org>
2025-11-13 10:39:03 -05:00
Niklas Wenzel
b121065984 docs: clarify meaning of string value for menu item icon (#48919)
* docs: clarify meaning of string value for menu item icon

* fix: format

* fix: wording
2025-11-13 16:10:18 +01:00
Keeley Hammond
2622e6606d build: apply additional compression to dsym on upload (#48930)
build: use tar.xz compression
2025-11-13 10:43:53 +01:00
electron-roller[bot]
10b07deb97 chore: bump chromium to 144.0.7522.0 (main) (#48892)
* chore: bump chromium in DEPS to 144.0.7522.0

* 7131867: Remove GenericScopedHandle::IsValid in favor of is_valid

https://chromium-review.googlesource.com/c/chromium/src/+/7131867

* 7078879: [video pip] Remove old controls

https://chromium-review.googlesource.com/c/chromium/src/+/7078879

* chore: fixup patch indices

* 7128138: Add a pref to enable Secure DNS 'automatic mode with DoH fallback'.

https://chromium-review.googlesource.com/c/chromium/src/+/7128138

* chore: fixup indices

* fix: pip patch

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
2025-11-13 09:49:51 +01:00
vulture
92a910d15c fix: Windows: Calling window.setFocusable(true) will no longer cause a window to lose focus (#45640)
Make setFocusable only deactivate a window if focusable is false. Do not deactivate a window when setting focusable to true.
2025-11-12 15:15:40 -05:00
Charles Kerr
3c5513015a refactor: make api::WebRequest inherit from gin::Wrappable (#48762)
* refactor: make api::WebRequest inherit from gin::Wrappable

refactor: remove unused v8::Isolate* arg from WebRequest ctor

refactor: make electron::api::Session::web_request_ a cppgc::Member<api::WebRequest>

refactor: allocate api::WebRequest on cpp heap

refactor: modify Create(), Find(), and FindOrCreate() to return a WebRequest*

* refactor: ProxyingURLLoaderFactory takes a concrete api::WebRequest instead of a WebRequestAPI

Experimental commit to ensure `ProxyingURLLoaderFactory::web_request_api_`
won't be a dangling pointer.

* chore: fix doc shear

* refactor: use cppgc::WeakPersistent<> in ProxyingURLLoaderFactory

* refactor: make ProxyingURLLoaderFactory::web_request_ const

* refactor: make ProxyingWebSocket::web_request_ a cppgc::WeakPersistent<>

* add a gin::WeakCellFactory to api::WebRequest

* refactor: use a gin::WeakCell for the bound WebRequest argument in HandleOnBeforeRequestResponseEvent()

* chore: update patches
2025-11-12 12:53:00 -06:00
John Kleinschmidt
27727dbe0a docs: deprecate clipboard API access from renderer processes (#48877) 2025-11-12 10:16:31 -05:00
정승규
7961206fcb docs: fix v40 stable release date (#48889)
* docs(timelines): Correct v40.0.0 stable release date

On the Electron Timelines tutorial page (/docs/latest/tutorial/electron-timelines), there is a clear typo in the release schedule for v40.0.0.

The table currently lists the dates as:
* Alpha: 2025-Oct-30
* Beta: 2025-Dec-03
* **Stable: 2025-Oct-28**

This is logically incorrect, as the 'Stable' release date (Oct 28) is listed *before* both the 'Alpha' (Oct 30) and 'Beta' (Dec 03) dates for the same version.

This appears to be a copy-paste error, as the 'Stable' date (2025-Oct-28) is identical to the 'Stable' date for the v39.0.0 release in the preceding row.

This commit updates the 'Stable' date for v40.0.0 to its correct value, ensuring the timeline is accurate and logical.

* docs: Update v40.0.0 stable date to 2026-Jan-13 based on Chromium schedule
2025-11-12 12:59:32 +01:00
dependabot[bot]
7da0b4b351 build(deps): bump actions-cool/issues-helper from 3.7.1 to 3.7.2 (#48884)
Bumps [actions-cool/issues-helper](https://github.com/actions-cool/issues-helper) from 3.7.1 to 3.7.2.
- [Release notes](https://github.com/actions-cool/issues-helper/releases)
- [Changelog](https://github.com/actions-cool/issues-helper/blob/main/CHANGELOG.md)
- [Commits](564cd9b1ba...9861779a69)

---
updated-dependencies:
- dependency-name: actions-cool/issues-helper
  dependency-version: 3.7.2
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-11-11 21:33:27 +01:00
BILL SHEN
3d31030fc5 fix: restore window's canHide property on macOS (#47970)
* fix: restore window's canHide property on macOS

* chore: empty commit to unstick CI

---------

Co-authored-by: Charles Kerr <charles@charleskerr.com>
2025-11-11 15:30:04 -05:00
Shelley Vohr
11d174344a build: roll Mantle and remove patch (#38437) 2025-11-11 15:25:51 -05:00
dependabot[bot]
687f3d4a92 build(deps-dev): bump @electron/asar from 3.2.13 to 4.0.1 (#48721)
* build(deps-dev): bump @electron/asar from 3.2.13 to 4.0.1

Bumps [@electron/asar](https://github.com/electron/asar) from 3.2.13 to 4.0.1.
- [Release notes](https://github.com/electron/asar/releases)
- [Changelog](https://github.com/electron/asar/blob/main/CHANGELOG.md)
- [Commits](https://github.com/electron/asar/compare/v3.2.13...v4.0.1)

---
updated-dependencies:
- dependency-name: "@electron/asar"
  dependency-version: 4.0.1
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>

* chore: bump Node.js to 22.21.x

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
2025-11-11 15:01:19 -05:00
Shelley Vohr
93a611e224 ci: exclude top-level docs files from full CI (#48872) 2025-11-11 11:53:50 -05:00
Shelley Vohr
09db682529 build: remove track SSL_ERROR_ZERO_RETURN explicitly patch (#48875)
build: remove track SSL_ERROR_ZERO_RETURN explicitly patch
2025-11-11 14:16:04 +01:00
electron-roller[bot]
b811ca0cde chore: bump chromium to 144.0.7521.0 (main) (#48880)
* chore: bump chromium in DEPS to 144.0.7521.0

* chore: fixup patch indices

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
2025-11-11 13:16:38 +01:00
Robo
f260e06a62 chore: delay load pdfjs-dist for pdf spec (#48888)
trap handlers will be initialized once the user script starts
but before app#ready. Wasm compilation before that phase will
break trap handler registeration due to the check in
v8::internal::wasm::UpdateComputedInformation. For some reason
this issue was only visible in <= 39-x-y when pdf-reader.mjs
was being loaded, maybe some module loading logic changed in >= 40-x-y
which are based on Node.js v24.x. In either case, it is best to
align the loading of wasm module required for the tests in light
of changes to how we are registering the trap handlers for the
main process.
2025-11-11 19:00:39 +09:00
Charles Kerr
b659563724 refactor: use gin_helper's gin::Wrappable-to-v8::Local converter (#48885)
* refactor: Session::NetLog() returns a NetLog*

Use gin_helper's gin::Wrappable-to-v8::Local converter instead
of rewriting it.

* refactor: FromPath(base::FilePath&, gin::Arguments*) returns a Session*

refactor: FromPartition(std::string&, gin::Arguments*) returns a Session*

Use gin_helper's gin::Wrappable-to-v8::Local converter instead
of rewriting it.
2025-11-11 15:33:25 +09:00
Erick Zhao
dd7c7fddd1 docs: remove electronegativity (#48878) 2025-11-10 20:37:12 -05:00
Kai
bc86e68a72 feat: add bypassCustomProtocolHandlers option to net.request (#47331)
* feat: add bypassCustomProtocolHandlers option to net.request

* style: fix lint errors in api-protocol-spec
2025-11-10 16:37:29 -05:00
Shelley Vohr
4951b96235 feat: support WebSocket authentication handling (#48512)
* feat: support WebSocket authentication handling

* test: add a test

* refactor: route through login instead
2025-11-10 21:30:44 +01:00
electron-roller[bot]
a5cebb6df2 chore: bump chromium to 144.0.7520.0 (main) (#48869)
* chore: bump chromium in DEPS to 144.0.7520.0

* chore: fixup patch indices

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
2025-11-10 18:44:49 +01:00
Foad Lind
1ad8d35be9 docs: update macOS version support in README (#48785)
Update macOS version support in README

Support for macOS 11 (BigSur) was removed from v38: https://www.electronjs.org/blog/electron-38-0#removed-macos-11-support
2025-11-10 13:57:34 +01:00
electron-roller[bot]
a22511a196 chore: bump chromium to 144.0.7514.0 (main) (#48840)
* chore: bump chromium in DEPS to 144.0.7514.0

* chore: update patches

* 7119882: Reorganize //ui/gfx GN build target

https://chromium-review.googlesource.com/c/chromium/src/+/7119882

* Replace includes with forward declares in rect_conversions.h

https://chromium-review.googlesource.com/c/chromium/src/+/7127098

* Add ssl info to TrustedHeaderClient

https://chromium-review.googlesource.com/c/chromium/src/+/7106780

* Replace ContentPluginInfo with WebPluginInfo

https://chromium-review.googlesource.com/c/chromium/src/+/7127893

* Reland "[temporal] Unflag Temporal"

https://chromium-review.googlesource.com/c/v8/v8/+/7123876

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: John Kleinschmidt <jkleinsc@electronjs.org>
2025-11-10 13:27:35 +01:00
BILL SHEN
068ac3c405 fix: the parent window remained interactive after the modal window was opened (#48770)
fix: fix the issue where the parent window remained interactive after the modal window was opened in somecases.
2025-11-10 12:06:28 +01:00
Robo
87d1ff59cb build: add missing header for SetStackDumpFirstChanceCallback (#48860) 2025-11-10 18:12:02 +09:00
Charles Kerr
1073d7e2bb refactor: remove unused ExtensionActionAPI methods & fields (#48850)
refactor: remove unused method ExtensionActionAPI::GetExtensionPrefs()

refactor: remove unused field ExtensionActionAPI::browser_context_

refactor: remove unused field ExtensionActionAPI::browser_context_

looks like these were added in 5b105f91 but never used
2025-11-10 09:52:11 +01:00
Fedor Indutny
6399527761 fix: ESM-from-CJS import when CJK is in path (#48855)
Upstream fix: https://github.com/nodejs/node/pull/60575
2025-11-10 09:51:56 +01:00
Charles Kerr
519187db1d refactor: decouple api::WebRequest from api::BrowserContext (#48848)
* refactor: rename api::Session::CreateFrom() to api::Session::FromOrCreate()

This is both clearer and more consistent with other classes

* refactor: add Session::FromOrCreate(content::BrowserContext*)

* refactor: reimplement api::WebRequest::FromOrCreate() using api::Session::FromOrCreate()

* refactor: use base::PassKey to ensure WebRequest is only instantiated by Session

* refactor: remove WebRequest::From()

no longer needed; Session already guarantees uniqueness

* refactor: remove unused isolate arg from WebRequest ctor

* refactor: do not attach WebRequest to BrowserContext

no longer needed now that access goes through Session
2025-11-09 08:07:25 -06:00
Shelley Vohr
ab0ff5dffc refactor: remove spellcheck::kWinDelaySpellcheckServiceInit patch (#48843)
refactor: remove spellcheck::kWinDelaySpellcheckServiceInit patch
2025-11-08 10:26:06 -06:00
John Kleinschmidt
bec1734d63 chore: update patches (#48847) 2025-11-07 17:12:51 -05:00
Ryota Murakami
78b32cafcb docs: Update 404 devtools extension documentation link (#48813)
* docs: Update 404 devtools extension documentation link

https://developer.chrome.com/extensions/devtools

↑Current link is not exists.

So update to most relevant developer.chrome.com page.

https://developer.chrome.com/docs/extensions/how-to/devtools/extend-devtools#creating

* docs: remove unnecessary anchor link

Co-authored-by: Erick Zhao <erick@hotmail.ca>

---------

Co-authored-by: Erick Zhao <erick@hotmail.ca>
2025-11-07 10:32:33 -05:00
electron-roller[bot]
595920a308 chore: bump chromium to 144.0.7512.1 (main) (#48768)
* chore: bump chromium in DEPS to 144.0.7507.0

* chore: bump chromium in DEPS to 144.0.7508.0

* chore: update patches

* 7101838: [pathbuilder] Enforce immutable SkPath APIs globally

https://chromium-review.googlesource.com/c/chromium/src/+/7101838

* chore: update filenames.libcxx.gni

* [pathbuilder] Enforce immutable SkPath APIs globally

https://chromium-review.googlesource.com/c/chromium/src/+/7101838

* Reduce service_worker_info.h includes in headers

https://chromium-review.googlesource.com/c/chromium/src/+/7108401

* chore: bump chromium in DEPS to 144.0.7510.0

* chore: update patches

* Use internal popup menus for tabs in actor-controlled states

https://chromium-review.googlesource.com/c/chromium/src/+/7074751

* [api] Delete deprecated fields on v8::Isolate

https://chromium-review.googlesource.com/c/v8/v8/+/7081397
xref: 98d243aea0

* Fixup Reduce service_worker_info.h includes in headers

* Promote deprecation of v8::Context and v8::Object API methods

https://chromium-review.googlesource.com/c/v8/v8/+/7087956

* fixup Promote deprecation of v8::Context and v8::Object API methods

* chore: bump chromium in DEPS to 144.0.7512.1

* chore: update patches

* fixup [pathbuilder] Enforce immutable SkPath APIs global

* chore: update filenames.hunspell.gni

* fix deprecation of v8::Context and v8::Object API methods for nan

https://chromium-review.googlesource.com/c/v8/v8/+/7087956

* [PDF] Implement PdfHelpBubbleHandlerFactory

https://chromium-review.googlesource.com/c/chromium/src/+/7056325

also: [PDF Ink Signatures] Hook up IPH
https://chromium-review.googlesource.com/c/chromium/src/+/7056207

* Remove base/hash/md5.h

https://chromium-review.googlesource.com/c/chromium/src/+/7113738

* fixup for lint

* Remove deprecated interceptor callback types and AccessControl enum

https://chromium-review.googlesource.com/c/v8/v8/+/7112747

* fixup for lint

* fixup [PDF] Implement PdfHelpBubbleHandlerFactory

* use base::SHA1HashString instead of std::hash

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: John Kleinschmidt <jkleinsc@electronjs.org>
2025-11-07 10:13:45 -05:00
Robo
ca0b46b413 fix: enable wasm trap handlers in all Node.js processes (#48788)
* fix: enable wasm trap handlers in all Node.js  processes

* fix: separate registrations to account for featurelist init
2025-11-07 20:56:51 +09:00
Mitchell Cohen
194ce1a1d6 fix: CSD window frame tiles properly on Wayland (#48765)
fix: CSD window frame tiles properly on Linux
2025-11-07 11:24:12 +01:00
Shelley Vohr
b6a9f08be1 refactor: remove allow_unsafe_buffers pragma from FD_ZERO (#48811)
refactor: remove allow_unsafe_buffers pragma from FD_ZERO
2025-11-07 11:23:52 +01:00
reito
bab11f8c7b feat: add sharedTexture module to import shared texture (#47317)
feat: add `sharedTexture` module.
2025-11-07 09:50:28 +01:00
George Xu
38be633aa8 fix(reland): allow disabling all NSMenuItems (#48795)
* fix: allow disabling all `NSMenuItems` (#48598)

fix: allow disabling all NSMenuItems

* fix: add guard for type

---------

Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
2025-11-06 19:02:04 -08:00
Robo
9d01e6b3e3 fix: oom crash in v8 when optimizing wasm (#48791) 2025-11-06 21:58:13 +09:00
David Sanders
3c100c2229 build: use --keep-non-patch flag with git am (#48797) 2025-11-06 17:07:09 +09:00
Charles Kerr
f6ffb55c72 refactor: remove electron::WebRequestAPI interface (#48792)
* refactor: remove electron::WebRequestAPI interface

Remove the |electron::WebRequestAPI| interface class.
Use handles to the concrete class |electron::api::WebRequest| instead.

Prerequisite for https://github.com/electron/electron/pull/48762.

Two classes (electron::ProxyingURLLoaderFactory and electron::ProxyingWebSocket)
hold a handle to a WebRequest via |raw_ptr<electron::WebRequestAPI>|.
|electron::WebRequestAPI| is a pure virtual interface whose concrete impl is
|electron::api::WebRequest|.

This is a problem when migrating |electron::api::WebRequest| to cppgc:
we need to change those |raw_ptr<>|s to |cppgc::WeakPersistent<>| but
can't instantiate |cppgc::WeakPersistent<electron::WebRequestAPI>| as-is.
We also can't change it to inherit from |cppgc::GarbageCollectedMixin|,
since that causes problems when |electron::api::WebRequest| inherits from
both |electron::WebRequestAPI| and |cppgc::GarbageCollected|.

* refactor: use name web_request, not web_request_api

* refactor: make ProxyingURLLoaderFactory::web_request() private

* chore: make linter happy by fixing whitespace
2025-11-06 17:05:50 +09:00
Keeley Hammond
27bea2576e fix: revert allow disabling all NSMenuItems, fix menu crash (#48794)
Revert "fix: allow disabling all `NSMenuItems` (#48598)"

This reverts commit 0cb4fdd0f2.
2025-11-05 15:49:43 -08:00
Charles Kerr
c460992407 refactor: remove unnecessary template type in EmitEvent() (#48778)
refactor: remove unnecessary template type in EmitEvent()

refactor: CallMethodWithArgs() takes a std::string_view
2025-11-05 18:28:33 -05:00
Shelley Vohr
1f78d2258c refactor: remove base::AdaptCallbackForRepeating patch (#48774)
refactor: remove base::AdaptCallbackForRepeating patch
2025-11-05 11:00:51 -08:00
BILL SHEN
513a6ee80a fix: draw smoothing round rect corner (#48769) 2025-11-05 10:33:05 +01:00
Keeley Hammond
040b0e795b build: apply additional compression on upload (#48766)
build: apply additional compression on upload for large files
2025-11-04 10:20:42 -05:00
electron-roller[bot]
184586f0b1 chore: bump node to v24.11.0 (main) (#48728)
chore: bump node in DEPS to v24.11.0

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
2025-11-04 14:09:33 +01:00
dependabot[bot]
26759b8412 build(deps): bump github/codeql-action from 4.31.0 to 4.31.2 (#48764)
Bumps [github/codeql-action](https://github.com/github/codeql-action) from 4.31.0 to 4.31.2.
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](4e94bd11f7...0499de31b9)

---
updated-dependencies:
- dependency-name: github/codeql-action
  dependency-version: 4.31.2
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-11-04 11:54:33 +01:00
dependabot[bot]
de5041797f build(deps): bump actions-cool/issues-helper from 3.6.2 to 3.7.1 (#48763)
Bumps [actions-cool/issues-helper](https://github.com/actions-cool/issues-helper) from 3.6.2 to 3.7.1.
- [Release notes](https://github.com/actions-cool/issues-helper/releases)
- [Changelog](https://github.com/actions-cool/issues-helper/blob/main/CHANGELOG.md)
- [Commits](50068f49b7...564cd9b1ba)

---
updated-dependencies:
- dependency-name: actions-cool/issues-helper
  dependency-version: 3.7.1
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-11-04 11:54:19 +01:00
axolotl
5bd45a6a28 feat: add SF Symbol support to NativeImage::CreateFromNamedImage (#48203)
* feat: add SF Symbol support to NativeImage::CreateFromNamedImage

* use obj-c name in NSImage constructor

* add test for named symbol image

* apply suggested simplification

* fix: support NX cocoa prefix
2025-11-04 11:15:34 +01:00
David Sanders
d7727c9ec2 build: remove patch that landed in Chromium roll (#48771) 2025-11-04 10:07:52 +01:00
electron-roller[bot]
ba135e2f7f chore: bump chromium to 144.0.7506.0 (main) (#48744)
* chore: bump chromium in DEPS to 144.0.7504.0

* chore: bump chromium in DEPS to 144.0.7506.0

* chore: update patches

* Revert "build: explicitly disable reclient"

This reverts commit e08c6adb08.

No longer needed after https://crrev.com/c/7099239

* 7097498: Remove MSG_ROUTING_* constants from ipc_message.h

https://chromium-review.googlesource.com/c/chromium/src/+/7097498

* 7090671: [//gpu] Remove unneeded GpuInfo methods

https://chromium-review.googlesource.com/c/chromium/src/+/7090671

* 7103701: Remove IPC::PlatformFileForTransit.

https://chromium-review.googlesource.com/c/chromium/src/+/7103701

(This should have been removed with https://github.com/electron/electron/pull/17406).

* chore: update filenames.libcxx.gni

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: John Kleinschmidt <jkleinsc@electronjs.org>
2025-11-03 21:26:16 -08:00
Damglador
a88de8bf1c fix: use app name as a part of tray id on Linux (#48675)
* fix: use browser name as tray id

* fix: remove unnecessary .c_str()

* fix: use string_view instead of string&

* fix: move app_name_ to the bottom of private: section

https://google.github.io/styleguide/cppguide.html#Declaration_Order

* fix: use base's string utils to join strings

* docs: note when to remove the patch

* fix: update patch

* fix: make linter happy

* fix: move app_name_ to the bottom of private: section
2025-11-03 16:53:53 -06:00
Mitchell Cohen
4d6db515bd fix: release mouse buttons on focus loss on Wayland (#48752) 2025-11-03 14:37:42 +01:00
Niklas Wenzel
20fc76cb43 docs: explain how to handle incoming drag and drop (#48718)
Fixes https://github.com/electron/electron/issues/48667
2025-11-03 14:37:01 +01:00
Mitchell Cohen
2a94d414f7 docs: clarify BrowserWindow and App API support status on Wayland (#48740)
* docs: clarify BrowserWindow API support in Wayland

* typo fix

* updated docs

* wrapping
2025-10-31 16:35:08 -05:00
Charles Kerr
4abb1f2aa3 refactor: use Object.values() instead of Object.keys() in stringifyValues() (#48741)
refactor: use Object.values() instead of Object.keys() in stringifyValues

we only used the key to get the value
2025-10-31 16:32:34 -05:00
electron-roller[bot]
310490221e chore: bump chromium to 144.0.7500.0 (main) (#48725)
* chore: bump chromium in DEPS to 144.0.7500.0

* chore: fixup patch indices

* 7088768: Reland "download reclient only for chromeos by default"

https://chromium-review.googlesource.com/c/chromium/src/+/7088768

* Revert "7088768: Reland "download reclient only for chromeos by default""

This reverts commit 149d9fc92e.

* build: explicitly disable reclient

* 7013355: [api] Remove deprecated PropertyCallbackInfo::Holder()

https://chromium-review.googlesource.com/c/v8/v8/+/7013355

* [video pip] Enable video picture-in-picture controls update

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6701399

* fixup! [api] Remove deprecated PropertyCallbackInfo::Holder()

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
Co-authored-by: John Kleinschmidt <jkleinsc@electronjs.org>
Co-authored-by: deepak1556 <hop2deep@gmail.com>
2025-10-31 11:01:09 -04:00
Shelley Vohr
3345edd2bf chore: upgrade Node.js to v24.10.0 (#48613)
* chore: upgrade Node.js to v24.10.0

* chore: fixup crypto patch

* chore: fixup crypto test patch

* src: prepare for v8 sandboxing

https://github.com/nodejs/node/pull/58376

* esm: fix module.exports export on CJS modules

https://github.com/nodejs/node/pull/57366

* chore: fixup lazyload fs patch

* esm: Source Phase Imports for WebAssembly

https://github.com/nodejs/node/pull/56919

* module: remove --experimental-default-type

https://github.com/nodejs/node/pull/56092

* lib,src: refactor assert to load error source from memory

https://github.com/nodejs/node/pull/59751

* src: add source location to v8::TaskRunner

https://github.com/nodejs/node/pull/54077

* src: remove dependency on wrapper-descriptor-based CppHeap

https://github.com/nodejs/node/pull/54077

* src: do not use soon-to-be-deprecated V8 API

https://github.com/nodejs/node/pull/53174

* src: stop using deprecated fields of v8::FastApiCallbackOptions

https://github.com/nodejs/node/pull/54077

* test: update v8-stats test for V8 12.6

https://github.com/nodejs/node/pull/54077

* esm: unflag --experimental-wasm-modules

https://github.com/nodejs/node/pull/57038

* test: adapt assert tests to stack trace changes

https://github.com/nodejs/node/pull/58070

* src,test: unregister the isolate after disposal and before freeing

https://github.com/nodejs/node/pull/58070

* src: use cppgc to manage ContextifyContext

https://github.com/nodejs/node/pull/56522

* src: replace uses of FastApiTypedArray

https://github.com/nodejs/node/pull/58070

* module: integrate TypeScript into compile cache

https://github.com/nodejs/node/pull/56629

* deps: update ada to 3.2.7

https://github.com/nodejs/node/pull/59336

* src: make minor cleanups in encoding_binding.cc

https://github.com/nodejs/node/pull/57448

* src: switch from `Get/SetPrototype` to `Get/SetPrototypeV2`

https://github.com/nodejs/node/pull/55453

* src: use non-deprecated Get/SetPrototype methods

https://github.com/nodejs/node/pull/59671

* src: simplify string_bytes with views

https://github.com/nodejs/node/pull/54876

* src: improve utf8 string generation performance

https://github.com/nodejs/node/pull/54873

* src: use non-deprecated Utf8LengthV2() method

https://github.com/nodejs/node/pull/58070

* src: use non-deprecated WriteUtf8V2() method

https://github.com/nodejs/node/pull/58070

* src: refactor WriteUCS2 and remove flags argument

https://github.com/nodejs/node/pull/58163

* src: use String::WriteV2() in TwoByteValue

https://github.com/nodejs/node/pull/58164

* node-api: use WriteV2 in napi_get_value_string_utf16

https://github.com/nodejs/node/pull/58165

* node-api: use WriteOneByteV2 in napi_get_value_string_latin1

https://github.com/nodejs/node/pull/58325

* src: migrate WriteOneByte to WriteOneByteV2

https://github.com/nodejs/node/pull/59634

* fs: introduce dirent\.parentPath

https://github.com/nodejs/node/pull/50976

* src: avoid copy by using std::views::keys

https://github.com/nodejs/node/pull/56080

* chore: fixup patch indices

* fix: errant use of context->GetIsolate()

* fix: tweak BoringSSL compat patch for new changes

* fix: add back missing isolate dtor declaration

* fixup! esm: fix module.exports export on CJS modules

* cli: remove --no-experimental-fetch flag

https://github.com/nodejs/node/pull/52611/files

* esm: Source Phase Imports for WebAssembly

https://github.com/nodejs/node/pull/56919

* fixup! src: prepare for v8 sandboxing

* chore: bump @types/node to v24

* chore: fix const assignment in crypto test

* fix: sandbox pointer patch issues

* chore: rework source phase import patch

* src: add percentage support to --max-old-space-size

https://github.com/nodejs/node/pull/59082

* chore: fixup crypto tests

* chore: HostImportModuleWithPhaseDynamically todo

* fix: cjs esm failures

* fix: v8::Object::Wrappable issues

- b72a615754
- 490bac2496
- 4896a0dd69

* chore: remove deleted specs

* src: use v8::ExternalMemoryAccounter

https://github.com/nodejs/node/pull/58070

* fs: port SonicBoom module to fs module as FastUtf8Stream

https://github.com/nodejs/node/pull/58897

* chore: tweak sandboxed pr patch

* test: disable parallel/test-os-checked-function

* test: use WHATWG URL instead of url.parse

* fix: OPENSSL_secure_zalloc doesn't work in BoringSSL

* chore: fix accidental extra line

* 7017517: [defer-import-eval] Parse import defer syntax

https://chromium-review.googlesource.com/c/v8/v8/+/7017517
2025-10-30 19:16:48 +01:00
Charles Kerr
c5fe50be3b refactor: remove redundant map lookups in browser/api/menu.ts (#48706)
perf: avoid double map lookup in Menu.prototype._shouldCommandIdWorkWhenHidden

perf: avoid double map lookup in Menu.prototype._isCommandIdVisible

perf: avoid double map lookup in Menu.prototype._shouldRegisterAcceleratorForCommandId

perf: avoid double map lookup in Menu.prototype._getSharingItemForCommandId
2025-10-29 11:42:15 -05:00
electron-roller[bot]
37de243f55 chore: bump chromium to 143.0.7499.0 (main) (#48707)
* chore: bump chromium in DEPS to 143.0.7499.0

* 7079895: Allow full screen reentry when full screen parameters changed

https://chromium-review.googlesource.com/c/chromium/src/+/7079895

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
2025-10-29 12:32:33 +01:00
Erick Zhao
8c05e4b450 docs: use relative link for OffscreenSharedTexture (#48717) 2025-10-28 15:24:31 -07:00
Keeley Hammond
1eb2858e9a build: bump NMV to 143 for Electron 40 (#48714) 2025-10-28 15:02:26 -07:00
Calvin
c761a7529e docs: add release timeline for Electron 40 (#48663) 2025-10-28 12:42:59 -07:00
Calvin
75c722ca2f docs: remove inaccurate EOL deprecation process (#48696) 2025-10-28 12:40:00 -07:00
byquanton
1d3cc9d554 docs: add caveats for Electron PipeWire implementation (#48242) 2025-10-28 12:39:12 -07:00
Shelley Vohr
0cb4fdd0f2 fix: allow disabling all NSMenuItems (#48598)
fix: allow disabling all NSMenuItems
2025-10-28 11:20:55 -04:00
syntax.sculptor
21dfa8c732 fix: use correct signal variable in nan-spec-runner install check (#48639)
The install process spawn was not capturing its own signal variable,
causing the error check to incorrectly reference the build signal
instead. This could lead to:
- Install termination by signal going undetected
- False positive errors when build was killed but install succeeded

This commit ensures the install signal is properly captured and
checked, matching the pattern used for the build process.
2025-10-28 11:18:47 -04:00
electron-roller[bot]
29e0948f7b chore: bump chromium to 143.0.7497.0 (main) (#48657)
* chore: bump chromium in DEPS to 143.0.7492.0

* chore: bump chromium in DEPS to 143.0.7493.0

* chore: update mas_avoid_private_macos_api_usage.patch.patch

Move os_crypt/sync and os_crypt/async shared code to os_crypt/common | https://chromium-review.googlesource.com/c/chromium/src/+/7081087

* chore: update add_didinstallconditionalfeatures.patch

no manual changes; patch applied with fuzz

Reland "Remove BackForwardTransitions flag" | https://chromium-review.googlesource.com/c/chromium/src/+/7079411

* chore: update printing.patch

Avoid a reachable NOTREACHED() in PrintingContextLinux | https://chromium-review.googlesource.com/c/chromium/src/+/7081117

* chore: update allow_in-process_windows_to_have_different_web_prefs.patch

patch reapplied manually due to context shear

Reland "Remove BackForwardTransitions flag" | https://chromium-review.googlesource.com/c/chromium/src/+/7079411

* chore: update chore_provide_iswebcontentscreationoverridden_with_full_params.patch

patch reapplied manually due to context shear

Cleanup: format some content files | https://chromium-review.googlesource.com/c/chromium/src/+/7083290

* chore: update feat_ensure_mas_builds_of_the_same_application_can_use_safestorage.patch

patch manually reapplied for files moved upstream

Move os_crypt/sync and os_crypt/async shared code to os_crypt/common | https://chromium-review.googlesource.com/c/chromium/src/+/7081087

* chore: update revert_cleanup_remove_feature_windelayspellcheckserviceinit.patch

no manual changes; patch applied with fuzz

[spelling+grammar restrictions] fix feature param name | https://chromium-review.googlesource.com/c/chromium/src/+/7081186

* chore: update patches

* chore: fix broken includes in ElectronBrowserMainParts

Move os_crypt/sync and os_crypt/async shared code to os_crypt/common | https://chromium-review.googlesource.com/c/chromium/src/+/7081087

* chore: bump chromium in DEPS to 143.0.7495.0

* chore: fixup patch indices

* chore: bump chromium in DEPS to 143.0.7497.0

* chore: fixup patch indices

* 7085081: Roll libc++ from d6739a332fe9 to bc00f6e9f739 (1 revision)

https://chromium-review.googlesource.com/c/chromium/src/+/7085081

* 7081087: Move os_crypt/sync and os_crypt/async shared code to os_crypt/common

https://chromium-review.googlesource.com/c/chromium/src/+/7081087

* test: fix failing spec

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: Charles Kerr <charles@charleskerr.com>
Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
2025-10-28 11:17:29 -04:00
dependabot[bot]
08492b5977 build(deps): bump actions/upload-artifact from 4.6.2 to 5.0.0 (#48691)
Bumps [actions/upload-artifact](https://github.com/actions/upload-artifact) from 4.6.2 to 5.0.0.
- [Release notes](https://github.com/actions/upload-artifact/releases)
- [Commits](ea165f8d65...330a01c490)

---
updated-dependencies:
- dependency-name: actions/upload-artifact
  dependency-version: 5.0.0
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-10-28 07:50:01 -05:00
dependabot[bot]
3c1b51d949 build(deps): bump github/codeql-action from 4.30.9 to 4.31.0 (#48692)
Bumps [github/codeql-action](https://github.com/github/codeql-action) from 4.30.9 to 4.31.0.
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](16140ae1a1...4e94bd11f7)

---
updated-dependencies:
- dependency-name: github/codeql-action
  dependency-version: 4.31.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-10-28 07:49:29 -05:00
michal-pichlinski-openfin
28f1cf1f11 feat: Focus DevTools when breakpoint is triggered (#46386)
`bringToFront` DevTools message is sent when breakpoint is triggered
or inspect is called and Chromium upon this message activates DevTools
via `DevToolsUIBindings::Delegate::ActivateWindow`:
```
void DevToolsWindow::ActivateWindow() {
  if (life_stage_ != kLoadCompleted)
    return;
\#if BUILDFLAG(IS_ANDROID)
  NOTIMPLEMENTED();
\#else
  if (is_docked_ && GetInspectedBrowserWindow())
    main_web_contents_->Focus();
  else if (!is_docked_ && browser_ && !browser_->window()->IsActive())
    browser_->window()->Activate();
\#endif
}
```
which implements: `DevToolsUIBindings::Delegate::ActivateWindow`.

Electron also implements this interface in:
`electron::InspectableWebContents`. However it was only setting
a zoom level, therefore this commit extends it with activation
of the DevTools.

Only supported for DevTools manged by `electron::InspectableWebContents`.

Closes: #37388
2025-10-28 08:46:33 -04:00
Erick Zhao
297319f931 ci: use <sup> in release notes generator (#48690) 2025-10-28 09:06:23 +01:00
dependabot[bot]
7fecc66e12 build(deps): bump actions/download-artifact from 5.0.0 to 6.0.0 (#48693)
Bumps [actions/download-artifact](https://github.com/actions/download-artifact) from 5.0.0 to 6.0.0.
- [Release notes](https://github.com/actions/download-artifact/releases)
- [Commits](634f93cb29...018cc2cf5b)

---
updated-dependencies:
- dependency-name: actions/download-artifact
  dependency-version: 6.0.0
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-10-28 08:58:28 +01:00
dependabot[bot]
705d120288 build(deps-dev): bump typescript from 5.6.2 to 5.8.3 (#48694)
Bumps [typescript](https://github.com/microsoft/TypeScript) from 5.6.2 to 5.8.3.
- [Release notes](https://github.com/microsoft/TypeScript/releases)
- [Changelog](https://github.com/microsoft/TypeScript/blob/main/azure-pipelines.release-publish.yml)
- [Commits](https://github.com/microsoft/TypeScript/compare/v5.6.2...v5.8.3)

---
updated-dependencies:
- dependency-name: typescript
  dependency-version: 5.8.3
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-10-28 08:54:56 +01:00
Teaveloper
9ce27e5318 docs: security.md use runnable examples for permissions and csp (#43248)
* docs: security.md use runnable examples for permissions and csp

Signed-off-by: LeUser111 <florian.wiedenmann@grob.de>

* Removed semi-colon for uniform js code style in examples

Signed-off-by: LeUser111 <florian.wiedenmann@grob.de>

* docs: security.md, session.md - added clarification on defaultSession, added csp example

* docs: security.md/session.md incorporated review feedback

* docs: security.md/session.md incorporated more review feedback

* docs: security.md/session.md incorporated more review feedback

* docs: tutorial/security.md - fixed linting issue

* chore: empty commit for CI

---------

Signed-off-by: LeUser111 <florian.wiedenmann@grob.de>
Co-authored-by: Keeley Hammond <khammond@slack-corp.com>
2025-10-27 16:56:53 -04:00
CuzImSlymi
09c22ea979 docs: add net.isOnline() to online/offline detection tutorial (#48665)
* docs: add net.isOnline() to online/offline detection tutorial

* chore: make linter happy

docs/tutorial/online-offline-events.md:12:1 MD004/ul-style Unordered list style [Expected: dash; Actual: asterisk]
docs/tutorial/online-offline-events.md:13:1 MD004/ul-style Unordered list style [Expected: dash; Actual: asterisk]

---------

Co-authored-by: Charles Kerr <charles@charleskerr.com>
2025-10-27 15:35:38 -04:00
Charles Kerr
e44b96bbd3 refactor: avoid deprecated views a11y api (#47674)
* refactor: use GetViewAccessibility().SetName() instead of SetAccessibleName()

Xref: https://chromium-review.googlesource.com/c/chromium/src/+/5537333

* refactor: use GetViewAccessibility().SetRole() instead of SetAccessibleRole()

Xref: https://chromium-review.googlesource.com/c/chromium/src/+/5337377

* fixup! refactor: use GetViewAccessibility().SetRole() instead of SetAccessibleRole()

---------

Co-authored-by: John Kleinschmidt <jkleinsc@electronjs.org>
2025-10-27 14:05:25 -05:00
Shelley Vohr
b389377c63 feat: add app.isHardwareAccelerationEnabled() (#47614)
* feat: add app.isHardwareAccelerationEnabled()

* chore: address review feedback
2025-10-27 14:03:08 -05:00
zoy
8f6ecd816b docs: modify the thickFrame doc (#48579)
* doc: modify the thickFrame doc

* chore: update description

Co-authored-by: John Kleinschmidt <kleinschmidtorama@gmail.com>

* update format

---------

Co-authored-by: John Kleinschmidt <kleinschmidtorama@gmail.com>
2025-10-27 13:38:05 -04:00
Charles Kerr
a611881ff3 fix: logical bug in install.js env var handling (#48634)
If either `npm_config_electron_use_remote_checksums` or
`electron_use_remote_checksums` are set as environment variables, then
force Electron to verify with remote checksums instead of embedded ones.

Fixes #48594.
2025-10-27 11:23:45 +01:00
dependabot[bot]
7925a4fe78 build(deps-dev): bump webpack-cli from 5.1.4 to 6.0.1 (#48651)
Bumps [webpack-cli](https://github.com/webpack/webpack-cli) from 5.1.4 to 6.0.1.
- [Release notes](https://github.com/webpack/webpack-cli/releases)
- [Changelog](https://github.com/webpack/webpack-cli/blob/main/CHANGELOG.md)
- [Commits](https://github.com/webpack/webpack-cli/compare/webpack-cli@5.1.4...webpack-cli@6.0.1)

---
updated-dependencies:
- dependency-name: webpack-cli
  dependency-version: 6.0.1
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-10-27 09:21:05 +01:00
Shelley Vohr
eda0a7e749 fix: crash on empty dialog extensions array on Windows (#48640) 2025-10-25 18:14:55 +02:00
electron-roller[bot]
777b6c70a2 chore: bump chromium to 143.0.7491.0 (main) (#48650)
* chore: bump chromium in DEPS to 143.0.7490.0

* chore: bump chromium in DEPS to 143.0.7491.0

* chore: update add_didinstallconditionalfeatures.patch

no manual changes; patch applied with fuzz

Revert "Remove BackForwardTransitions flag" | https://chromium-review.googlesource.com/c/chromium/src/+/7078209

* chore: update allow_in-process_windows_to_have_different_web_prefs.patch

patch reapplied manually due to context shear

Remove BackForwardTransitions flag | https://chromium-review.googlesource.com/c/chromium/src/+/7022596

* chore: update allow_electron_to_depend_on_components_os_crypt_sync.patch

no manual changes; patch applied with fuzz

Remove usage of os_crypt/sync in chrome/browser/ui | https://chromium-review.googlesource.com/c/chromium/src/+/7062066

* chore: update patches

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: Charles Kerr <charles@charleskerr.com>
2025-10-24 16:54:44 -05:00
electron-roller[bot]
6d8196fba3 chore: bump chromium to 143.0.7489.0 (main) (#48642)
* chore: bump chromium in DEPS to 143.0.7489.0

* chore: update add_didinstallconditionalfeatures.patch

no manual changes; patch applied with fuzz

* chore: update allow_in-process_windows_to_have_different_web_prefs.patch

patch reapplied manually due to context shear

Remove BackForwardTransitions flag | https://chromium-review.googlesource.com/c/chromium/src/+/7022596

* chore: update process_singleton.patch

patch reapplied manually due to context shear

Use an empty prefix for socket temporary directory. | https://chromium-review.googlesource.com/c/chromium/src/+/7062192

* chore: update add_electron_deps_to_license_credits_file.patch

no manual changes; patch applied with fuzz

* chore: update expose_ripemd160.patch

Apply modernize-use-nullptr fixes in all .cc files | https://boringssl-review.googlesource.com/c/boringssl/+/83067

* chore: update feat_expose_several_extra_cipher_functions.patch

Apply modernize-use-nullptr fixes in all .cc files | https://boringssl-review.googlesource.com/c/boringssl/+/83067

* Pass Bus::Options by value with std::move. | https://chromium-review.googlesource.com/c/chromium/src/+/7056670

* chore: update patches

* Remove some includes of base/callback_list.h | https://chromium-review.googlesource.com/c/chromium/src/+/7055621

* chore: run gen-libc++-filenames.js

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: Charles Kerr <charles@charleskerr.com>
2025-10-23 16:28:51 -04:00
Teaveloper
fbfd7c7126 docs: security.md mark 'Enable process sandboxing' as active by defau… (#43247)
* docs: security.md mark 'Enable process sandboxing' as active by default since electron 20

* Adjusted according to feedback

* Updated according to feedback - adjusted sandbox.md

* formatting

* Fixed broken markup

* Implemented docs linting suggestions

* docs: docs/tutorial/sandbox.md - fixed typo

Co-authored-by: Erick Zhao <erick@hotmail.ca>

* docs: web-preferences.md - sandbox: mention default value and relation to nodeIntegration

---------

Co-authored-by: Erick Zhao <erick@hotmail.ca>
2025-10-23 16:11:55 -04:00
Ruben R
00e01e0e82 fix: remove killed check to allow multiple signals (#40667)
* fix: remove `killed` check to allow multiple signals

* fix: signal forwarding
2025-10-23 15:20:04 -04:00
Calvin
418b8235bc chore: bump nan to 2.23.0 (#48591)
* chore: bump nan to 2.23.0

* Fix C++ flags passed to C compiler in NAN spec runner

Passing C++-specific flags to the C compiler caused failures building native test modules.

NAN uprgaded the version of node-gyp it uses, triggering a new codepath with the C compiler that didn't occur before. In that new branch, the C++ flags present in the CFLAGS environment variable we were passing in caused the C compiler to error out:

```
error: invalid argument '-std=c++20' not allowed with 'C'
```

The fix is to only pass C++-specific flags to the C++ compiler, and not the C compiler. This is done by separating out the CFLAGS and CXXFLAGS environment variables in our nan-spec-runner.js script.

I'm curious to know more about why each of these flags are necessary, but for now this change restores the previous behavior where native test modules could be built successfully.

* test: use v8 version check instead of node version check (patch)

* Re-enable `methodswithdata-test`
2025-10-23 20:58:40 +02:00
David Sanders
717eb0dca5 ci: add more fields to Slack payload for backport requested message (#48148)
* ci: add more fields to Slack payload for backport requested message

* chore: wrap values with toJSON
2025-10-23 11:58:18 -04:00
Niklas Wenzel
c6c3d405e2 docs: fix Ubuntu version used to build Electron (#48638) 2025-10-23 10:45:45 -04:00
electron-roller[bot]
9235dc0159 chore: bump chromium to 143.0.7485.0 (main) (#48618)
* chore: bump chromium in DEPS to 143.0.7485.0

* chore: update allow_disabling_blink_scheduler_throttling_per_renderview.patch

Move SetSupportsDraggableRegions mojom IPC from chrome/ and extensions/ to blink/ | https://chromium-review.googlesource.com/c/chromium/src/+/7043264

Patch applied manually due to context shear

* Move SetSupportsDraggableRegions mojom IPC from chrome/ and extensions/ to blink/ | https://chromium-review.googlesource.com/c/chromium/src/+/7043264

* chore: e patches all

* chore: check for file existence before setting utime

* chore: stop disabling kWinDelaySpellcheckServiceInit

[cleanup] Remove feature WinDelaySpellcheckServiceInit | https://chromium-review.googlesource.com/c/chromium/src/+/7012087

This flag has been removed upstream. We've used it since c2d7164 (#38248)
to fix a crash originally described in 97b353a (#34993):

> Delaying spell check initialization is causing specs for
> 'custom dictionary word list API' to fail in Electron.

Since we haven't touched this in a few years, and since there's a
clear success criteria (a passing/failing spec), and since the patch
to restore this flag would be pretty large (~750 lines), I'm going
to try just removing the flag from our source to see if the spec
passes or fails.

* Revert "chore: stop disabling kWinDelaySpellcheckServiceInit"

This reverts commit e688880396.

Unfortunately, the crash persists.

* Revert [cleanup] Remove feature WinDelaySpellcheckServiceInit | https://chromium-review.googlesource.com/c/chromium/src/+/7012087

We currently need this feature

* fixup! chore: check for file existence before setting utime

* fixup! Move SetSupportsDraggableRegions mojom IPC from chrome/ and extensions/ to blink/ | https://chromium-review.googlesource.com/c/chromium/src/+/7043264

Address Robo's code review @ 64c7fd21ed

* fixup! fixup! chore: check for file existence before setting utime

fix: oops typo

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: Charles Kerr <charles@charleskerr.com>
2025-10-23 08:30:29 -05:00
Shelley Vohr
f784ea6f4f fix: icon in Windows toast notification (#48543) 2025-10-21 15:12:26 -04:00
Tau Gärtli
7ec0ebc50a feat: Add getAccentColor on Linux (#48027)
* feat: Implement `getAccentColor` on Linux

* doc: Update OS support for accent color APIs
2025-10-21 14:26:30 -04:00
dependabot[bot]
4d329d466b build(deps): bump actions/checkout from 4.2.2 to 5.0.0 (#48051)
* build(deps): bump actions/checkout from 4.2.2 to 5.0.0

Bumps [actions/checkout](https://github.com/actions/checkout) from 4.2.2 to 5.0.0.
- [Release notes](https://github.com/actions/checkout/releases)
- [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md)
- [Commits](11bd71901b...08c6903cd8)

---
updated-dependencies:
- dependency-name: actions/checkout
  dependency-version: 5.0.0
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>

* chore: remove inaccurate version information

Version can easily be determined from sha

* ci: link node 24 for linux arm testing

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: John Kleinschmidt <jkleinsc@electronjs.org>
2025-10-21 14:12:05 -04:00
Shelley Vohr
e766d378e1 feat: enable more granular a11y feature management (#48042)
* feat: enable more granular a11y feature management

* Update docs/api/app.md

Co-authored-by: John Kleinschmidt <jkleinsc@electronjs.org>

---------

Co-authored-by: John Kleinschmidt <jkleinsc@electronjs.org>
2025-10-21 10:56:14 -04:00
Shelley Vohr
0a19176917 feat: enable resetting accent color (#48274) 2025-10-21 10:49:08 -04:00
Shelley Vohr
6562d6ed0b fix: systemPreferences.getAccentColor inverted color (#48511)
fix: systemPreferences.getAccentColor inverted color
2025-10-21 10:46:46 -04:00
Shelley Vohr
0b179f8f05 fix: devtools crashing on Linux in detach mode (#48600) 2025-10-21 10:45:02 -04:00
Shelley Vohr
89d3067dd4 fix: trafficLightPosition incorrect with customButtonsOnHover (#48538)
fix: trafficLightPosition incorrect with customButtonsOnHover
2025-10-21 10:43:04 -04:00
electron-roller[bot]
00a3031357 chore: bump chromium to 143.0.7483.0 (main) (#48590)
* chore: bump chromium in DEPS to 143.0.7482.0

* chore: bump chromium in DEPS to 143.0.7483.0

* [CodeHealth] Remove RenderWidgetHostImpl::is_hidden() | https://chromium-review.googlesource.com/c/chromium/src/+/7050059

* chore: update mas_avoid_private_macos_api_usage.patch.patch

[graphite] Refactor backpressure fences on Mac to avoid GLContext | https://chromium-review.googlesource.com/c/chromium/src/+/7047167

* chore: update disable_compositor_recycling.patch

no manual changes; patch applied with fuzz

[CodeHealth] Remove RenderWidgetHostImpl::is_hidden() | https://chromium-review.googlesource.com/c/chromium/src/+/7050059

* chore: update allow_disabling_blink_scheduler_throttling_per_renderview.patch

[CodeHealth] Remove RenderWidgetHostImpl::is_hidden() | https://chromium-review.googlesource.com/c/chromium/src/+/7050059

* chore: update feat_allow_code_cache_in_custom_schemes.patch

[url] Change Add*Scheme*(...) functions to accept std::string_view | https://chromium-review.googlesource.com/c/chromium/src/+/7046471

* chore: e patches all

* [memory] Replace bool success with MemoryDumpRequestOutcome enum. | https://chromium-review.googlesource.com/c/chromium/src/+/7029767

* [CodeHealth] Remove RenderWidgetHostImpl::is_hidden() | https://chromium-review.googlesource.com/c/chromium/src/+/7050059

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: Charles Kerr <charles@charleskerr.com>
2025-10-21 08:11:09 -05:00
dependabot[bot]
46c344fb1c build(deps): bump github/codeql-action from 4.30.8 to 4.30.9 (#48606)
Bumps [github/codeql-action](https://github.com/github/codeql-action) from 4.30.8 to 4.30.9.
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](f443b600d9...16140ae1a1)

---
updated-dependencies:
- dependency-name: github/codeql-action
  dependency-version: 4.30.9
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-10-21 10:47:44 +02:00
dependabot[bot]
28cf65eb33 build(deps): bump actions/setup-node from 5.0.0 to 6.0.0 (#48607)
Bumps [actions/setup-node](https://github.com/actions/setup-node) from 5.0.0 to 6.0.0.
- [Release notes](https://github.com/actions/setup-node/releases)
- [Commits](a0853c2454...2028fbc5c2)

---
updated-dependencies:
- dependency-name: actions/setup-node
  dependency-version: 6.0.0
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-10-21 07:30:39 +02:00
John Kleinschmidt
2a0c368105 build: use one build target (#48527)
This reverts commit Optimizes our builds for use with siso/avoids file contention on Windows
2025-10-20 15:57:50 -04:00
Mitchell Cohen
0c27c1a395 fix: position window titlebar buttons correctly in Ubuntu on Wayland (#48490) 2025-10-20 12:42:23 -07:00
Michaela Laurencin
a528547dc8 chore: exempt tracking-upstream issues from stale (#48574) 2025-10-20 11:47:58 -04:00
Shelley Vohr
413803188d fix: background hover contrast for WCO buttons (#48568) 2025-10-20 09:54:14 +02:00
electron-roller[bot]
1cc2fce905 chore: bump chromium to 143.0.7477.0 (main) (#48584)
* chore: bump chromium in DEPS to 143.0.7477.0

* 7049117: [CodeCache] Adjust PersistentCache for CodeCache feature

Refs https://chromium-review.googlesource.com/c/chromium/src/+/7049117

* chore: update patches

* chore: add missing includes of ui/gfx/image/image_skia.h

* 7028738: Rename several ipc_* files used by param_traits*

Refs https://chromium-review.googlesource.com/c/chromium/src/+/7028738

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: David Sanders <dsanders11@ucsbalum.com>
2025-10-19 21:46:34 +02:00
electron-roller[bot]
3bfe1f2363 chore: bump chromium to 143.0.7474.0 (main) (#48572)
* chore: bump chromium in DEPS to 143.0.7474.0

* 7006208: [Mac] Fix rendering bug for manual occlusion detection on macOS 26

Refs https://chromium-review.googlesource.com/c/chromium/src/+/7006208

* chore: update patches

* 7038563: Forward declare more in page_navigator.h

Refs https://chromium-review.googlesource.com/c/chromium/src/+/7038563

* 7023417: Remove ipc/ipc_message_macros.h

Refs https://chromium-review.googlesource.com/c/chromium/src/+/7023417

* 7006340: Move icon_util files to win/ subdrectory

Refs https://chromium-review.googlesource.com/c/chromium/src/+/7006340

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: David Sanders <dsanders11@ucsbalum.com>
2025-10-17 13:04:24 -04:00
Shelley Vohr
7e031f7e33 ci: fix publish for macOS < 26.0 (#48575) 2025-10-16 16:53:13 -07:00
Robo
7580e3a5e2 chore: update fix_harden_blink_scriptstate_maybefrom.patch (#48566) 2025-10-16 10:16:17 +09:00
electron-roller[bot]
471a14432f chore: bump chromium to 143.0.7469.0 (main) (#48548)
* chore: bump chromium in DEPS to 143.0.7469.0

* 7021651: [//gpu] Fold handle creation into D3DImageBackingFactory

Refs https://chromium-review.googlesource.com/c/chromium/src/+/7021651

* 7013047: Fix various C++23 build errors in //chrome

Refs https://chromium-review.googlesource.com/c/chromium/src/+/7013047

* 7010850: [//ui] Port screen_mac.mm's calls to DisplayColorSpaces

Refs https://chromium-review.googlesource.com/c/chromium/src/+/7010850

* 7007933: Remove superfluous mojom includes in //content/public headers

Refs https://chromium-review.googlesource.com/c/chromium/src/+/7007933

* 7023196: Trim os_crypt/sync visibility list

Refs https://chromium-review.googlesource.com/c/chromium/src/+/7023196

* 7008912: Remove GURL::*_piece() method

Refs https://chromium-review.googlesource.com/c/chromium/src/+/7008912

* 7003989: Add wrapper struct for CopyFromSurface output

Refs https://chromium-review.googlesource.com/c/chromium/src/+/7003989

* 7017889: [MemoryPressureListener] Remove type aliases

Refs https://chromium-review.googlesource.com/c/chromium/src/+/7017889

* 7027780: Delete viz::ResourceSizes

Refs https://chromium-review.googlesource.com/c/chromium/src/+/7027780
Refs https://chromium-review.googlesource.com/c/chromium/src/+/6989572

* 6495189: [api] Delete old String::Write* APIs

Refs https://chromium-review.googlesource.com/c/v8/v8/+/6495189

* chore: update patches

* chore: run script/gen-libc++-filenames.js

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: David Sanders <dsanders11@ucsbalum.com>
2025-10-15 14:10:10 -07:00
Shelley Vohr
676406c9e6 build: run on macOS 15 (#48563) 2025-10-14 13:29:21 -07:00
CezaryKulakowski
357e42d907 fix: fixed white flash on call to BrowserWindow.show (#47151) 2025-10-14 15:58:27 +02:00
お餅のCreeeper
9b740594fb fix: enable shader-f16 on windows (#48342)
* fix: Enable shader-f16 on Windows

* fix: include dxil.dll and dxcompiler.dll for windows x64 and arm64

* fix: modified to follow the chromium dawn build configuration

* fix: include dxil.dll and dxcompiler.dll for windows x86

* fix: Modified to avoid explicitly specifying dawn_use_built_dxc
2025-10-14 15:46:12 +02:00
dependabot[bot]
9e577ae60e build(deps): bump ossf/scorecard-action from 2.4.2 to 2.4.3 (#48551)
Bumps [ossf/scorecard-action](https://github.com/ossf/scorecard-action) from 2.4.2 to 2.4.3.
- [Release notes](https://github.com/ossf/scorecard-action/releases)
- [Changelog](https://github.com/ossf/scorecard-action/blob/main/RELEASE.md)
- [Commits](05b42c6244...4eaacf0543)

---
updated-dependencies:
- dependency-name: ossf/scorecard-action
  dependency-version: 2.4.3
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-10-14 14:45:03 +02:00
dependabot[bot]
b74bd8fc35 build(deps): bump github/codeql-action from 3.30.6 to 4.30.8 (#48552)
Bumps [github/codeql-action](https://github.com/github/codeql-action) from 3.30.6 to 4.30.8.
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](64d10c1313...f443b600d9)

---
updated-dependencies:
- dependency-name: github/codeql-action
  dependency-version: 4.30.8
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-10-14 11:29:55 +02:00
David Sanders
f494dbb609 ci: upload build cache hit rate on Windows as well (#48550) 2025-10-14 09:57:47 +02:00
David Sanders
8dc5999f8b build(deps): bump @electron/typescript-definitions to 9.1.5 (#48210) 2025-10-13 10:46:34 -07:00
electron-roller[bot]
d920c82fc4 chore: bump chromium to 143.0.7451.0 (main) (#48362)
* chore: bump chromium in DEPS to 142.0.7429.0

* chore: bump chromium in DEPS to 142.0.7430.0

* 6954508: Reland Migrate WrappableWithNamedPropertyInterceptor to gin::Wrappable | https://chromium-review.googlesource.com/c/chromium/src/+/6954508

* https://chromium-review.googlesource.com/c/chromium/src/+/6955633

* 5584820: Fix font face resolution when renderer is blocked | https://chromium-review.googlesource.com/c/chromium/src/+/5584820

* chore: export patches

* chore: remove patch that keeley says is ok to remove in comments

* chore: bump chromium in DEPS to 142.0.7432.0

* chore: export patches

* chore: bump chromium in DEPS to 142.0.7434.0

* 6973697: Use type tags for data stored in V8 internal fields | https://chromium-review.googlesource.com/c/chromium/src/+/6973697

* 6976272: Revert Reland mac: click through content area in main window | https://chromium-review.googlesource.com/c/chromium/src/+/6976272

* chore: export patches

* 6938086: Rename native_widget_types.h -> native_ui_types.h | https://chromium-review.googlesource.com/c/chromium/src/+/6938086

* 6951252: Correct PersistentCache backed code cache context grouping

* chore: bump chromium in DEPS to 142.0.7436.0

* 6981628: Reland Use unordered_map in AcceleratorMap | https://chromium-review.googlesource.com/c/chromium/src/+/6981628

* chore: export patches

* chore: resolve patch conflict with main

* chore: merge conflict with main

* chore: bump chromium in DEPS to 142.0.7438.0

* chore: bump chromium in DEPS to 142.0.7440.0

* chore: bump chromium in DEPS to 142.0.7442.0

* chore: bump chromium in DEPS to 142.0.7444.0

* chore: bump chromium in DEPS to 143.0.7445.0

* chore: bump chromium in DEPS to 143.0.7447.0

* chore: bump chromium in DEPS to 143.0.7449.0

* chore: bump chromium in DEPS to 143.0.7451.0

* 7001364: Migrate GURL accessors to Get* variants in //content | https://chromium-review.googlesource.com/c/chromium/src/+/7001364

* 6986521: Implicit second value 'any' instead of 'span-all' for fallback query | https://chromium-review.googlesource.com/c/chromium/src/+/6986521

* chore: update chromium patches

* chore: update chromium patches

* chore: update patches

* fix: parse macOS SDK version across line break
https://chromium-review.googlesource.com/c/chromium/src/+/6980166

* fix: replace v8::Object::SetPrototype() usage
https://chromium-review.googlesource.com/c/v8/v8/+/6983465
https://github.com/nodejs/node/pull/55453

* fix: regenerate filenames.libcxx.gni
https://chromium-review.googlesource.com/c/chromium/src/+/6980307

* fix: replace additional usages of SetPrototype
https://chromium-review.googlesource.com/c/v8/v8/+/6983465

* build: use macos 15 minimum
https://chromium-review.googlesource.com/c/chromium/src/+/6980166

* ci: ignore missing dir for strip_universal_deep

* fix: js2c compilation failure

https://chromium-review.googlesource.com/c/chromium/src/+/6950738

See patch description explaining MacOS 26 SDK headers incompatibility.

* fixup! chore: export patches

* feat: add new memory-eviction exit reason
https://chromium-review.googlesource.com/c/chromium/src/+/6991933

* fix: set JSON reader parsing options
https://chromium-review.googlesource.com/c/chromium/src/+/6992114

* fix: provide DeviceEmulationCacheBehavior param
https://chromium-review.googlesource.com/c/chromium/src/+/6965238

* fix: views::NonClientFrameView -> views::FrameView
https://chromium-review.googlesource.com/c/chromium/src/+/7005027
https://chromium-review.googlesource.com/c/chromium/src/+/6966937

* fix: check new forced colors enum value
https://chromium-review.googlesource.com/c/chromium/src/+/6944403

* fix: migrate NetworkConditions -> MatchedNetworkConditions
https://chromium-review.googlesource.com/c/chromium/src/+/6827307

* fix: migrate GURL string methods to Get*()
https://chromium-review.googlesource.com/c/chromium/src/+/7007010

* fix: disable C++ modules in electron_lib builds
https://chromium-review.googlesource.com/c/chromium/src/+/6950738

* fix: partially revert is_headless_mode removal
https://chromium-review.googlesource.com/c/chromium/src/+/6955633

This patch should likely be reworked. For now, this partially reverts the
removal of a required class property to restore behavior.

* Revert "build: use macos 15 minimum"

This reverts commit 2fc12d6acc.

Initially this change was made to test if it fixes libcxx
compilation issues. As that's now resolved by disabling libcxx
modules, this can be reverted.

* fix: disable C++ modules in libnode builds

* fixup! fix: replace v8::Object::SetPrototype() usage https://chromium-review.googlesource.com/c/v8/v8/+/6983465 https://github.com/nodejs/node/pull/55453

* fixup! fix: replace v8::Object::SetPrototype() usage https://chromium-review.googlesource.com/c/v8/v8/+/6983465 https://github.com/nodejs/node/pull/55453

* build: switch to macos-15 runner

build/mac/find_sdk.py now requires macOS 15 SDK as a minimum version. The
macos 15 runners default to an Xcode using the 15 SDK and removes older
versions.

* fixup! fix: check new forced colors enum value https://chromium-review.googlesource.com/c/chromium/src/+/6944403

* fixup! fix: migrate GURL string methods to Get*() https://chromium-review.googlesource.com/c/chromium/src/+/7007010

* fix: use std::u16string for Extension::Create() error parameter
https://chromium-review.googlesource.com/c/chromium/src/+/6975452

* fix: add missing image_skia include
https://chromium-review.googlesource.com/c/chromium/src/+/6986762

* fixup! fix: add missing image_skia include https://chromium-review.googlesource.com/c/chromium/src/+/6986762

* fix: remove outdated V8 flag
https://chromium-review.googlesource.com/c/v8/v8/+/6948286

* fix: disable protocol handler DCHECK

https://chromium-review.googlesource.com/c/chromium/src/+/6727594

Ignore the extension custom protocol handler registry DCHECK until
we invest in supporting it. Replacing this DCHECK seems harmless
and will unblock the roll.

* fix: replace deprecated usage of SetPrototype
https://chromium-review.googlesource.com/c/v8/v8/+/6983465

* fixup! fix: migrate NetworkConditions -> MatchedNetworkConditions https://chromium-review.googlesource.com/c/chromium/src/+/6827307

* fixup! fix: migrate GURL string methods to Get*() https://chromium-review.googlesource.com/c/chromium/src/+/7007010

* chore: remove patch already included in roll

* chore: remove extraneous formatting added to patch

* chore: remove fix_harden_blink_scriptstate_maybefrom.patch
https://chromium-review.googlesource.com/c/chromium/src/+/6973697

No longer needed since the above CL landed.

* 6973697: Use type tags for data stored in V8 internal fields

https://chromium-review.googlesource.com/c/chromium/src/+/6973697

* chore: update patches

* fixup! chore: export patches

* chore: restore electron embedder data tag patch

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: Alice Zhao <alicelovescake@anthropic.com>
Co-authored-by: Keeley Hammond <vertedinde@electronjs.org>
Co-authored-by: Samuel Maddock <smaddock@slack-corp.com>
Co-authored-by: John Kleinschmidt <jkleinsc@electronjs.org>
2025-10-13 12:21:54 -04:00
dependabot[bot]
d82b8f3b80 build(deps): bump github/codeql-action from 3.30.5 to 3.30.6 (#48478)
Bumps [github/codeql-action](https://github.com/github/codeql-action) from 3.30.5 to 3.30.6.
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](3599b3baa1...64d10c1313)

---
updated-dependencies:
- dependency-name: github/codeql-action
  dependency-version: 3.30.6
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-10-13 16:02:16 +02:00
Samuel Attard
52929c93db build: fail publish when upload fatal errors (#48537)
We logged a fatal error but didn't exit with code 1 so the publish kept going. This was caught by a sanity check later down the release process but would have been quicker to fail out here.

Also adds some code to maybe workaround the underlying auth error
2025-10-13 12:53:52 +02:00
Shelley Vohr
dd25a6361b fix: auth required websocket crash (#48510) 2025-10-13 10:13:32 +02:00
Zuohui Yang
16b5776b01 fix: launch crash when null device is disabled on Windows (#47870)
fix: fix launch crash when null device is disabled on Windows

add node flag node::ProcessInitializationFlags::kNoStdioInitialization

Co-authored-by: yangzuohui <yangzuohui@bytedance.com>
Co-authored-by: yangliu <yangliu.leo@bytedance.com>
2025-10-11 18:00:04 -04:00
David Sanders
cbf5c3331f ci: fix release branch name in build stats script (#48533) 2025-10-10 22:28:09 -07:00
David Sanders
3359f90389 ci: upload build effective cache hit rate stats to Datadog (#48509) 2025-10-10 19:55:21 -07:00
Erick Zhao
cf9fa5ef65 docs: unmark asar integrity as experimental and clean docs (#48434) 2025-10-10 12:56:48 -07:00
Niklas Wenzel
550e054168 docs: update Azure Trusted Signing availability (#48494)
* docs: update Azure Trusted Signing availability

Source: https://github.com/Azure/trusted-signing-action/issues/93#issuecomment-3383517386

* docs: remove unused link
2025-10-10 11:43:29 -04:00
Shelley Vohr
b992ead837 fix: dialog.showMessageBox defaultid on Windows (#48216)
* fix: dialog.showMessageBox defaultid on Windows

* Update shell/browser/ui/message_box_win.cc

Co-authored-by: Robo <hop2deep@gmail.com>

---------

Co-authored-by: Robo <hop2deep@gmail.com>
2025-10-10 15:39:23 +02:00
Shelley Vohr
11f76118db fix: unexpected openExternal dialog on macOS Tahoe (#48502)
fix: unexpected openExternal dialog on macOS Tahoe
2025-10-10 12:48:44 +02:00
Robo
37c7487600 fix: crash when inspector evaluates on provisional frames (#48503) 2025-10-10 11:34:09 +02:00
reito
9e46efb8f7 feat: offscreen rendering support rgbaf16 hdr output format. (#48265)
* feat: offscreen rendering support rgbaf16

* docs: update doc

* docs: update doc.
2025-10-09 10:33:34 +02:00
dependabot[bot]
9c38917a14 build(deps): bump actions/github-script from 7.0.1 to 8.0.0 (#48329)
Bumps [actions/github-script](https://github.com/actions/github-script) from 7.0.1 to 8.0.0.
- [Release notes](https://github.com/actions/github-script/releases)
- [Commits](60a0d83039...ed597411d8)

---
updated-dependencies:
- dependency-name: actions/github-script
  dependency-version: 8.0.0
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-10-09 10:33:24 +02:00
zoy
3a53c71324 fix: broken transparent window styles on resizable change (#48378)
* fix: wrong api call

* fix: consistency of the resize state

* fix: edge cases

* chore: add detailed comments

* fix: lint

* chore: only windows

* chore: use transparent
2025-10-09 09:49:20 +02:00
David Sanders
0d478ec69c ci: ignore lost communication with server annotation in audit (#48493) 2025-10-09 09:48:56 +02:00
Erick Zhao
9143f7c6e2 docs: clarify postinstall requirements (#48485)
postinstall
2025-10-09 09:48:47 +02:00
Erick Zhao
df86312e2f docs: add note for node_modules for Yarn and pnpm (#48484)
* Add instructions on using node_modules with Yarn

* update text for pnpm

---------

Co-authored-by: CodingOtto <otto+github@fysiker.fi>
2025-10-09 09:48:22 +02:00
Ulises Gascón
ffbae02a95 docs: add security escalation policy (#48317) 2025-10-08 15:19:07 -07:00
Sam Maddock
a87ee21f5c build: bump version in .nvmrc to 22 (#48413) 2025-10-08 14:21:55 -04:00
electron-roller[bot]
ea8f43f9b9 chore: bump node to v22.20.0 (main) (#48383)
* chore: bump node in DEPS to v22.20.0

* chore: fixup patches

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
2025-10-08 15:19:08 +02:00
Fedor Indutny
e8e91c331a feat: dynamic ESM import in preload without context isolation (#48375)
Dynamic ESM import in non-context-isolated preload

Extend `HostImportModuleWithPhaseDynamically`'s routing to support
Node.js import resolution in non-context-isolated preloads through
`v8_host_defined_options` length check. The length of host defined
options is distinct between Blink and Node.js and we can use it to
determine which resolver to use.
2025-10-08 10:44:09 +02:00
Charles Kerr
49c1139ab9 chore: remove unused reference to api::BrowserView (#48474)
chore: remove unused reference to api::BrowserView

Unused since #35658 / 15c60143
2025-10-08 10:43:28 +02:00
dependabot[bot]
16bcd645b5 build(deps): bump actions/stale from 9.1.0 to 10.1.0 (#48477)
Bumps [actions/stale](https://github.com/actions/stale) from 9.1.0 to 10.1.0.
- [Release notes](https://github.com/actions/stale/releases)
- [Changelog](https://github.com/actions/stale/blob/main/CHANGELOG.md)
- [Commits](5bef64f19d...5f858e3efb)

---
updated-dependencies:
- dependency-name: actions/stale
  dependency-version: 10.1.0
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-10-08 09:56:23 +02:00
John Kleinschmidt
6756974828 build: fixup chromedriver and mksnapshot (#48470)
* build: update build tools to get proper exit codes from e build

xref: https://github.com/electron/build-tools/pull/759

* build: target zips directly

mksnapshot and chromedriver have issues with siso trying to run a separate build and zip step, so just target the zip target

* build: don't unzip chromedriver and mksnapshot in tests

The contents of these files are not used in testing, so we shouldn't unzip them.
2025-10-06 23:22:55 -04:00
Keeley Hammond
d6dfd4ed7a build: handle Metal toolchain being unbundled from Xcode 26 (#48467)
* chore: add metal patch dir

* chore: cherry-pick 2f564f1ca07b from angle (#48465)

* chore: update patch
2025-10-06 10:17:46 -04:00
Charles Kerr
a1ca9a8d55 refactor: DRY in App::SetAppLogPath() (#48452) 2025-10-05 12:32:28 -05:00
Charles Kerr
38e491689a perf: avoid a little extra work in InvokeIpcCallback() (#48456)
perf: two minor perf refactors in InvokeIpcCallback()

1. Allocate the CallbackScope on the stack instead of the heap
2. Skip a redundant call to  node::Environment::GetCurrent()
2025-10-04 21:52:53 -07:00
Niklas Wenzel
6e2be00f0f docs: recommend calling renderer process modules from preload script (#48427) 2025-10-04 18:44:10 +02:00
Charles Kerr
497b5a68a4 docs: clarify optional args in webFrame.executeJavaScript() (#48447) 2025-10-04 09:28:06 -05:00
Kaiichiro Ota
715808ecbe docs: mention that webUtils should be used via preload script (#45861)
* docs: mention that webUtils should be used via preload script

* docs: suppress lint errors

* docs: clarify webUtils usage scope

* docs: exclude potentially dangerous alert() in the example code

* docs: minor change

* docs: minor change

* docs: minor change

* docs: minor change

* docs: minor change

* docs: minor change

* docs: minor change

* docs: minor change

* docs: minor change

* docs: minor change

* docs: make linter happy

* docs: apply suggestion

Co-authored-by: Samuel Attard <samuel.r.attard@gmail.com>

* docs: apply suggestion

Co-authored-by: Samuel Attard <samuel.r.attard@gmail.com>

* docs: apply suggestion

Co-authored-by: Samuel Attard <samuel.r.attard@gmail.com>

* docs: minor change

* docs: minor change

* docs: remove preload line

---------

Co-authored-by: Niklas Wenzel <dev@nikwen.de>
Co-authored-by: Samuel Attard <samuel.r.attard@gmail.com>
2025-10-03 13:07:38 -07:00
Charles Kerr
01cab978f7 refactor: remove gin_helper::Arguments (#48374)
* refactor: make api::Clipboard::GetClipboardBuffer() private

* refactor: move GetClipboadBuffer() into anonymous namespace

* refactor: use gin::Arguments in StopRecording()

* refactor: use gin::Arguments in ImageView::New()

* refactor: use gin::Arguments in AppendSwitch()

* refactor: use gin::Arguments WebContentsView::New()

* refactor: make gin::Arguments arg const in WrappableBase::InitWithArgs()

This makes explicit that we are using it for wrapper + isolate, not the args values

* refactor: remove gin_helper::Arguments arg from ExposeAPI()

refactor: remove gin_helper::Arguments arg from ExposeAPIInWorld()

* refactor: remove gin_helper::Arguments arg from ElectronBindings::GetSystemMemoryInfo()

* refactor: remove gin_helper::Arguments arg from preload_utils::GetBinding()

* refactor: use gin::Arguments in OpenExternal()

* refactor: use gin::Arguments in ExecuteInWorld()

* refactor: use gin::Arguments in ExecuteJavaScript()

* refactor: use gin::Arguments in InvokeNew()

* refactor: use gin::Arguments in ExecuteJavaScriptInIsolatedWorld()

* refactor: remove unused GetNextArgument() marshaller for gin_helper::Arguments

* refactor: remove unused #include gin_helper/arguments.h

* chore: remove unused gin_helper::Arguments

* fixup! refactor: use gin::Arguments in ExecuteJavaScriptInIsolatedWorld()

Xref: https://github.com/electron/electron/pull/48447
2025-10-03 14:10:29 -05:00
zoy
7cb1552614 fix: accentColor set distinguishes the frame (#48405)
* fix: accentColor set distinguishes the frame

* chore: invalid change

* fix: lint
2025-10-03 20:10:18 +02:00
Niklas Wenzel
49c37b4daa docs: update allowed window.open options (#48428) 2025-10-03 01:29:26 +02:00
Robo
37a115b8fd fix: initialze featurelist before parsing features (#48411) 2025-10-03 01:18:14 +02:00
Shelley Vohr
e7e29ea876 fix: snapped window restoring to correct position (#48296) 2025-10-02 18:14:48 +02:00
Erick Zhao
b40a4befd4 docs: fix formatting in asar integrity (#48431) 2025-10-01 22:27:28 -07:00
dependabot[bot]
61a7303531 build(deps): bump github/codeql-action from 3.30.1 to 3.30.5 (#48420)
Bumps [github/codeql-action](https://github.com/github/codeql-action) from 3.30.1 to 3.30.5.
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](f1f6e5f6af...3599b3baa1)

---
updated-dependencies:
- dependency-name: github/codeql-action
  dependency-version: 3.30.5
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-09-30 18:36:57 +02:00
Fedor Indutny
6f9cd718c4 fix: runtime JS error that crashes GetPackageJSON (#48293)
We overriden the `GetPackageJSON` in Node.js to let us read files
straight from the ASAR file instead of disk. The override works by
providing a JS method with the limitation that it should not throw a
runtime error. However, this invariant was accidentally violated by
`asar.splitPath` that sometimes contrary to its' TypeScript definition
returned `false`.
2025-09-30 18:32:13 +02:00
Samuel Attard
a95180e080 build: add missing copied tarball to cloudstore paths (#48408)
It's guarunteed that `iojs-*` and `node-*` were the same origin file (we azcopy them) but this was missing in logs and it annoyed me
2025-09-29 11:16:39 -07:00
BILL SHEN
d4a5fdc8fc fix: add missed enum SaveRequestType to PdfViewerPrivate function (#48372)
fix: add missed SaveRequestType enum to PdfViewerPrivate function
2025-09-26 16:34:06 -04:00
avarayr
3a7c6dd4a5 fix: MacOS 26 Tahoe - stop overriding private cornerMask API to fix WindowServer GPU load (#48376)
fix: macOS stop overriding private cornerMask API to fix WindowServer GPU load spike

Electron fetched a custom `_cornerMask` for `ElectronNSWindow` to smooth
vibrancy corners. On macOS 15 (Tahoe) that private hook forces the window
shadow to be rendered from a fully transparent surface, causing the
WindowServer GPU load regression. Remove the `cornerMask` property and
the `_cornerMask` override so we stay on Apple’s default shadow path.
2025-09-26 12:41:16 -07:00
Robo
26e886c517 fix: disable NSAutoFillHeuristicController on macOS 26 (#48379)
Co-authored-by: Keeley Hammond <khammond@slack-corp.com>
2025-09-26 08:40:55 +09:00
Charles Kerr
26a473db98 refactor: make api::Menu inherit from gin::Wrappable (#48351)
* refactor: make api::Menu inherit from gin::Wrappable*

* refactor: make api::Menu::kWrapperInfo const

* refactor: use three-arg version of GetConstructor in Menu

refactor: undo branch changes to two-arg version of GetConstructor

* fixup! refactor: make api::Menu inherit from gin::Wrappable*

fix: return type of Menu::New

* fixup! refactor: make api::Menu inherit from gin::Wrappable*

make MenuMac's constructor public so that cppgc can use it

* refactor: Pinnable -> SelfKeepAlive
2025-09-24 19:42:22 -05:00
Charles Kerr
6661457cdf refactor: prefer upstream gin::Arguments::ThrowTypeError() over gin_helper (#48368)
* refactor: use gin::Arguments::ThrowTypeError() in AutoUpdater::SetFeedURL()

* refactor: use gin::Arguments::ThrowTypeError() in Browser::Focus()

* refactor: use gin::Arguments::ThrowTypeError() in SystemPreferences::SetUserDefault()

* refactor: use gin::Arguments::ThrowTypeError() in UtilityProcessWrapper::Create()

* refactor: use gin::Arguments::ThrowTypeError() in UtilityProcessWrapper::PostMessage()

* refactor: use gin::Arguments::ThrowTypeError() in ElectronBundleMover::ShouldContinueMove()

* refactor: use gin::Arguments::ThrowTypeError() in OnClientCertificateSelected()

* refactor: use gin::Arguments::ThrowTypeError() in Session::ClearData()

* refactor: use gin::Arguments::ThrowTypeError() in ElectronBrowserContext::DisplayMediaDeviceChosen()

* refactor: use gin::Arguments::ThrowTypeError() in WebContents::ReplaceMisspelling()

* refactor: use gin::Arguments::ThrowTypeError() in WebContents::Print()

* chore: iwyu shell/common/gin_helper/error_thrower.h
2025-09-24 19:10:05 -05:00
John Kleinschmidt
b51e82c5fb test: rerun failed tests individually (#48205)
* test: rerun failed tests individually

* ci: use screencapture-nag-remover

Needed to bypass the popup message "bash" is requesting to bypass the system private window picker and directly access your screen and audio.

* Revert "chore: test with 1st quadrant of the window"

No longer needed because of the addition of the
screencapture-nag-remover script.

This reverts commit f4a7e04c0b.

* test: fixup navigationHistory flake

* rerun test up to 3 times
2025-09-24 13:35:14 -07:00
Charles Kerr
235fdc41f6 refactor: use gin::Arguments in BaseWindow (#48355)
* refactor: make api::Clipboard::GetClipboardBuffer() private

* refactor: move GetClipboadBuffer() into anonymous namespace

* refactor: use gin::Arguments in BaseWindow::MoveAbove()

refactor: use gin::Arguments in BaseWindow::SetAlwaysOnTop()

refactor: use gin::Arguments in BaseWindow::SetIgnoreMouseEvent()

* refactor: use gin::Arguments in BaseWindow::SetProgresBar()

* refactor: use gin::Arguments in BaseWindow::SetVisibleOnAllWorkspaces()

* refactor: use gin::Arguments in BaseWindow::SetVibrancy()

* refactor: use gin::Arguments in BaseWindow::SetAspectRatio()

* refactor: use gin::Arguments in BaseWindow::PreviewFile()

* refactor: use gin::Arguments in BaseWindow::SetThumbarButtons()

* refactor: use gin::Arguments in BaseWindow::SetBounds()

* refactor: use gin::Arguments in BaseWindow::SetContentBounds()

* refactor: use gin::Arguments in BaseWindow::SetSize()

* refactor: use gin::Arguments in BaseWindow::SetContentSize()

* refactor: use gin::Arguments in BaseWindow::SetSheetOffset()

* refactor: use gin::Arguments in BaseWindow::SetPosition()

* refactor: use gin::Arguments in BaseWindow::AddTabbedWindow()

* refactor: use gin::Arguments in BaseWindow::SetParentWindow()

* refactor: use gin::Arguments in BaseWindow::BaseWindow()

* refactor: use gin::Arguments in BaseWindow::SetAccentColor()

* refactor: use gin::Arguments in BaseWindow::SetTitleBarOverlay()
2025-09-24 09:39:16 -04:00
Charles Kerr
6bbbc1232e chore: remove unused, undocumented, untested executionMode arg from web_frame.executeJavaScriptInIsolatedWorld() (#48361)
chore: remove unused, undocumented execution mode arg from web_frame.executeJavaScriptInIsolatedWorld()
2025-09-24 08:13:49 -05:00
Niklas Wenzel
49335805d5 docs: mention setContentProtection macOS limitations (#48290) 2025-09-23 16:28:21 -05:00
John Kleinschmidt
b27e721f69 build: update patches (#48364)
chore: update patches
2025-09-23 16:37:38 -04:00
electron-roller[bot]
1fda08b8c8 chore: bump chromium to 142.0.7417.0 (main) (#48275)
* chore: bump chromium in DEPS to 142.0.7401.0

* 6911185: Reland "Send touch moves async immediately after scroll starts."

https://chromium-review.googlesource.com/c/chromium/src/+/6911185

* 6906887: mac: click through content area in main window

https://chromium-review.googlesource.com/c/chromium/src/+/6906887

* 6916667: Expose helper to eliminate duplicate recipes.

https://chromium-review.googlesource.com/c/chromium/src/+/6916667

* 6909842: Switch LegacyRenderWidgetHostHWND from atlcrack.h to msg_util.h.

https://chromium-review.googlesource.com/c/chromium/src/+/6909842

* 6884056: Remove the SecKeychain implementation for the Keychain interface

https://chromium-review.googlesource.com/c/chromium/src/+/6884056

* 6904906: Remove `WTF::` in renderer/core/[p-x].*/

https://chromium-review.googlesource.com/c/chromium/src/+/6904906

* 6556585: [persistent_cache]: PersistentCache for CodeCache

https://chromium-review.googlesource.com/c/chromium/src/+/6556585

* 6904864: Layout: Support abort on the text placeholder layout

https://chromium-review.googlesource.com/c/chromium/src/+/6904864

* chore: fixup patch indices

* chore: bump chromium in DEPS to 142.0.7402.0

* fixup! 6556585: [persistent_cache]: PersistentCache for CodeCache

* chore: fixup patch indices

* 6905244: [api] Remove deprecated `GetIsolate`

https://chromium-review.googlesource.com/c/v8/v8/+/6905244

* 6897694: Remove NativeTheme::UserHasContrastPreference().

https://chromium-review.googlesource.com/c/chromium/src/+/6897694

* 6897477: Remove GetPlatformHighContrastColorScheme() and enum.

https://chromium-review.googlesource.com/c/chromium/src/+/6897477

* 6918198: Reland "Rename display::Screen::GetScreen() to display::Screen::Get()"

https://chromium-review.googlesource.com/c/chromium/src/+/6918198

* 6907147: [LNA] add use counter for websocket mixed-content issues

https://chromium-review.googlesource.com/c/chromium/src/+/6907147

* 6914538: Replace WTF::String with blink::String

https://chromium-review.googlesource.com/c/website/+/6914538

* 6892538: [video pip] Allow touchscreen users to toggle live caption

https://chromium-review.googlesource.com/c/chromium/src/+/6892538

* chore: fix patch

* chore: bump chromium in DEPS to 142.0.7403.0

* build: remove ninja logs

* chore: fixup patch indices

* 6920670: [PDF] Change pdf_extension_util to return dictionaries

https://chromium-review.googlesource.com/c/chromium/src/+/6920670

* 6917864: Devirtualize and inline various NativeTheme getters.

https://chromium-review.googlesource.com/c/chromium/src/+/6917864

* 6920873: [PDF] Simplify PDFDocumentHelperClient::OnSaveURL()

https://chromium-review.googlesource.com/c/chromium/src/+/6920873

* build: don't kill blink/web_tests

* 6923655: Roll libc++ from 954086abf121 to b87b2bb112f8 (4 revisions)

https://chromium-review.googlesource.com/c/chromium/src/+/6923655

* 6905242: Reland "[CSP] Clarify report-only console messages."

https://chromium-review.googlesource.com/c/chromium/src/+/6905242

* fixup! 6897694: Remove NativeTheme::UserHasContrastPreference().

* chore: bump chromium in DEPS to 142.0.7405.0

* 6910012: [LNA] Enable LNA enforcement by default

https://chromium-review.googlesource.com/c/chromium/src/+/6910012

* 6929444: Combine GetInstanceForXXX() implementations.

https://chromium-review.googlesource.com/c/chromium/src/+/6929444

* 6927873: Rename native_widget_types.h -> native_ui_types.h

https://chromium-review.googlesource.com/c/chromium/src/+/6927873

* 6853978: Init perfetto really early in WebView

https://chromium-review.googlesource.com/c/chromium/src/+/6853978

* 6874886: Use only one picker observer to avoid getting duplicate notifications

https://chromium-review.googlesource.com/c/chromium/src/+/6874886

* chore: fixup patch indices

* fix: Protocol complex inline dtor

* chore: bump chromium in DEPS to 142.0.7407.0

* chore: bump chromium in DEPS to 142.0.7409.0

* chore: bump chromium in DEPS to 142.0.7411.0

* chore: bump chromium in DEPS to 142.0.7413.0

* fixup! 6905242: Reland "[CSP] Clarify report-only console messages."

* 6927233: Remove NativeTheme "use dark colors" bit.

https://chromium-review.googlesource.com/c/chromium/src/+/6927233

* chore: fixup patch indices

* 6899206: [PermissionOptions] Multi-state permission subscriptions & setting changes

https://chromium-review.googlesource.com/c/chromium/src/+/6899206

* chore: bump chromium in DEPS to 142.0.7415.0

* 6936895: [headless] Remove headless flag from views::Widget class

https://chromium-review.googlesource.com/c/chromium/src/+/6936895

We should probably followup on this to see if there is a way to do this without reverting this CL.

* 6937023: Reland "Use new DBus type system in dbus_xdg::Request"

https://chromium-review.googlesource.com/c/chromium/src/+/6937023

* chore: update patches

* 6944749: Add GN visibility list to //components/os_crypt/sync

https://chromium-review.googlesource.com/c/chromium/src/+/6944749

* Further replace sub_capture_target_version with CaptureVersion

https://chromium-review.googlesource.com/c/chromium/src/+/6935455

* fixup for lint

* chore: update filenames.libcxx.gni

* chore: bump chromium in DEPS to 142.0.7417.0

* 6944136: Reorder NativeTheme headers/.cc files.

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6944136

* 6939701: [DSSC][4] Make FSVCI objects aware of their capture-version-source

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6939701

* 6944404: Remove extraneous callback call

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6944404

* 6936124: [FPF-CI]: Introduce blink::NoiseToken for fingerprinting protection

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6936124

* chore: update patches

* fixup! 6927233: Remove NativeTheme "use dark colors" bit.

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6927233

* fixup! 6917864: Devirtualize and inline various NativeTheme getters.

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6917864

* 6937588: Add initial OsSettingsProvider object, supplying caret blink interval.

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6937588

* fixup! 6905242: Reland "[CSP] Clarify report-only console messages."

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6905242

* 6907515: Replace SingletonHwndObserver with a CallbackList on SingletonHwnd.

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6907515

* 6910482: [Save to Drive] Implement retry functionality

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6910482

* fixup! 6927233: Remove NativeTheme "use dark colors" bit.

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6927233

* Revert "build: remove ninja logs"

This reverts commit 72874740fd.

* test: fix flakey test picked from PR 48205

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
Co-authored-by: John Kleinschmidt <jkleinsc@electronjs.org>
Co-authored-by: David Sanders <dsanders11@ucsbalum.com>
Co-authored-by: Alice Zhao <alicelovescake@anthropic.com>
2025-09-22 20:16:27 -07:00
Charles Kerr
19256a07dd refactor: use gin::Arguments in api::Clipboard (#48354)
* refactor: make api::Clipboard::GetClipboardBuffer() private

* refactor: remove unused gin_helper::Arguments* arg from Clipboard::ReadBuffer()

* refactor: remove unused gin_helper::Arguments* arg from Clipboard::ReadBookmark()

* refactor: move GetClipboadBuffer() into anonymous namespace

* refactor: use gin::Arguments in api::Clipboard
2025-09-23 04:12:47 +09:00
John Kleinschmidt
f62d7254c4 build: update build tools to get siso for forks fix (#48345) 2025-09-18 00:04:09 -04:00
Keeley Hammond
c7aa0b537d chore: cherry-pick ec6c18478382 from v8 (#48335)
* chore: cherry-pick ec6c18478382 from v8

* chore: update patches
2025-09-16 19:08:15 -07:00
Robo
048d620701 fix: remove unneeded handlescope from JS callbacks (#48318)
fix: remove handlescope from JS callbacks
2025-09-16 06:56:38 +09:00
Charles Kerr
15cdae1cf0 refactor: make api::NetLog inherit from gin::Wrappable (#48308)
* refactor: remove unused v8::Isolate* arg from NetLog ctor

* refactor: allocate api::NetLog on cpp heap

* refactor: make electron::api::Session::net_log_ a cppgc::Member<api::NetLog>

* refactor: remove unnecessary EscapableHandleScope

* chore: code style consistency
2025-09-16 06:29:46 +09:00
Shelley Vohr
bac383c219 feat: add fileSystem to ses.setPermissionCheckHandler (#48170)
feat: add fileSystem to ses.setPermissionCheckHandler
2025-09-15 17:00:58 -04:00
John Kleinschmidt
49eb165ef9 ci: Use Local Execution, Remote Caching (LERC) for fork PRS (#48319)
cleanup
2025-09-15 16:31:49 -04:00
Charles Kerr
a468ed7f10 refactor: narrow or remove gin arguments (#48300)
* refactor: narrow App:SetJumpList() arg from gin::Arguments* to v8::Isolate*

* refactor: narrow WebContents::AddWorkSpace() arg from gin::Arguments* to v8::Isolate*

* refactor: narrow ShowMessageBox() arg from gin::Arguments* to v8::Isolate*

* refactor: narrow ShowOpenDialog() arg from gin::Arguments* to v8::Isolate*

* refactor: remove unused gin::Arguments* arg from OverrideGlobalPropertyFromIsolatedWorld()

* refactor: narrow WebContents::StartDrag() arg from gin::Arguments* to v8::Isolate*

* refactor: narrow NetLog::StopLogging() arg from gin::Arguments* to v8::Isolate*

* refactor: narrow Protocol::IsProtocolHandled() arg from gin::Arguments* to v8::Isolate*
2025-09-13 08:19:07 +09:00
Calvin
5444738721 fix: set ozone platform for wayland (#48301)
* fix: set ozone platform for wayland

* whoops, includes. thx charles
2025-09-13 08:17:06 +09:00
Charles Kerr
a6959ca97b refactor: allocate api::Debugger on cpp heap (#48266)
* refactor: remove unused isolate arg from Debugger ctor

* refactor: make Debugger ctor, dtor public

needed for cppgc::MakeGarbageCollected()

This is what upstream does, e.g. https://chromium-review.googlesource.com/c/chromium/src/+/6722236

* fixup! refactor: remove unused isolate arg from Debugger ctor

mark Debugger ctor as explicit

* refactor: in EventEmitterMixin, handle both old and new WrapperInfo types

* refactor: make electron::api::Debugger inherit from gin::Wrappable

* refactor: add api::Debugger::GetTypeName()

* refactor: add api::Debugger::GetClassName()
2025-09-11 16:03:17 -04:00
dependabot[bot]
45353ae38c build(deps): bump actions/setup-node from 4.4.0 to 5.0.0 (#48282)
Bumps [actions/setup-node](https://github.com/actions/setup-node) from 4.4.0 to 5.0.0.
- [Release notes](https://github.com/actions/setup-node/releases)
- [Commits](49933ea528...a0853c2454)

---
updated-dependencies:
- dependency-name: actions/setup-node
  dependency-version: 5.0.0
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-09-10 21:35:54 -05:00
Charles Kerr
f702327dce refactor: avoid unused inheritance in ServiceWorkerMain (#48279)
ServiceWorkerMain does not need to inherit from EventEmitterMixin
2025-09-10 11:16:35 -05:00
dependabot[bot]
fda3a3d493 build(deps): bump github/codeql-action from 3.29.11 to 3.30.1 (#48283)
Bumps [github/codeql-action](https://github.com/github/codeql-action) from 3.29.11 to 3.30.1.
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](3c3833e0f8...f1f6e5f6af)

---
updated-dependencies:
- dependency-name: github/codeql-action
  dependency-version: 3.30.1
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-09-10 09:47:34 -05:00
Michaela Laurencin
dae5dad167 docs: update release timeline for unsupported v35 (#48285) 2025-09-09 15:03:48 -07:00
John Kleinschmidt
940ebb6c7a chore: update patches (#48278) 2025-09-08 15:44:47 -04:00
electron-roller[bot]
793565e4be chore: bump chromium to 141.0.7390.7 (main) (#48212)
* chore: bump chromium in DEPS to 141.0.7381.3

* chore: update patches

* chore: bump chromium in DEPS to 141.0.7382.0

* chore: update patches

* chore: bump chromium in DEPS to 141.0.7384.0

* chore: bump chromium in DEPS to 141.0.7386.0

* [Extensions] Move devtools_page and chrome_url_overrides handlers

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6862700

* Reland "[api] Advance deprecation of GetIsolate"

Refs https://chromium-review.googlesource.com/c/v8/v8/+/6875273

* Move "system integrated UI" concept out of NativeTheme.

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6867375

* chore: update patches

* Reland "[PermissionOptions] Return PermissionResult in callback for requests"

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6851838

* Reland "[exit-time-destructors] Enable by default"

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6859042

* chore: update patches

* [FSA] Revoke Read access after removing file via FileSystemAccess API

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6677249

* chore: IWYU

* [DevToolsUIBindings] Accept an object for `dispatchHttpRequest` params

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6877528

* chore: IWYU

* Pass navigation UI parameters on EnterFullscreen in EAM

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6874923

* chore: rm band-aid_over_an_issue_with_using_deprecated_nsopenpanel_api.patch

* Remove unused PreHandleMouseEvent

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6880411

* 6878583: siso: update to version 1.4.1

https://chromium-review.googlesource.com/c/chromium/src/+/6878583

* Fold native_theme_browser into native_theme.

https://chromium-review.googlesource.com/c/chromium/src/+/6882627

* fixup: Reland "[exit-time-destructors] Enable by default

https://chromium-review.googlesource.com/c/chromium/src/+/6859042

* chore: update filenames.libcxx.gni

* chore: IWYU

* fixup: chore: IWYU

* fixup: Reland "[exit-time-destructors] Enable by default

* fixup: Reland "[exit-time-destructors] Enable by default

* Remove common_theme.*; place its method in NativeTheme instead.

https://chromium-review.googlesource.com/c/chromium/src/+/6886029

* fixup: Reland "[exit-time-destructors] Enable by default

* Better track when WebPreferences need updates for color-related changes.

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6886797

* chore: bump chromium in DEPS to 141.0.7390.7

* 6904664: Reland "Make BrowserContext::GetPath() const"

https://chromium-review.googlesource.com/c/chromium/src/+/6904664

* Restore read access after certain file modification operations

https://chromium-review.googlesource.com/c/chromium/src/+/6861041

* fixup: Move "system integrated UI" concept out of NativeTheme.

* fixup: Reland "[exit-time-destructors] Enable by default

* chore: update patches

* 6906096: Remove GetSysSkColor().

https://chromium-review.googlesource.com/c/chromium/src/+/6906096

* Inline implementation of SysColorChangeListener into the lone user.

https://chromium-review.googlesource.com/c/chromium/src/+/6905083

Also 6906096: Remove GetSysSkColor(). | https://chromium-review.googlesource.com/c/chromium/src/+/6906096

* fixup: 6906096: Remove GetSysSkColor()

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: deepak1556 <hop2deep@gmail.com>
Co-authored-by: John Kleinschmidt <jkleinsc@electronjs.org>
2025-09-08 12:57:15 +02:00
electron-roller[bot]
1f322ebce3 chore: bump node to v22.19.0 (main) (#48222)
* chore: bump node in DEPS to v22.19.0

* chore: fixup patch indices

* crypto: add tls.setDefaultCACertificates()

https://github.com/nodejs/node/pull/58822

* esm: js-string Wasm builtins in ESM Integration

https://github.com/nodejs/node/pull/59179

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
2025-09-05 17:16:45 -04:00
Samuel Attard
f009e077f2 build: update spec deps for clean audit (#48238) 2025-09-03 15:05:49 -04:00
Calvin
fed73040e2 docs: move some planned breaking changes to 39 (#48236) 2025-09-01 14:55:11 -07:00
Shelley Vohr
828fd59a72 fix: file-only picker incorrectly allowing some directories (#48198) 2025-08-29 13:14:45 -04:00
Shelley Vohr
e892840975 fix: ensure dragging works again after emitting contextmenu event (#48199) 2025-08-29 10:37:37 -04:00
Shelley Vohr
7373173e44 fix: showMessageDialog should center dialog to parent (#48181) 2025-08-29 09:56:51 +02:00
electron-roller[bot]
5d5e672f17 chore: bump chromium to 141.0.7361.0 (main) (#48054)
* chore: bump chromium in DEPS to 141.0.7352.0

* chore: update patches

* 6830573: Revert 'Migrate WrappableWithNamedPropertyInterceptor to gin::Wrappable' | https://chromium-review.googlesource.com/c/chromium/src/+/6830573

* chore: bump chromium in DEPS to 141.0.7354.0

* chore: bump chromium in DEPS to 141.0.7356.0

* chore: bump chromium in DEPS to 141.0.7357.0

* chore: bump chromium in DEPS to 141.0.7359.0

* chore: bump chromium in DEPS to 141.0.7361.0

* 6838518: [Mac] Correctly deallocate sandbox error buffers and prevent crash resulting from nullptr assignment | https://chromium-review.googlesource.com/c/chromium/src/+/6838518

* 6850973: Reland "Use base::ByteCount in base::SysInfo." | https://chromium-review.googlesource.com/c/chromium/src/+/6850973

* 6506565: [FPF-CI] Create initial NoiseHash in the browser. | https://chromium-review.googlesource.com/c/chromium/src/+/6506565

* chore: update patches

* fixup! 6850973: Reland "Use base::ByteCount in base::SysInfo." | https://chromium-review.googlesource.com/c/chromium/src/+/6850973

* fixup! 6506565: [FPF-CI] Create initial NoiseHash in the browser. | https://chromium-review.googlesource.com/c/chromium/src/+/6506565

* fix: unsafe buffer warning in fix_properly_honor_printing_page_ranges.patch

* fix: FTBFS in src_remove_dependency_on_wrapper-descriptor-based_cppheap.patch

This change should be upstreamed.

Fixes this error:

../../third_party/electron_node/src/env.cc:606:3: error: no matching function for call to 'Wrap'
  606 |   v8::Object::Wrap<v8::CppHeapPointerTag::kDefaultTag>(
      |   ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
../../v8/include/v8-object.h:1076:14: note: candidate function template not viable: cannot convert argument of incomplete type 'void *' to 'v8::Object::Wrappable *' for 3rd argument
 1076 | void Object::Wrap(v8::Isolate* isolate, const v8::Local<v8::Object>& wrapper,
      |              ^
 1077 |                   v8::Object::Wrappable* wrappable) {
      |                   ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
../../v8/include/v8-object.h:1084:14: note: candidate function template not viable: no known conversion from 'Local<Object>' to 'const PersistentBase<Object>' for 2nd argument
 1084 | void Object::Wrap(v8::Isolate* isolate, const PersistentBase<Object>& wrapper,
      |              ^                          ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
../../v8/include/v8-object.h:1093:14: note: candidate function template not viable: no known conversion from 'Local<Object>' to 'const BasicTracedReference<Object>' for 2nd argument
 1093 | void Object::Wrap(v8::Isolate* isolate,
      |              ^
 1094 |                   const BasicTracedReference<Object>& wrapper,
      |                   ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
1 error generated.

* [v8-init] Access crash key only from main thread | https://chromium-review.googlesource.com/c/chromium/src/+/6827167

* chore: e patches all

* chore: remove chore_restore_some_deprecated_wrapper_utility_in_gin.patch from patches

this remove line got re-added when rebasing roller/chromium/main

* chore: e patches all

* fix: include base/time/time.h when using base::Time

* chore: update patches

* Make --host-rules an alias for --host-resolver-rules.

Refs https://chromium-review.googlesource.com/c/chromium/src/+/4867872

* ci: update BUILD_TOOLS_SHA

Refs https://github.com/electron/build-tools/pull/746

* [Fontations] Remove Fontations suffix from font names

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6835930

* temp: debug macOS addon build failure

* Revert "temp: debug macOS addon build failure"

This reverts commit 40bc8abab65dc83e17c4ab97cb6e7522a193fb44.

* test: run tests with Xcode 16.4

* ci: fix tccdb update for macOS 15

* spec: disable opening external application for loadURL

on macOS opening unknown external application will bring
up dialog to choose apps from application store which will
break our other test suites that want to capture screen
for pixel matching.

The loadURL spec that tests bad-scheme://foo is sufficient
that we hit the permission handler for openExternal since
at that point we already know the runtime gave up on handling
the scheme.

* chore: rebase patches

* chore: disable codesiging tests

* ci: update ScreenCaptureApprovals.plist for /bin/bash

* ci: try updating tcc permissions

* ci: update TCC permissions

Refs https://www.rainforestqa.com/blog/macos-tcc-db-deep-dive

* chore: test with 1st quadrant of the window

* chore: adjust for macOS 15 menubar height

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: Keeley Hammond <khammond@slack-corp.com>
Co-authored-by: Keeley Hammond <vertedinde@electronjs.org>
Co-authored-by: Charles Kerr <charles@charleskerr.com>
Co-authored-by: deepak1556 <hop2deep@gmail.com>
Co-authored-by: John Kleinschmidt <jkleinsc@electronjs.org>
2025-08-29 12:31:47 +09:00
LZL
e39943bf45 fix: BrowserWindow add the same BrowserView (#48053)
fix: BrowserWindow add the same BrowserView (#48057)
2025-08-28 10:31:41 +02:00
David Sanders
f331606e07 build: bump NMV to 140 (#48196) 2025-08-27 18:57:00 -07:00
David Sanders
cca55117e4 build: refactor Linux binary stripping to align with upstream (#47932) 2025-08-27 18:56:31 -07:00
Erick Zhao
bf29d2f0bd docs: fix some module headings (#48177) 2025-08-27 14:52:26 -07:00
John Kleinschmidt
fea1a2a987 ci: use free GH arm runners (#47872) 2025-08-27 10:01:36 -04:00
dependabot[bot]
a51c56aca9 build(deps): bump amannn/action-semantic-pull-request from 6.0.1 to 6.1.1 (#48175)
build(deps): bump amannn/action-semantic-pull-request

Bumps [amannn/action-semantic-pull-request](https://github.com/amannn/action-semantic-pull-request) from 6.0.1 to 6.1.1.
- [Release notes](https://github.com/amannn/action-semantic-pull-request/releases)
- [Changelog](https://github.com/amannn/action-semantic-pull-request/blob/main/CHANGELOG.md)
- [Commits](fdd4d3ddf6...48f256284b)

---
updated-dependencies:
- dependency-name: amannn/action-semantic-pull-request
  dependency-version: 6.1.1
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-08-27 13:52:36 +02:00
dependabot[bot]
89f25e6af3 build(deps): bump github/codeql-action from 3.29.10 to 3.29.11 (#48174)
Bumps [github/codeql-action](https://github.com/github/codeql-action) from 3.29.10 to 3.29.11.
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](96f518a34f...3c3833e0f8)

---
updated-dependencies:
- dependency-name: github/codeql-action
  dependency-version: 3.29.11
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-08-27 13:49:43 +02:00
Robo
e0db4046b2 refactor: allocate gin_helper::internal::Event on cpp heap (#48161) 2025-08-27 09:30:50 +09:00
Calvin
3b9130d815 docs: add release timeline for Electron 39 (#48167) 2025-08-26 14:19:56 -07:00
Shelley Vohr
52ed4646d9 chore: remove upstream OSR temp fix (#48162) 2025-08-26 16:22:45 -04:00
John Kleinschmidt
68098c317f build: remove no longer needed arg for siso (#48164)
* build: remove no longer needed arg for siso

* chore: test ffmpeg zip

* build: fix ffmpeg build with siso

* Revert "chore: test ffmpeg zip"

This reverts commit 2bbcc86039.
2025-08-25 16:46:36 -04:00
dependabot[bot]
52e0307cc1 build(deps): bump github/codeql-action from 3.29.7 to 3.29.10 (#48113)
Bumps [github/codeql-action](https://github.com/github/codeql-action) from 3.29.7 to 3.29.10.
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](51f77329af...96f518a34f)

---
updated-dependencies:
- dependency-name: github/codeql-action
  dependency-version: 3.29.10
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-08-25 13:23:15 +02:00
dependabot[bot]
7fffe77909 build(deps-dev): bump stream-json and @types/stream-json (#48114)
Bumps [stream-json](https://github.com/uhop/stream-json) and [@types/stream-json](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/stream-json). These dependencies needed to be updated together.

Updates `stream-json` from 1.8.0 to 1.9.1
- [Commits](https://github.com/uhop/stream-json/compare/1.8.0...1.9.1)

Updates `@types/stream-json` from 1.7.7 to 1.7.8
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/stream-json)

---
updated-dependencies:
- dependency-name: stream-json
  dependency-version: 1.9.1
  dependency-type: direct:development
  update-type: version-update:semver-minor
- dependency-name: "@types/stream-json"
  dependency-version: 1.7.8
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-08-25 12:58:38 +02:00
Robo
3ccb1bc0a8 refactor: allocate api::Session on cpp heap (#48141) 2025-08-25 18:52:06 +09:00
Shelley Vohr
0917ed5f6f fix: snapped restoration after minimization (#48142) 2025-08-22 14:37:45 -04:00
Samuel Attard
a67aad0f50 build: use siso instead of reclient (#47534) 2025-08-22 14:17:02 -04:00
reito
ceb6d28fd3 fix: webContent.fromId should be number instead of string (#48059) 2025-08-22 11:40:10 -04:00
Shelley Vohr
e12ab6708e chore: improve failed notification error messages on Windows (#48131) 2025-08-22 11:35:39 -04:00
Shelley Vohr
6101025368 fix: net.isOnline always true in utility processes (#48111)
* fix: net.isOnline always true in utilityProcesses

* Update shell/services/node/node_service.cc

Co-authored-by: Robo <hop2deep@gmail.com>

---------

Co-authored-by: Robo <hop2deep@gmail.com>
2025-08-22 14:30:41 +02:00
dependabot[bot]
97b0280ad4 build(deps): bump amannn/action-semantic-pull-request from 5.5.3 to 6.0.1 (#48115)
build(deps): bump amannn/action-semantic-pull-request

Bumps [amannn/action-semantic-pull-request](https://github.com/amannn/action-semantic-pull-request) from 5.5.3 to 6.0.1.
- [Release notes](https://github.com/amannn/action-semantic-pull-request/releases)
- [Changelog](https://github.com/amannn/action-semantic-pull-request/blob/main/CHANGELOG.md)
- [Commits](0723387faa...fdd4d3ddf6)

---
updated-dependencies:
- dependency-name: amannn/action-semantic-pull-request
  dependency-version: 6.0.1
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-08-21 10:44:27 +02:00
John Kleinschmidt
1044fe675d build: use new 7z command line switch (#48136)
-snld20 replaces -snld
2025-08-20 17:05:25 -04:00
John Kleinschmidt
42af60cc7e docs: update 38.0 breaking changes (#48117) 2025-08-20 14:15:01 -04:00
John Kleinschmidt
cadba11088 build: fixup docs only condition (#48128) 2025-08-20 12:58:54 -04:00
Shelley Vohr
8aeee3f714 refactor: use XmlWriter for Windows toasts (#48065)
refactor: use XmlWriter for Windows toasts
2025-08-20 16:06:51 +02:00
Robo
dd54e84a58 refactor: allocate api::App on cpp heap (#48118) 2025-08-20 20:35:08 +09:00
John Kleinschmidt
d4b7d9e9cf build: get source cache for docs only pipeline (#48120) 2025-08-20 11:07:00 +02:00
BILL SHEN
83a5ba1e2c feat: add fileBacked and purgeable fields to process.getSystemMemoryInfo() for macOS (#47628)
* fix: Optimize the value of memory.free in the return data of getSystemMemoryInfo().

* fix: Improve the value of memory in the return data of getSystemMemoryInfo().

* fix: complete API doc.

* Update docs/api/process.md

Co-authored-by: Will Anderson <will@itsananderson.com>

* fix: update name to fileBacked.

* fix: fix with code conflict

---------

Co-authored-by: Will Anderson <will@itsananderson.com>
2025-08-20 09:49:41 +02:00
Shelley Vohr
13d955a73e fix: system accent color parsing hex order (#48085)
fix: system accent color parsing
2025-08-19 10:01:41 +02:00
Samuel Attard
fdf29ce838 fix: ensure snapshot is valid (#48101) 2025-08-18 14:35:58 -07:00
Samuel Attard
3770bb31a7 fix: avoid deprecated login item methods (#48090) 2025-08-17 22:00:52 -07:00
dependabot[bot]
ed4a99ba5b build(deps-dev): bump @azure/storage-blob from 12.25.0 to 12.28.0 (#48055)
Bumps [@azure/storage-blob](https://github.com/Azure/azure-sdk-for-js) from 12.25.0 to 12.28.0.
- [Release notes](https://github.com/Azure/azure-sdk-for-js/releases)
- [Changelog](https://github.com/Azure/azure-sdk-for-js/blob/main/documentation/Changelog-for-next-generation.md)
- [Commits](https://github.com/Azure/azure-sdk-for-js/compare/@azure/storage-blob_12.25.0...@azure/storage-blob_12.28.0)

---
updated-dependencies:
- dependency-name: "@azure/storage-blob"
  dependency-version: 12.28.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-08-16 09:39:46 +02:00
Shelley Vohr
0e6c26096f fix: shell.openPath should be non-blocking (#48079)
fix: shell.openPath should be non-blocking
2025-08-15 13:55:31 -07:00
Keeley Hammond
7792ed1efa build: revert bump @octokit/rest from 20.1.2 to 22.0.0 (#48082)
Revert "build(deps-dev): bump @octokit/rest from 20.1.2 to 22.0.0 (#48014)"

This reverts commit 13ed526ca7.
2025-08-14 20:50:09 -07:00
Robo
c75c390ccf chore: add uma results in macOS keychain patch (#48080) 2025-08-15 11:10:37 +09:00
Shelley Vohr
4c3c3049e1 build: disallow non-maintainer changes to GitHub Actions workflows (#48038) 2025-08-14 13:54:05 -07:00
Shelley Vohr
68e7b38c05 build: use quick tunnels for ssh debugging (#47938)
* build: use dynamic local tunnels for ssh debugging

* weeee

* that'll do

* chore: pretty output

* build: allow ssh input

---------

Co-authored-by: Samuel Attard <samuel.r.attard@gmail.com>
2025-08-14 07:41:07 -04:00
dependabot[bot]
a051c7c274 build(deps): bump actions/download-artifact from 4.3.0 to 5.0.0 (#48052)
Bumps [actions/download-artifact](https://github.com/actions/download-artifact) from 4.3.0 to 5.0.0.
- [Release notes](https://github.com/actions/download-artifact/releases)
- [Commits](d3f86a106a...634f93cb29)

---
updated-dependencies:
- dependency-name: actions/download-artifact
  dependency-version: 5.0.0
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-08-13 14:33:48 +02:00
Shelley Vohr
53003d7af9 fix: app.accessibilitySupportEnabled (#48041)
fix: app.accessibilitySupportEnabled on macOS
2025-08-12 16:51:27 -04:00
David Sanders
63d7f609cd ci: manually fetch author_association in workflow automations (#48013) 2025-08-12 10:30:41 -07:00
electron-roller[bot]
01291623af chore: bump chromium to 141.0.7350.0 (main) (#48032)
* chore: bump chromium in DEPS to 141.0.7349.0

* chore: bump chromium in DEPS to 141.0.7350.0

* chore: update patches

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: Keeley Hammond <khammond@slack-corp.com>
2025-08-12 11:31:17 +02:00
dependabot[bot]
13ed526ca7 build(deps-dev): bump @octokit/rest from 20.1.2 to 22.0.0 (#48014)
Bumps [@octokit/rest](https://github.com/octokit/rest.js) from 20.1.2 to 22.0.0.
- [Release notes](https://github.com/octokit/rest.js/releases)
- [Commits](https://github.com/octokit/rest.js/compare/v20.1.2...v22.0.0)

---
updated-dependencies:
- dependency-name: "@octokit/rest"
  dependency-version: 22.0.0
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-08-12 11:18:08 +02:00
Shelley Vohr
afb0ee418c fix: re-entrancy issues in webContents.loadURL() (#48004)
fix: re-entrancy issues in webContents.loadURL()
2025-08-11 11:20:35 -04:00
electron-roller[bot]
55d8b71d72 chore: bump chromium to 141.0.7346.0 (main) (#47983)
* chore: bump chromium in DEPS to 141.0.7341.0

* chore: bump chromium in DEPS to 141.0.7342.0

* chore: update patches

manually resolved conflict in `osr_shared_texture_remove_keyed_mutex_on_win_dxgi.patch` due to https://crrev.com/c/6681354

* 6819541: WebShare: Improve mac share behavior when sharing a URL
https://chromium-review.googlesource.com/c/chromium/src/+/6819541

* Add missing include for SkBitmap

Couldn't quickly find where we lost the full definition in this file's includes. 🤷

* 6771055: [SxS] Move devtools to ContentsContainerView supporting side-by-side.
https://chromium-review.googlesource.com/c/chromium/src/+/6771055

There may be some simplification possible here (set_x, Rect position, ...), but this change is satisfactory to maintain the current behavior.

* 6813689: Switch SystemMemoryInfoKB to use ByteCount
https://chromium-review.googlesource.com/c/chromium/src/+/6813689

* 6818486: Track DevTools feature usage in new badge tracker
https://chromium-review.googlesource.com/c/chromium/src/+/6818486

* chore: bump chromium in DEPS to 141.0.7344.0

* Remove ELECTRON_OZONE_PLATFORM_HINT env var

6819616: Remove OzonePlatformHint | https://chromium-review.googlesource.com/c/chromium/src/+/6819616

See: https://github.com/electron/electron/issues/48001

* chore: update patches

* Add missing include for `base::NumberToString`

* Remove `DESKTOP_STARTUP_ID` code

This was removed upstream in https://chromium-review.googlesource.com/c/chromium/src/+/6819616 and I confirmed with the author that it was an intentional change. Going to mirror upstream and remove it here too.

* chore: bump chromium in DEPS to 141.0.7346.0

* chore: update patches

* 6828465: Reland "Remove BluezDBusThreadManager"
https://chromium-review.googlesource.com/c/chromium/src/+/6828465

* Patch change to Node.js test output

V8 enhanced the stack trace of "thenable" async tasks. A couple of Node.js tests needed to have their snapshots updates to accomodate the extra stack trace frames in the output.

This patch should be upstreamed to Node.js.

See:
6826001: fix thenable async stack trace
https://chromium-review.googlesource.com/c/v8/v8/+/6826001

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: clavin <clavin@electronjs.org>
2025-08-11 12:57:31 +09:00
Calvin
b9ceaabb85 docs: deprecate ELECTRON_OZONE_PLATFORM_HINT env var (#48002) 2025-08-10 21:49:23 +02:00
David Sanders
d6c0691a63 fix: importing from electron/utility in ESM (#47998) 2025-08-09 09:47:47 +02:00
David Sanders
a201d6c541 build: drop @types/webpack-env in favor of webpack/module types (#47798)
* build: drop @types/webpack-env in favor of webpack/module types

* chore: improve type when assigning to global.require
2025-08-08 18:09:23 -07:00
John Kleinschmidt
51add3e847 ci: cleanup use new arc cluster (#47916) 2025-08-08 09:26:10 -04:00
reito
9dcdec5015 feat: paint event move texture data to handle, add colorSpace (#47315)
* feat: paint event move shared texture to handle, add color space

* feat: add breaking change

* fix: properties.

* fix: remove utf8 bom
2025-08-08 10:13:56 +02:00
reito
095e622a6a feat: context bridge support VideoFrame (#47316)
* feat: context bridge support VideoFrame

* docs: add VideoFrame to docs
2025-08-07 16:41:49 -04:00
Shelley Vohr
a0d983e4b5 feat: allow macOS tray to maintain position (#47838)
* feat: allow macOS tray to maintain position

* refactor: just use guid

* test: fixup tests

* docs: clarify UUID format
2025-08-07 19:25:50 +02:00
wujinli
f49a645c06 fix: compilation error when disabling extensions and pdf_viewer (#47964) 2025-08-07 11:18:32 -04:00
John Kleinschmidt
8ab5ac9069 ci: fixup mac runner hang (#47982) 2025-08-07 10:52:26 +02:00
Will Anderson
27a8cc531b chore: Remove redundant IS_WIN check inside electron_main_win.cc (#47967) 2025-08-07 09:54:13 +02:00
David Sanders
26ffc8505c fix: allow importing from electron/utility at runtime (#47968) 2025-08-07 09:53:42 +02:00
electron-roller[bot]
3b0f35a7e8 chore: bump chromium to 140.0.7339.2 (main) (#47929)
* chore: bump chromium in DEPS to 140.0.7330.0

* chore: bump chromium in DEPS to 140.0.7331.0

* chore: update patches

* fix: gn check failing on crashpad.h
Not yet sure what caused this

* fix: predictors::PreconnectManager -> content::PreconnectManager
CL: https://chromium-review.googlesource.com/c/chromium/src/+/6788473

* chore: bump chromium in DEPS to 140.0.7333.0

* chore: bump chromium in DEPS to 140.0.7335.0

* chore: bump chromium in DEPS to 140.0.7337.0

* chore: update patches

* chore: restore some gin utility

* 6804057: [Extensions] Validate nodoc is specified as a boolean in schemas
https://chromium-review.googlesource.com/c/chromium/src/+/6804057

* fixup! chore: restore some gin utility

* fixup! fix: predictors::PreconnectManager -> content::PreconnectManager CL: https://chromium-review.googlesource.com/c/chromium/src/+/6788473

* 6772346: Reset MouseWheelPhaseHandler state when trackpoint scroll is detected
https://chromium-review.googlesource.com/c/chromium/src/+/6772346

Not certain about what the "correct" argument to pass here is. A quick dive into the CL suggests that passing `false` is safe to keep things working. The blast radius if this assumption is wrong is that "fling" scroll gestures may not work as expected with the OSR.

* 6789383: Uninstall SODA language pack after 30 days of inactivity
https://chromium-review.googlesource.com/c/chromium/src/+/6789383

* chore: update libcxx filenames

* chore: bump chromium in DEPS to 140.0.7339.0

* chore: update patches

* fixup! 6772346: Reset MouseWheelPhaseHandler state when trackpoint scroll is detected https://chromium-review.googlesource.com/c/chromium/src/+/6772346

* chore: bump chromium in DEPS to 140.0.7339.2

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: Samuel Maddock <smaddock@slack-corp.com>
Co-authored-by: deepak1556 <hop2deep@gmail.com>
Co-authored-by: clavin <clavin@electronjs.org>
2025-08-06 20:14:23 -04:00
David Sanders
8769d5ba9e build: check zip manifest for chromedriver.zip (#47972) 2025-08-06 20:04:19 -04:00
dependabot[bot]
7f8b7c3873 build(deps-dev): bump @electron/lint-roller from 3.1.1 to 3.1.2 (#47963)
Bumps [@electron/lint-roller](https://github.com/electron/lint-roller) from 3.1.1 to 3.1.2.
- [Release notes](https://github.com/electron/lint-roller/releases)
- [Changelog](https://github.com/electron/lint-roller/blob/main/.releaserc.json)
- [Commits](https://github.com/electron/lint-roller/compare/v3.1.1...v3.1.2)

---
updated-dependencies:
- dependency-name: "@electron/lint-roller"
  dependency-version: 3.1.2
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-08-06 11:21:55 +02:00
David Sanders
8bf4260e3e test: add TS smoke test for electron/utility (#47969) 2025-08-06 10:30:39 +02:00
Charles Kerr
7a13c6f175 refactor: avoid deprecated v8::Context::GetIsolate() pt 4 (#47961)
* refactor: remove GetIsolate() calls from SetPrivate()

* refactor: remove excess GetIsolate() calls in PassValueToOtherContextInner()

* refactor: remove GetIsolate() calls from GetPrivate()

* refactor: add a v8::Isolate* local to ProxyFunctionWrapper()

* refactor: remove error_context->GetIsolate() call from PassValueToOtherContextInner()

* refactor: remove GetIsolate() call from ProxyFunctionWrapper()

* refactor: pass source and destination isolate as arg to CreateProxyForAPI()
2025-08-05 20:08:04 -05:00
Keeley Hammond
678fb400fd fix: video scrubbing on playback (#47703)
* fix: fix video scrubbing on playback

* chore: address review feedback

---------

Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
2025-08-05 18:48:52 +02:00
Shelley Vohr
8806499904 fix: offscreen mode under window.open creation (#47868)
fix: offscreen mode under new window creation
2025-08-05 14:56:33 +02:00
dependabot[bot]
637a504e28 build(deps): bump github/codeql-action from 3.29.4 to 3.29.5 (#47962)
Bumps [github/codeql-action](https://github.com/github/codeql-action) from 3.29.4 to 3.29.5.
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](4e828ff8d4...51f77329af)

---
updated-dependencies:
- dependency-name: github/codeql-action
  dependency-version: 3.29.5
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-08-05 14:41:57 +02:00
electron-roller[bot]
40cdfdb1d1 chore: bump node to v22.18.0 (main) (#47937)
* chore: bump node in DEPS to v22.18.0

* crypto: fix inclusion of OPENSSL_IS_BORINGSSL define

https://github.com/nodejs/node/pull/58845

* crypto: fix SHAKE128/256 breaking change introduced with OpenSSL 3.4

https://github.com/nodejs/node/pull/58960

* permission: propagate permission model flags on spawn

https://github.com/nodejs/node/pull/58853

* esm: syncify default path of ModuleLoader\.load

https://github.com/nodejs/node/pull/57419

* src: remove fast API for InternalModuleStat

https://github.com/nodejs/node/pull/58489

* src: simplify adding fast APIs to ExternalReferenceRegistry

https://github.com/nodejs/node/pull/58896/

* chore: fixup patch indices

* src: fix internalModuleStat v8 fast path

https://github.com/nodejs/node/pull/58054

* test: add tests to ensure that node.1 is kept in sync with cli.md

https://github.com/nodejs/node/pull/58878

* crypto: fix SHAKE128/256 breaking change introduced with OpenSSL 3.4

https://github.com/nodejs/node/pull/58942

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
2025-08-04 14:40:36 -04:00
Robo
4ca10a1056 chore: move gin::Handle to gin_helper (#47959)
* chore: move gin::Handle to gin_helper

* chore: fix lint
2025-08-05 02:03:06 +09:00
Robo
9d05454dc7 chore: move gin::DeprecatedWrappable to gin_helper (#47958)
* chore: move gin::DeprecatedWrappable to gin_helper

This is in preparation for migrating to gin::Wrappable
based on cppgc #47922
The upstream class will be deleted soon via roller PR but
the cppgc migration should happen outside the roll, this
change retains the current functionality by copying the
implementation into //electron/shell/common/gin_helper.
The class can be deleted once the cppgc migration is complete.

* chore: fix lint:cpp
2025-08-04 23:28:01 +09:00
dependabot[bot]
0e862bba61 build(deps-dev): bump remark-preset-lint-markdown-style-guide from 4.0.0 to 6.0.1 (#47940)
build(deps-dev): bump remark-preset-lint-markdown-style-guide

Bumps [remark-preset-lint-markdown-style-guide](https://github.com/remarkjs/remark-lint) from 4.0.0 to 6.0.1.
- [Release notes](https://github.com/remarkjs/remark-lint/releases)
- [Changelog](https://github.com/remarkjs/remark-lint/blob/main/changelog.md)
- [Commits](https://github.com/remarkjs/remark-lint/commits)

---
updated-dependencies:
- dependency-name: remark-preset-lint-markdown-style-guide
  dependency-version: 6.0.1
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-08-04 14:29:36 +02:00
Shelley Vohr
4232ed2814 fix: crash on window.close() with webContents on blur (#47933)
fix: crash on window.close with WebContentsView on blur
2025-08-04 10:35:29 +02:00
Will Anderson
e7683bdd25 feat: Use DIR_ASSETS path to locate resource bundles (#47439)
* feat: Use DIR_ASSETS path to locate resource bundles

* Use DIR_ASSETS for calculating ASAR relative paths

* Add test to verify 'assets' matches parent dir of 'exe'

* Add Mac-specific test for assets path (but it is failing)

* test: Update app.getPath('assets') to expect an exception on Mac

* docs: Update docs for 'assets' path to indicate that it's only available on Windows + Linux

* fix: Don't define 'assets' mapping on macOS
2025-08-04 12:34:08 +09:00
Sam Maddock
bdaf3b9a2b refactor: replace webFrame.routingId with sync IPC (#47717)
* refactor: replace webFrame.routingId with sync IPC

* fix: GetConstructor missing isolate

* fix: missing isolate
2025-08-02 11:00:42 -04:00
Shelley Vohr
5c98e3609f feat: add {get|set}AccentColor on Windows (#47741)
* feat: add setAccentColor on Windows

* refactor: unify GetSystemAccentColor

* refactor: remove redundant parsing

* chore: fixup documentation

* Update docs/api/browser-window.md

Co-authored-by: Will Anderson <andersonw@dropbox.com>

* Update docs/api/base-window.md

Co-authored-by: Will Anderson <andersonw@dropbox.com>

---------

Co-authored-by: Will Anderson <andersonw@dropbox.com>
2025-08-01 22:29:02 +02:00
dependabot[bot]
2cfccac074 build(deps-dev): bump folder-hash from 2.1.2 to 4.1.1 (#47931)
Bumps [folder-hash](https://github.com/marc136/node-folder-hash) from 2.1.2 to 4.1.1.
- [Release notes](https://github.com/marc136/node-folder-hash/releases)
- [Changelog](https://github.com/marc136/node-folder-hash/blob/main/CHANGELOG.md)
- [Commits](https://github.com/marc136/node-folder-hash/compare/v2.1.2...v4.1.1)

---
updated-dependencies:
- dependency-name: folder-hash
  dependency-version: 4.1.1
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-08-01 19:16:43 +02:00
electron-roller[bot]
03aad28412 chore: bump chromium to 140.0.7327.0 (main) (#47902)
* chore: bump chromium in DEPS to 140.0.7324.0

* chore: bump chromium in DEPS to 140.0.7325.0

* chore: remove @dsanders11's unused include patch
CL: https://chromium-review.googlesource.com/c/chromium/src/+/6782507

* fix: apply keychain patch to new apple subdir
CL: https://chromium-review.googlesource.com/c/chromium/src/+/6736212

* chore: update chromium patches

* chore: update other patches

* chore: bump chromium in DEPS to 140.0.7327.0

* fix: mistake in reapplied patch

* fixup! fix: apply keychain patch to new apple subdir CL: https://chromium-review.googlesource.com/c/chromium/src/+/6736212

* chore: update patches

* fix: remove OnPrivateNetworkAccessPermissionRequired override
CL: https://chromium-review.googlesource.com/c/chromium/src/+/6769208

* fix: update colorSpace property to use new unified value
CL: https://chromium-review.googlesource.com/c/chromium/src/+/6795085

* fix: include OverlayWindowLiveCaptionButton
CL: https://chromium-review.googlesource.com/c/chromium/src/+/6787420

* fixup! fix: apply keychain patch to new apple subdir CL: https://chromium-review.googlesource.com/c/chromium/src/+/6736212

* fix: format chromium_src/BUILD.gn
CL: https://chromium-review.googlesource.com/c/chromium/src/+/6787427

* fix: format BUILD.gn
CL: https://chromium-review.googlesource.com/c/chromium/src/+/6787427

* chore: include script/ in logged path

* fix: update filenames.libcxx.gni
CL: https://chromium-review.googlesource.com/c/chromium/src/+/6787279

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: Samuel Maddock <smaddock@slack-corp.com>
2025-07-31 18:11:00 -04:00
Sam Maddock
25e2459f31 feat: webFrameMain.fromFrameToken (#47850)
* feat: webFrameMain.fromFrameToken

* refactor: return null instead of undefined

* docs: mention renderer webFrame property

* chore: undo null->undefined in wfm.fromId api
this will be updated in another pr
2025-07-31 16:41:44 -04:00
Shelley Vohr
18af498cf1 build: roll build-images to 933c7d6 (#47880) 2025-07-31 12:08:45 -04:00
John Kleinschmidt
9f43503b3e chore: revert "ci: fixup mac runners" (#47917)
This reverts commit 06d7a51a58.
2025-07-31 11:08:43 -04:00
Shelley Vohr
ecb1eb0b5d feat: add app.getRecentDocuments() (#45839)
feat: add app.getRecentDocuments()
2025-07-31 16:15:33 +02:00
dependabot[bot]
2c916cfa33 build(deps-dev): bump @octokit/rest from 20.1.1 to 20.1.2 (#47818)
* build(deps-dev): bump @octokit/rest from 20.1.1 to 22.0.0

Bumps [@octokit/rest](https://github.com/octokit/rest.js) from 20.1.1 to 22.0.0.
- [Release notes](https://github.com/octokit/rest.js/releases)
- [Commits](https://github.com/octokit/rest.js/compare/v20.1.1...v22.0.0)

---
updated-dependencies:
- dependency-name: "@octokit/rest"
  dependency-version: 22.0.0
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>

* chore: bump octokit/rest to 20.1.2

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: John Kleinschmidt <jkleinsc@electronjs.org>
2025-07-31 14:30:45 +02:00
Shelley Vohr
4c9ab8765b fix: dark mode on Linux default themeing (#47869) 2025-07-31 10:54:55 +02:00
dependabot[bot]
051f78dd1d build(deps): bump actions-cool/issues-helper from 3.6.0 to 3.6.2 (#47905)
Bumps [actions-cool/issues-helper](https://github.com/actions-cool/issues-helper) from 3.6.0 to 3.6.2.
- [Release notes](https://github.com/actions-cool/issues-helper/releases)
- [Changelog](https://github.com/actions-cool/issues-helper/blob/main/CHANGELOG.md)
- [Commits](a610082f8a...50068f49b7)

---
updated-dependencies:
- dependency-name: actions-cool/issues-helper
  dependency-version: 3.6.2
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-07-31 10:54:25 +02:00
dependabot[bot]
c796a74467 build(deps): bump github/codeql-action from 3.29.2 to 3.29.4 (#47904)
Bumps [github/codeql-action](https://github.com/github/codeql-action) from 3.29.2 to 3.29.4.
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](181d5eefc2...4e828ff8d4)

---
updated-dependencies:
- dependency-name: github/codeql-action
  dependency-version: 3.29.4
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-07-31 10:54:03 +02:00
John Kleinschmidt
0d0cbaf7b4 ci: use new arc cluster (#47897) 2025-07-30 13:45:24 -04:00
Charles Kerr
63c452dcc7 refactor: avoid deprecated v8::Context::GetIsolate() calls pt 3 context get isolate pt 3 (#47901)
* refactor: add a v8::Isolate* arg to RendererClientBase::IsWebViewFrame()

Needed for creating gin dictionaries

refactor: add a v8::Isolate* arg to ShouldLoadPreload()

Needed for calling IsWebViewFrame()

* refactor: add a v8::Isolate* arg to electron::util::CompileAndCall()

* refactor: add a v8::Isolate* arg to OnCreatePreloadableV8Context()

* refactor: add a v8::Isolate* arg to InvokeEmitProcessEvent()

* refactor: add a v8::Isolate* arg to ServiceWorkerData's constructor

* refactor: add a v8::Isolate* arg to RendererClientBase::SetupMainWorldOverrides()

* refactor: add a v8::Isolate* arg to RendererClientBase::WilLReleaseScriptContext()

* docs: update docs to avoid v8::Context::GetIsolate()

* refactor: add a v8::Isolate* arg to ElectronSandboxedRendererClient::InitializeBindings()

* refactor: avoid v8::Context::GetIsolate() call in PromiseBase::SettleScope::~SettleScope()
2025-07-30 09:14:38 -05:00
electron-roller[bot]
f6407b4949 chore: bump chromium to 140.0.7314.0 (main) (#47882)
* chore: bump chromium in DEPS to 140.0.7314.0

* 6769821: Delegate checking whether preconnect is enabled.

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6769821

* 6632993: PDF Searchify IPH: Use embedder WebContents for GuestView PDF

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6632993

* 6769214: [ios blink] Set IOSurface shared memory region on all GMB handles

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6769214

* chore: update patches

* 6769572: [soft navs]: Move AsyncSameDocumentNavigationStarted to TaskAttributionTracker

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6769572

* chore: node gen-libc++-filenames.js

* 6765740: [SxS] Implement support for split view in extensions API

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6765740

* 6769821: Delegate checking whether preconnect is enabled.

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6769821

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: David Sanders <dsanders11@ucsbalum.com>
2025-07-28 15:31:54 -07:00
John Kleinschmidt
06d7a51a58 ci: fixup mac runners (#47877)
ci: make sure camera and bluetooth are available on macos

ci: turn off spotlight indexing
2025-07-28 13:37:05 -04:00
Charles Kerr
2255bb620a refactor: avoid deprecated v8::Context::GetIsolate() calls (pt 2) (#47879)
* refactor: add a v8::Isolate* arg to Constructible::GetConstructor()

* refactor: add a v8::Isolate* arg to NodeBindings::Initialize()

This is needed for the GetConstructor() call

* refactor: avoid v8::Context::GetIsolate() call in GetIpcObject() by taking it as an arg

* refactor: avoid v8::Context::GetIsolate() call in ipc_native::EmitIPCEvent() by taking it as an arg
2025-07-28 10:22:27 -05:00
Charles Kerr
084c6ef549 refactor: prefer GetCreationContextChecked(v8::Isolate*) over GetCreationContextChecked() (#47878)
* refactor: pass an isolate when calling GetCreationContextChecked() in V8FunctionInvoker

* refactor: pass an isolate when calling GetCreationContextChecked() in RendererClientBase

* refactor: pass an isolate when calling GetCreationContextChecked() in ScriptExecutionCallback::Completed()

* refactor: pass an isolate when calling GetCreationContextChecked() in ScriptExecutionCallback::CopyResultToCallingContextAndFinalize()

* refactor: pass an isolate when calling GetCreationContextChecked() in electron::GetRenderFrame()

* refactor: pass an isolate when calling GetCreationContextChecked() in gin_helper::internal::CallMethodWithArgs()

* refactor: pass an isolate when calling GetCreationContextChecked() in OverrideGlobalPropertyFromIsolatedWorld()

* refactor: pass an isolate when calling GetCreationContextChecked() in OverrideGlobalValueFromIsolatedWorld()

* refactor: pass an isolate when calling GetCreationContextChecked() in ProxyFunctionWrapper()

* refactor: pass an isolate when calling GetCreationContextChecked() in PassValueToOtherContextInner()

* fixup! refactor: pass an isolate when calling GetCreationContextChecked() in electron::GetRenderFrame()
2025-07-25 09:06:57 -05:00
Shelley Vohr
01faaa30ea fix: window content protection on older Windows versions (#47856) 2025-07-24 12:05:28 -07:00
electron-roller[bot]
c569d5e4ba chore: bump chromium to 140.0.7312.0 (main) (#47862)
* chore: bump chromium in DEPS to 140.0.7312.0

* 6769540: Move NetworkTrafficAnnotationTag out of PreconnectManager.

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6769540

* 6771377: Roll libc++ from 3eda1e62e799 to 569aa83b4bbc (7 revisions)

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6771377

* 6771398: Remove unnecessary std::optional wrappers in ResolveHostClient

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6771398

* chore: update patches

* 6776165: Use shared session bus for MPRIS

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6776165

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: David Sanders <dsanders11@ucsbalum.com>
2025-07-23 16:26:30 -07:00
Shelley Vohr
670da27305 ci: add ability to debug SSH sessions in CI (#47819) 2025-07-23 10:57:06 -04:00
dependabot[bot]
5f901174c5 build(deps): bump slackapi/slack-github-action from 2.1.0 to 2.1.1 (#47748)
Bumps [slackapi/slack-github-action](https://github.com/slackapi/slack-github-action) from 2.1.0 to 2.1.1.
- [Release notes](https://github.com/slackapi/slack-github-action/releases)
- [Commits](b0fa283ad8...91efab103c)

---
updated-dependencies:
- dependency-name: slackapi/slack-github-action
  dependency-version: 2.1.1
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-07-23 11:24:17 +02:00
xufuhang
b39a1fb877 fix: webContents.downloadURL() did not support referer header (#47625)
Signed-off-by: xufuhang <576484918@qq.com>
2025-07-23 10:37:24 +02:00
Robo
2156ccb577 ci: update llvmobjdump package as part of fix sync (#47858) 2025-07-23 17:05:30 +09:00
electron-roller[bot]
9e2f7065a0 chore: bump chromium to 140.0.7309.0 (main) (#47848)
* chore: bump chromium in DEPS to 140.0.7309.0

* 6762172: Replace MSG_ROUTING_NONE with IPC::mojom::kRoutingIdNone.

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6762172

* 6759543: [exit-time-destructors] Exclude target with warnings

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6759543

* 6765167: Split PreconnectManager into interface and implementation.

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6765167

* 6766775: [media] Clarify coded and visible size in FrameResources

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6766775

* 6760878: Move PreconnectRequest to //content/public

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6760878

* 6718973: Implement media playback trust check for the video PiP overlay window

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6718973

* chore: add missing include of <iterator> in ada

* chore: update patches

* chore: node gen-libc++-filenames.js

* 6759633: [media] Use format from shared image in FrameResources

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6759633

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: David Sanders <dsanders11@ucsbalum.com>
2025-07-22 16:09:47 -07:00
Niklas Wenzel
51bfe07da9 build: extend Chromium options in bug report template (#47829)
* build: extend Chromium options in bug report template

As predicted by @dsanders11 and others, we got a bunch of bug reports with clearly incorrect values for "does this issue appear in Chromium?" because people didn't test or didn't know how to test.

This PR adds an "I didn't know how to test" option.

* build: update wording to use present tense
2025-07-21 15:26:02 -04:00
Shelley Vohr
4699761649 build: improve check-zip-manifest (#47828)
* build: improve check-zip-manifest

* fix: unicode on Windows
2025-07-21 15:20:27 -04:00
electron-roller[bot]
26e1bda335 chore: bump chromium to 140.0.7301.0 (main) (#47747)
* chore: bump chromium in DEPS to 140.0.7296.0

* chore: update patches

* 6702959: Remove OwnedByWidgetPassKey usage from content analysis dialog tests | https://chromium-review.googlesource.com/c/chromium/src/+/6702959

* 6722750: Remove un-used `stream_id` argument for `AidaCodeComplete` | https://chromium-review.googlesource.com/c/chromium/src/+/6722750

* 6696478: Reland Reland [video pip] Add fade in/out animation to controls visibility changes | https://chromium-review.googlesource.com/c/chromium/src/+/6696478

* chore: update libc++-filenames

* build: explicitly include cstdlib in Boyer-Moore patch

* chore: bump chromium in DEPS to 140.0.7297.0

* chore: update patches

* 6729537: [FPF] Pipe flag state from the browser to the renderer | https://chromium-review.googlesource.com/c/chromium/src/+/6729537

* 6727996: [Win] Detect pre-IPC crashes in sandboxed utility processes | https://chromium-review.googlesource.com/c/chromium/src/+/6727996

* 6707182: Move wtf/cross_thread_copier*.* to "blink" namespace | https://chromium-review.googlesource.com/c/chromium/src/+/6707182

* 6730796: extensions: Extract safe browsing/telemetry methods to new client class | https://chromium-review.googlesource.com/c/chromium/src/+/6730796

* chore: bump chromium in DEPS to 140.0.7299.0

* chore: update patches

* chore: update main patches

* build: reset the minimum macOS SDK to 15 to match upstream

This reverts commit 499e987c77.

* 6730215: Remove IPC_MESSAGE_LOG_ENABLED ifdef blocks. | https://chromium-review.googlesource.com/c/chromium/src/+/6730215

* 6690442: Delete ppapi/buildflags/buildflags.h | https://chromium-review.googlesource.com/c/chromium/src/+/6690442

* [wip]: 6667681: Use more binaries from clang toolchain in mac build | https://chromium-review.googlesource.com/c/chromium/src/+/6667681

* chore: bump chromium in DEPS to 140.0.7301.0

* chore: update patches

* 6656309: extensions: Port proxy API to desktop Android | https://chromium-review.googlesource.com/c/chromium/src/+/6656309

* 6758510: Reland 'Move GN enable_plugins variable out of //ppapi' | https://chromium-review.googlesource.com/c/chromium/src/+/6758510

* 6701466: [Extensions] Remove NaCl arch info from Update Client URLs | https://chromium-review.googlesource.com/c/chromium/src/+/6701466

* 6735979: [FSA] Replace `request_writable` with a new enum `FileSystemAccessPermissionMode`. | https://chromium-review.googlesource.com/c/chromium/src/+/6735979

* 6712080: Reland "Turn on gender translation PAK generation everywhere" | https://chromium-review.googlesource.com/c/chromium/src/+/6712080

* 6730796: extensions: Extract safe browsing/telemetry methods to new client class | https://chromium-review.googlesource.com/c/chromium/src/+/6730796

* build: restore minimum macOS SDK to 10, restore patch

This reverts commit a04c579b99.

* fixup! 6701466: [Extensions] Remove NaCl arch info from Update Client URLs | https://chromium-review.googlesource.com/c/chromium/src/+/6701466

* chore: correct node patches

* fixup! 6667681: Use more binaries from clang toolchain in mac build | https://chromium-review.googlesource.com/c/chromium/src/+/6667681

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: Keeley Hammond <khammond@slack-corp.com>
Co-authored-by: Keeley Hammond <vertedinde@electronjs.org>
Co-authored-by: patchup[bot] <73610968+patchup[bot]@users.noreply.github.com>
2025-07-21 09:32:53 -07:00
Shelley Vohr
cf871bce4e build: fix ffmpeg generation on Windows non-x64 (#47768)
* build: fix ffmpeg generation on Windows non-x64

* test: ffmpeg artifact
2025-07-21 11:33:42 -04:00
Charles Kerr
39cca586f6 refactor: avoid deprecated v8::Context::GetIsolate() calls (pt 1) (#47760)
* refactor: avoid redundant GetIsolate() calls in NodeBindings::CreateEnvironment()

Xref: https://chromium-review.googlesource.com/c/v8/v8/+/6563615

* refactor: use v8::Isolate::GetCurrent() in Initialize() methods

* refactor: add v8::Isolate* arg to NodeBindings::CreateEnvironment()

* fixup! refactor: use v8::Isolate::GetCurrent() in Initialize() methods

* refactor: add v8::Isolate* arg to RendererClientBase::DidCreateScriptContext()

* fixup! refactor: add v8::Isolate* arg to NodeBindings::CreateEnvironment()

* fixup! fixup! refactor: use v8::Isolate::GetCurrent() in Initialize() methods

refactor: prefer JavascriptEnvironment::GetIsolate() in the browser layer
2025-07-21 16:34:38 +02:00
Shelley Vohr
2f4a070c39 fix: dialog file filters and macOS app bundles (#47825) 2025-07-21 13:57:50 +02:00
electron-roller[bot]
2b098408a8 chore: bump node to v22.17.1 (main) (#47776)
* chore: bump node in DEPS to v22.17.1

* chore: update patches

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: patchup[bot] <73610968+patchup[bot]@users.noreply.github.com>
2025-07-18 15:18:18 -04:00
Shelley Vohr
fa844268ec ci: remove kTCCServiceMicrophone change (#47816)
ci: remove kTCCServiceMicrophone change
2025-07-18 10:02:06 +02:00
Shelley Vohr
a29a72c3ab build: update codespace on-create-command (#47810)
build: update codespace on-create-command
2025-07-18 10:01:49 +02:00
Shelley Vohr
4601aeccde chore: clean up NativeWindowMac::UpdateVibrancyRadii (#47665)
chore: clean up NativeWindowMac::UpdateVibrancyRadii
2025-07-17 11:45:24 -04:00
Shelley Vohr
31b18c9830 fix: abnormal behavior of windows background material (#47386)
* fix: abnormal behavior of windows background material

Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>

* chore: update patches

* fix: setting background material after init

---------

Co-authored-by: zoy <zoy-l@outlook.com>
Co-authored-by: patchup[bot] <73610968+patchup[bot]@users.noreply.github.com>
2025-07-17 14:50:12 +02:00
Shelley Vohr
895bf9103e fix: handle missing NativeWindowMac in ElectronNSWindow (#47751)
fix: handle missing NativeWindowMac in ElectronNSWindow
2025-07-17 14:49:37 +02:00
David Sanders
bf51d345c8 build(dev-deps): drop unused @types/webpack dep (#47767) 2025-07-17 11:04:11 +02:00
Shelley Vohr
6eef170d9a test: re-enable native module tests (#46747) 2025-07-17 11:03:15 +02:00
Shelley Vohr
31725b4a86 fix: window accentColor should adhere to native window behavior (#47740)
* fix: window accentColor should adhere to native window behavior

* fix: address review feedback

* chore: remove duplicate UpdateWindowAccentColor call in ctor
2025-07-17 10:59:42 +02:00
John Kleinschmidt
ec748eb915 test: cleanup RenderFrame lifespan tests (#47746)
* test: cleanup RenderFrame lifespan tests

* test: disable navigator.serial tests on arm64 mac

debug the hang

test: disable navigator.bluetooth on arm64 mac

Revert "test: disable navigator.bluetooth on arm64 mac"

This reverts commit 4b53a8485a5ff391832c7da93d859f1aa8722e70.

Revert "debug the hang"

This reverts commit 00338f0d49a7918224822087b4510fa9db0686c3.

Revert "test: disable navigator.serial tests on arm64 mac"

This reverts commit fb515ce447a9d42185e84b17b460e4fb6d1bf71d.

Reapply "test: disable navigator.serial tests on arm64 mac"

This reverts commit 0e5608108ffebbe8b8b27af9ea06aadae2ea85dd.

Reapply "test: disable navigator.bluetooth on arm64 mac"

This reverts commit f4c7d3fc0624a22421cba5d3d75df8c5d4367eea.

fixup

* test: add waitUntil for flaky test
2025-07-16 16:19:55 -04:00
Shelley Vohr
5feb91e2f4 test: fix extensions console flake (#47750) 2025-07-16 18:27:20 +02:00
Shelley Vohr
5128ebeddb test: deflake clipboard read/write specs (#47752) 2025-07-16 18:27:11 +02:00
Calvin
389927dce8 fix: corner smoothing feature gate crash (#47759)
* fix: corner smoothing feature gate crash

* Fix ElectronCornerSmoothing::CSSValueFromComputedStyleInternal
2025-07-16 08:39:17 -07:00
Calvin
67afc10b75 fix: add macos memory query fallback patch to avoid crash (#47765) 2025-07-16 08:18:54 -07:00
Pratyush
f570e6967f docs: fix broken sentence in crashReporter.start() documentation (#47688) 2025-07-16 15:05:45 +02:00
Shelley Vohr
09ab71de43 fix: deprecation warning crash when no Node.js environment available (#47700) 2025-07-16 12:45:59 +02:00
Milan Burda
21b325b034 docs: improve win.setContentProtection() docs (#46596)
* docs: improve win.setContentProtection() docs

* docs: update Windows display affinity value

* docs: update Windows behavior description

* Revert "docs: update Windows behavior description"

This reverts commit 6d1942c53a.

* Revert "docs: update Windows display affinity value"

This reverts commit c15363e75d.

---------

Co-authored-by: Niklas Wenzel <dev@nikwen.de>
2025-07-15 15:16:56 -07:00
Erick Zhao
cc9ca4bee2 docs: add Menu module tutorials (#47268)
* docs: add `Menu` module tutorials

* link API docs to new tutorials

* removed unreferenced fiddles

* add wording for new types

* fix import sort errors

* delete accelerator.md

* fixes
2025-07-15 15:09:32 -07:00
Shelley Vohr
17dba93587 fix: missing SQLite builtin support in Node.js (#47706)
https://github.com/nodejs/node/pull/58122
2025-07-15 15:39:16 +02:00
electron-roller[bot]
603cafad7e chore: bump chromium to 140.0.7281.0 (main) (#47616)
* chore: bump chromium in DEPS to 140.0.7269.2

* chore: bump chromium in DEPS to 140.0.7270.0

* chore: bump chromium in DEPS to 140.0.7271.0

* chore: bump chromium in DEPS to 140.0.7273.0

* 6516731: [ExclusiveAccessForAndroid] remove unneeded includes & deps | https://chromium-review.googlesource.com/c/chromium/src/+/6516731

* 6694809: dbus: Ensure systemd scope is started before using any portal services | https://chromium-review.googlesource.com/c/chromium/src/+/6694809

* chore: patch chromium

* chore: export patches

* chore: bump chromium in DEPS to 140.0.7275.0

* 6677511: [pepper] More pepper removal | https://chromium-review.googlesource.com/c/chromium/src/+/6677511

* 6513641: [gin] Rename gin::Wrappable to gin::DeprecatedWrappable | https://chromium-review.googlesource.com/c/chromium/src/+/6513641

* chore: export chromium patches

* 6513641: [gin] Rename gin::Wrappable to gin::DeprecatedWrappable | https://chromium-review.googlesource.com/c/chromium/src/+/6513641

* chore: bump chromium in DEPS to 140.0.7277.0

* chore: bump chromium in DEPS to 140.0.7279.0

* chore: bump chromium in DEPS to 140.0.7281.0

* 6677314: Plumb enabled client hints in the network requestion to network layer

https://chromium-review.googlesource.com/c/chromium/src/+/6677314

* 6351556: [source-phase-imports] Support Wasm Source Phase Imports

https://chromium-review.googlesource.com/c/chromium/src/+/6351556

* 6700077: [renderer] Avoid calls to deprecated GetIsolate methods

https://chromium-review.googlesource.com/c/chromium/src/+/6700077

* 6692873: Reland "Reland "FSA: Only normalize the hardcoded rules once during initialization""

https://chromium-review.googlesource.com/c/chromium/src/+/6692873

* 6686234: [gin] Cleanup NamedPropertyInterceptor for Wrappable

https://chromium-review.googlesource.com/c/chromium/src/+/6686234

* chore: export patches

* 6667723: Remove content_enable_legacy_ipc GN arg.

https://chromium-review.googlesource.com/c/chromium/src/+/6667723

* 6646566: ui: Move NativeWindowTracker to its own directory

https://chromium-review.googlesource.com/c/chromium/src/+/6646566

* fix: add missing includes

* 6580522: [WAR, DNR] Fix unsafe redirect error to web accessible resource

https://chromium-review.googlesource.com/c/chromium/src/+/6580522

* 6680477: Implement `completeCode` endpoint and expose to DevTools

https://chromium-review.googlesource.com/c/chromium/src/+/6680477

* 6677511: [pepper] More pepper removal

https://chromium-review.googlesource.com/c/chromium/src/+/6677511

* 6696689: Rename views::WidgetFocusManager -> NativeViewFocusManager

https://chromium-review.googlesource.com/c/chromium/src/+/6696689

* 6702812: Move wtf/text/string_impl*.* to "blink" namespace

https://chromium-review.googlesource.com/c/chromium/src/+/6702812

* chore: fix dialog patch

* 6702431: [animation-trigger] Parse timeline-trigger-name

https://chromium-review.googlesource.com/c/chromium/src/+/6702431

* chore: fixup patch indices

* feat: replace webFrame.routingId with webFrame.frameToken

* feat: WebFrameMain.prototype.frameToken

* test: refactor to use replacement APIs

* chore: fixup pip patch

* test: adjust webFrame tests for frameToken changes

* 6703757: Reland "Enable -fsanitize=array-bounds in non-UBSan builds"

https://chromium-review.googlesource.com/c/chromium/src/+/6703757

* test: switch to frameTokens

* test: routingId is fine to test in the main process

* docs: add routingId to breaking changes

* docs: update plugin-crashed event

* chore: fixup linux dialog patch

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: alice <alice@makenotion.com>
Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
Co-authored-by: Samuel Maddock <smaddock@slack-corp.com>
2025-07-14 13:42:37 -07:00
Shelley Vohr
09f269426e test: add response to bluetooth request possibilities (#47725) 2025-07-14 13:12:27 -04:00
Shelley Vohr
3bbb82b42b ci: roll BUILD_TOOLS_SHA for macOS 15.5 SDK (#47694)
ci: roll BUILD_TOOLS_SHA for macOS 15.5 SDK
2025-07-14 13:11:07 -04:00
Shelley Vohr
a9504abde9 build: roll sysroots (#47710) 2025-07-14 11:27:19 -04:00
BILL SHEN
9f3636ffe2 build: add platform-specific conditions to the source_set in chromium_src (#47627)
* build: Add platform-specific if conditions to the source sets in chromium_src.

* build: Add platform-specific if conditions to the source sets in chromium_src.
2025-07-14 11:25:16 +02:00
Shelley Vohr
4a89068fb7 ci: add kTCCServiceAppleEvents perm override to fix AppleScript errors (#47726)
ci: add kTCCServiceAppleEvents perm override to fix AppleScript errors
2025-07-13 21:05:52 +02:00
John Kleinschmidt
137d4ec329 build: cleanup symlinks in cache (#47727)
* build: cleanup symlinks in cache

* build: ignore broken links

* try --ignore-failed-read

* build: dont deref symlinks

* build: add flag to 7zip to resolve symlink error

Needed to ignore Dangerous symbolic link path was ignored errors

* Revert "build: cleanup symlinks in cache"

This reverts commit 69e53cdc88.
2025-07-11 16:13:12 -04:00
David Sanders
624d085632 build: deep update brace-expansion to resolve an audit alert (#47692) 2025-07-11 09:57:41 +02:00
Robo
600b6b3315 build: reenable v8_enable_temporal_support (#47699)
* build: reenable v8_enable_temporal_support

* ci: test with increased vm map count

* chore: backport PA use fewer vmas by default on linux

* chore: update patches

* Revert "ci: test with increased vm map count"

This reverts commit b626c9a5ab7ad3f01e17d77c330abfd8096a8b02.

* ci: remove logs

---------

Co-authored-by: patchup[bot] <73610968+patchup[bot]@users.noreply.github.com>
2025-07-11 02:49:54 +09:00
David Sanders
9e67bd3508 ci: update audit CI workflow dependencies (#47691)
* ci: update audit CI workflow dependencies

* ci: bump to @electron/fiddle-core@2.0.1
2025-07-10 19:19:36 +02:00
Shelley Vohr
909fd3d55a ci: set git core.longpaths to true (#47695)
ci: set git core.longpaths to true
2025-07-10 19:13:39 +02:00
Niklas Wenzel
f2429c31c1 build: ask bug reporters to check if it is a Chromium issue (#47702)
* build: ask bug reporters to check if it is a Chromium issue

Inspiration: https://github.com/electron/electron/issues/47672#issuecomment-3051298922

* build: fix options
2025-07-10 08:47:04 -07:00
Shelley Vohr
fbb83be785 refactor: use dbus_thread_linux::GetSharedSessionBus() (#47685)
refactor: use dbus_thread_linux::GetSharedSessionBus()
2025-07-10 10:17:34 +02:00
Shelley Vohr
1eab19fc7c build: remove unused script (#47642) 2025-07-09 10:35:04 -04:00
Shelley Vohr
02f2feabe6 docs: update build prerequisites (#47680) 2025-07-09 12:07:24 +02:00
David Sanders
712262597d build: drop eslint-plugin-unicorn (#47676) 2025-07-08 15:20:56 +02:00
Shelley Vohr
31bc5ca903 fix: default to system accent color on invalid user color (#47660)
fix: default to system accent color on invalid user color"
2025-07-08 11:15:13 +02:00
Shelley Vohr
03a02fc31e fix: fullscreen for windows without rounded corners (#47664) 2025-07-08 11:14:14 +02:00
Shelley Vohr
5ef6897bc7 fix: accent color should reflect system settings without restart (#47629)
fix: accentColor should reflect system settings without restart
2025-07-03 18:13:39 +02:00
Charles Kerr
bc585b6a3f refactor: avoid a few unnecessary strings (#47644)
* perf: replace string temporary with string_view in GetXdgAppId()

* perf: replace string temporary with string_view in ToV8(WindowOpenDisposition)

* perf: replace string temporary with string_view in ToV8(electron::api::WebContents::Type)
2025-07-03 11:08:59 -05:00
David Sanders
4c460df0a4 ci: fix audit workflow alerting on stale results (#47643) 2025-07-03 14:42:04 +02:00
Shelley Vohr
cf193b279b fix: crash on source capture with empty thumbnail size (#47641) 2025-07-03 14:41:19 +02:00
Shelley Vohr
655037fbdf fix: window.open popups are always resizable (#47540)
fix: window.open popups are always resizable

Closes https://github.com/electron/electron/issues/43591.

Per current WHATWG spec, the `window.open` API should always
create a resizable popup window. This change updates the
`parseFeaturesString` function to ensure that windows opened
with `window.open` are always resizable, regardless of the
`resizable` feature string.
2025-07-02 15:02:59 +02:00
Samuel Attard
07338bb1cf build: update yarn to 1.22.22 (#47635) 2025-07-02 12:11:42 +02:00
reito
fb0b77b731 feat: add ColorSpace (#47314) 2025-07-02 00:09:09 -07:00
Keeley Hammond
499e987c77 build: set the minimum macOS SDK to 10.15 (#47634)
* build: set the minumum macOS SDK to 10.15

* build: revert "Update mac_sdk_min to match minimum required SDK version"

This reverts commit 3d4654fc18.
2025-07-01 18:51:08 -07:00
Cas_
f7138344d8 docs: discoverability of chromium switches (#44947)
* docs: document discoverability of chromium switches

* docs: fixed typo

* docs: reference chromium endorsed list of swithes

* docs: reorder command-line-switches

* fix: address review

* fix: typo

* fix: wording

* Update command-line-switches.md

fix: lint space

* fix: Update docs/api/command-line-switches.md

Co-authored-by: Keeley Hammond <vertedinde@electronjs.org>

---------

Co-authored-by: Keeley Hammond <vertedinde@electronjs.org>
2025-07-01 14:31:49 -07:00
dependabot[bot]
b9248e6782 build(deps): bump github/codeql-action from 3.29.0 to 3.29.2 (#47622) 2025-07-01 11:12:15 +02:00
Shelley Vohr
af39dcfb09 refactor: use non-deprecated macOS API in RemoveAsDefaultProtocolClient (#47506)
refactor: use non-deprecated macOS API in RemoveAsDefaultProtocolClient
2025-07-01 10:19:28 +02:00
Samuel Attard
d347632046 build: write abi version to published npm package (#47598) 2025-06-30 15:01:09 -07:00
electron-roller[bot]
4f69c5835e chore: bump chromium to 140.0.7261.0 (main) (#47561)
* chore: bump chromium in DEPS to 140.0.7259.0

* chore: update patches

* Add fade in animation to Picture-in-Picture windows

https://chromium-review.googlesource.com/c/chromium/src/+/6538268

* [v8] Use V8 Apis that don't return JSGlobalObject

Refs https://issues.chromium.org/issues/333672197

* chore: IWYU

* chore: bump chromium in DEPS to 140.0.7261.0

* chore: update patches

* revert: update to siso-chromium image

* [v8] Use v8::Object::WrapGlobal()

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6650977

* chore: IWYU

* chore: fix --trace-startup spec

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: deepak1556 <hop2deep@gmail.com>
2025-06-30 12:30:05 -04:00
Taiki Komoda
fa15332587 docs: update automated-testing.md (#47017)
* Update automated-testing.md

* fixed lint error
2025-06-30 10:56:48 +02:00
Shelley Vohr
e299a1d098 feat: support complete WebUSB device properties (#47459)
* feat: support complete WebUSB device properties

* docs: correct type consistency
2025-06-30 10:28:21 +02:00
Charles Kerr
c2302960a8 refactor: reduce scope of temporaries when getting dictionary values (#47581)
refactor: reduce scale of temporaries when getting dictionary values
2025-06-29 21:58:18 +02:00
Charles Kerr
5e862f398e fix: Reland "[accessibility] Platform node lifetime cleanups" (#47590)
Reland "[accessibility] Platform node lifetime cleanups"

https://chromium-review.googlesource.com/c/chromium/src/+/6462552
2025-06-29 21:57:48 +02:00
Shelley Vohr
61c245761c test: fix nan tests on macOS (#47583) 2025-06-29 21:57:44 +02:00
Charles Kerr
7c55b24be2 refactor: avoid copies of large objects in range based for loops (#47588)
* Avoid copies of large objects in range-based for-loops.

Xref: https://chromium-review.googlesource.com/c/chromium/src/+/6527689

* Avoid copies of large objects in range-based for-loops in Browser::ShowAboutPanel()
2025-06-29 21:32:26 +02:00
Charles Kerr
4af248f2b6 perf: avoid copying a vector when calling ConvertToWeakPtrVector() (#47593) 2025-06-29 21:32:03 +02:00
Erick Zhao
69e9b653ba docs: update example apps (#47597) 2025-06-29 21:31:42 +02:00
electron-roller[bot]
4dccccadbb chore: bump node to v22.17.0 (main) (#47557)
* chore: bump node in DEPS to v22.17.0

* build: use //third_party/simdutf by default in GN

https://github.com/nodejs/node/pull/58115

* chore: adjust crypto specs:

- https://github.com/nodejs/node/pull/58117
- https://github.com/nodejs/node/pull/58387

* deps: update libuv to 1.51.0

https://github.com/nodejs/node/pull/58124

* test: fix test-buffer-tostring-range on allocation failure

https://github.com/nodejs/node/pull/58416

* build: use FILE_OFFSET_BITS=64 esp. on 32-bit arch

https://github.com/nodejs/node/pull/58090

* build: use //third_party/simdutf by default in GN

https://github.com/nodejs/node/pull/58115

* inspector: add protocol method Network.dataReceived

https://github.com/nodejs/node/pull/58001

* test: force slow JSON.stringify path for overflow

https://github.com/nodejs/node/pull/58181

* chore: fixup patch indices

* 6049967: Remove protocol::Maybe and roll inspector_protocol

https://chromium-review.googlesource.com/c/chromium/src/+/6049967

* chore: fixup crypto test patch

* src: fix module buffer allocation

https://github.com/nodejs/node/pull/57738

* crypto: expose process.features.openssl_is_boringssl

https://github.com/nodejs/node/pull/58387

* util: add internal assignFunctionName() function

https://github.com/nodejs/node/pull/57916

* build: fix pointer compression builds

https://github.com/nodejs/node/pull/58171

* chore: put back config options

* fixup! deps: update libuv to 1.51.0

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
2025-06-28 16:33:09 +02:00
Charles Kerr
79cd6a2614 refactor: sync IsKillURL() with upstream impl in extension_tab_util.cc (#47580)
Use base::MakeFixedFlatSet()
2025-06-27 15:49:41 -05:00
Charles Kerr
2ba8fe9140 refactor: extract-constant static Windows registry keys in Browser code (#47569)
* refactor: extract-constant for registry key in GetProcessExecPath()

* refactor: extract-constant for registry key in Browser::SetLoginItemSettings()

* refactor: extract-constant for registry key in Browser::SetLoginItemSettings()

* refactor: extract-constant for registry key in Browser::GetLoginItemSettings()

* chore: document the symbolic constants

* refactor: prefer base::wcstring_view::c_str() to data() to make zero-termination clearer
2025-06-27 10:34:55 -05:00
Charles Kerr
b21c4b0f88 refactor: make context bridge's private keys hidden, constexpr string_views (#47562)
* refactor: local functions GetPrivate(), SetPrivate() now take std::string_views

* refactor: make local keys std::string_views instead of C-style char arrays

* refactor: make local keys constexpr

* refactor: move local keys into local anonymous namespace
2025-06-27 09:29:53 -05:00
Charles Kerr
f50ad3d022 refactor: remove stray .c_str() calls for absl::StrFormat() (#47548)
refactor: remove stray .c_str() calls for absl::StrFormat()

StrFormat() understands std::string, std::string_view
2025-06-26 11:41:30 +02:00
Keeley Hammond
7a274a711c fix: revert upstream MacOS mouse event routing (#47560)
* fix: revert upstream MacOS mouse event routing

* fix: reduce patch surface area

* chore: update patches
2025-06-26 11:41:11 +02:00
Niklas Wenzel
bc499ffb8a docs: fix --experimental-network-inspection spelling (#47565)
doc: fix `--experimental-network-inspection` spelling
2025-06-26 11:40:55 +02:00
Niklas Wenzel
0a74e91580 docs: update asar integrity fuse availability (#47528) 2025-06-25 23:15:59 +02:00
electron-roller[bot]
035879357e chore: bump chromium to 139.0.7256.0 (main) (#47481)
* chore: bump chromium in DEPS to 139.0.7242.0

* chore: update render_widget_host_view_mac.patch

no code changes; just updating patch context

Do a cleanup pass on the history swiper code | https://chromium-review.googlesource.com/c/chromium/src/+/6604367

* chore: update mas_avoid_private_macos_api_usage.patch.patch

no code changes; just updating patch context

[tracing] Delete base/trace_event/base_tracing.h | https://chromium-review.googlesource.com/c/chromium/src/+/6624012

* chore: update chore_provide_iswebcontentscreationoverridden_with_full_params.patch

no manual changes; just updating patch context

[ActorFramework] Refactor Actor Task Management | https://chromium-review.googlesource.com/c/chromium/src/+/6618684

* chore: update fix_move_autopipsettingshelper_behind_branding_buildflag.patch

[pip] Tuck picture-in-picture windows when a file dialog is open | https://chromium-review.googlesource.com/c/chromium/src/+/6449682

Reland "[document pip] Restrict the size that a website can request" | https://chromium-review.googlesource.com/c/chromium/src/+/6372104

* chore: update feat_corner_smoothing_css_rule_and_blink_painting.patch

Xref: corner-shape: constraint radii based on opposite corner overlap | https://chromium-review.googlesource.com/c/chromium/src/+/6592572

* chore: update revert_code_health_clean_up_stale_macwebcontentsocclusion.patch

no manual changes; just updating patch context

* chore: update fix_rename_sqlite_win32_exports_to_avoid_conflicts_with_node_js.patch

no code changes; just updating patch context

* chore: e patches all

* Plumb Verify2QwacBinding and hook it up in QwacWebContentsObserver

https://chromium-review.googlesource.com/c/chromium/src/+/6624719

* [Extensions] Remove host delegate OnMainFrameCreatedForBackgroundPage

https://chromium-review.googlesource.com/c/chromium/src/+/6631123

* Extensions: Rename GetResourceURL to ResolveExtensionURL

https://chromium-review.googlesource.com/c/chromium/src/+/6625053

* [NonClientFrameView] Consolidate NativeFrameViewMac

https://chromium-review.googlesource.com/c/chromium/src/+/6614239

* ICWYU

* [views-ax] Remove dead code WidgetAXTreeIDMap

https://chromium-review.googlesource.com/c/chromium/src/+/6619701

* Reland "extensions: Add `WillPrepareForEvaluation` to setup MojoJS"

https://chromium-review.googlesource.com/c/chromium/src/+/6630056

* NavigationThrottleRunner2: Remove MaybeAddThrottle

https://chromium-review.googlesource.com/c/chromium/src/+/6628079

* [pip] Tuck picture-in-picture windows when a file dialog is open

https://chromium-review.googlesource.com/c/chromium/src/+/6449682

* build: fix snapshot_blob.bin build error

xref: https://issues.chromium.org/issues/416540976

* chore: e patches all

* build: freeup disk space on macos

* chore: bump chromium in DEPS to 139.0.7244.0

* chore: update printing.patch

no manual changes; just updating patch context

* chore: remove upstreamed ignore_parse_errors_for_resolveshortcutproperties.patch

Prevent Windows crash on unexpected shortcut type | https://chromium-review.googlesource.com/c/chromium/src/+/6633298

* chore: e patches all

* Revert "Reland "extensions: Add `WillPrepareForEvaluation` to setup MojoJS""

This reverts commit 77c4f967a6.

Revert CL for the high confidence crash culprit for http://crash/28f897bb9743dfe0 | https://chromium-review.googlesource.com/c/chromium/src/+/6641819

* Fix spec's expected base64-encoded PNG strings to match upstream changes.

[rust png] Enable by default. | https://chromium-review.googlesource.com/c/chromium/src/+/6085801

* chore: bump chromium in DEPS to 139.0.7246.0

* chore: e patches all

* chore: bump chromium in DEPS to 139.0.7248.0

* chore: update patches

* siso: Enable Siso by default for non-Google builds

https://chromium-review.googlesource.com/c/chromium/src/+/6638830

Disabling for now until we are ready to build siso on all platforms.

* Revert "revert Don't use static variable for UseExternalPopupMenus"

This reverts commit e91e3894e6.

* Update mac_sdk_min to match minimum required SDK version

https://chromium-review.googlesource.com/c/chromium/src/+/6493969
(cherry picked from commit 3e7cbe912d)

* [video pip] Use default window styling on Mac

https://chromium-review.googlesource.com/c/chromium/src/+/6648665

* Reland "Force the unintentional renderer process creation check by default"

https://chromium-review.googlesource.com/c/chromium/src/+/6626905

* fixup: Reland "Force the unintentional renderer process creation check by default

https://chromium-review.googlesource.com/c/chromium/src/+/6626905

* chore: bump chromium in DEPS to 139.0.7249.0

* fixup: Reland "Force the unintentional renderer process creation check by default

https://chromium-review.googlesource.com/c/chromium/src/+/6626905

* chore: update patches

* chore: bump chromium in DEPS to 139.0.7250.0

* chore: bump chromium in DEPS to 139.0.7252.0

* chore: bump chromium in DEPS to 139.0.7254.0

* 6638187: browser level TOCTOU check for coordinate target

https://chromium-review.googlesource.com/c/chromium/src/+/6638187

* chore: fixup patch indices

* chore: add missing base/notimplemented includes

* 6652910: [Frame Cleanup] Push down/hide implementation-specific API

https://chromium-review.googlesource.com/c/chromium/src/+/6652910

* chore: bump chromium in DEPS to 139.0.7256.0

* chore: fix lint

* fixup! 6652910: [Frame Cleanup] Push down/hide implementation-specific API

* fix: move HandleScope location

* chore: bump chromium in DEPS to 139.0.7258.0

* fixup! [NonClientFrameView] Consolidate NativeFrameViewMac

* Revert "chore: bump chromium in DEPS to 139.0.7258.0"

This reverts commit 264b2e934f.

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: Charles Kerr <charles@charleskerr.com>
Co-authored-by: John Kleinschmidt <jkleinsc@electronjs.org>
Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
Co-authored-by: deepak1556 <hop2deep@gmail.com>
2025-06-26 00:12:49 +09:00
Felix Rieseberg
e4c37e4b38 docs: Add C++/Linux tutorial (#46822) 2025-06-25 12:57:43 +02:00
Calvin
828fc84e60 build: update NMV to 139 (#47529) 2025-06-24 12:24:17 -04:00
Shelley Vohr
51fbc964a6 fix: ensure /dev/null fd is closed on failure (#47525)
* fix: ensure /dev/null fd is closed on failure

* chore: ignore closehandle for windows

---------

Co-authored-by: Robo <hop2deep@gmail.com>
2025-06-24 17:44:50 +02:00
Shelley Vohr
3e8e87d186 feat: support customizing window accent color on Windows (#47285) 2025-06-24 14:43:02 +02:00
Samuel Attard
498f4bc98c build: rewrite push-patch to use the github API instead of local git commits to ensure commits are signed (#47401)
* build: rewrite push-patch to use the github API instead of local git commits to ensure commits are signed

* again

(cherry picked from commit a21afc3e45)

* use pr head ref

(cherry picked from commit 0edcc985fa)
2025-06-23 22:26:43 -07:00
Michaela Laurencin
a6ad5a6e60 docs: update timelines for E38 (#47488)
Update electron-timelines.md
2025-06-23 15:50:22 +02:00
Shelley Vohr
93d5152a25 fix: chrome://accessibility loading correctly (#47497)
fix: chrome://accessibility loading correctly
2025-06-23 14:38:29 +02:00
Shelley Vohr
fb65124234 chore: fix nightly issues getting unsupported label comment (#47503)
* chore: fix nightly issues getting unsupported label comment

* chore: address review feedback
2025-06-23 14:22:41 +02:00
dependabot[bot]
93f4b3cf9f build(deps): bump github/codeql-action from 3.28.19 to 3.29.0 (#47486)
Bumps [github/codeql-action](https://github.com/github/codeql-action) from 3.28.19 to 3.29.0.
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](fca7ace96b...ce28f5bb42)

---
updated-dependencies:
- dependency-name: github/codeql-action
  dependency-version: 3.29.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-06-23 11:24:18 +02:00
Charles Kerr
bb22eaccec refactor: simplify titlebar overlay initialization (#47480) 2025-06-23 11:24:05 +02:00
David Sanders
90a14299fd ci: fix sending Slack message in CI audit workflow (#47494) 2025-06-23 11:23:39 +02:00
Shelley Vohr
60924690d9 build: combine dependent libc patch (#47491) 2025-06-23 11:22:35 +02:00
John Kleinschmidt
9b158238dc build: update cache action to latest (#47501) 2025-06-23 11:22:14 +02:00
Samuel Attard
dac5e0cd1a build: add siso backend.star (#47509) 2025-06-20 11:25:27 -07:00
Robo
626895848e fix: utilityProcess running user script after process.exit is called (#47469)
* fix: utilityProcess running user script after process.exit is called

* docs: update breaking changes

* chore: update spec

* chore: update spec/api-utility-process-spec.ts

Co-authored-by: David Sanders <dsanders11@ucsbalum.com>

* chore: remove interface bound checks

---------

Co-authored-by: Niklas Wenzel <dev@nikwen.de>
Co-authored-by: David Sanders <dsanders11@ucsbalum.com>
2025-06-18 04:36:22 +09:00
Keeley Hammond
3536d4976a fix: revert moving IsClosed() and IsClosable() into NativeWindow::Close() (#47482)
Revert "refactor: move `IsClosed()` and `IsClosable()` tests into `NativeWindow::Close()` (#46888)"

This reverts commit 3faddd5ae2.
2025-06-16 16:41:19 -07:00
Shelley Vohr
2ad762e075 feat: support HIDDevice.collections (#47391)
* feat: support HIDDevice.collections

* Update docs/api/structures/hid-device.md

Co-authored-by: Erick Zhao <ezhao@slack-corp.com>

---------

Co-authored-by: Erick Zhao <ezhao@slack-corp.com>
2025-06-16 15:56:08 -04:00
electron-roller[bot]
6779769d22 chore: bump chromium to 139.0.7219.0 (main) (#47348)
* chore: bump chromium in DEPS to 139.0.7205.0

* 6543986: Mac: decouple deserializing and applying sandbox policy

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6543986

* 6580079: Reland 'Remove the third-party blocking feature'
Refs https://chromium-review.googlesource.com/c/chromium/src/+/6580079

* 6505716: guest-contents: Add components/guest_contents
Refs https://chromium-review.googlesource.com/c/chromium/src/+/6505716

* 6572556: Move LogMessageManager out of gpu_service_impl.cc.
Refs https://chromium-review.googlesource.com/c/chromium/src/+/6572556

* 6566111: Change UtilityProcessHost to manage its instance internally
Refs https://chromium-review.googlesource.com/c/chromium/src/+/6566111

* 6550237: Rename ReconnectEventObserver to ConnectionChangeObserverClient
Refs https://chromium-review.googlesource.com/c/chromium/src/+/6550237

* 6565918: Validate path is valid UTF8 in SelectFileDialogLinuxPortal
Refs https://chromium-review.googlesource.com/c/chromium/src/+/6565918

* 6579713: Remove base::NotFatalUntil::M130 usage
6566111: Change UtilityProcessHost to manage its instance internally
Refs
https://chromium-review.googlesource.com/c/chromium/src/+/6579713
https://chromium-review.googlesource.com/c/chromium/src/+/6566111

* chore: update chromium patches

* chore: update remaining patches

* fixup! 6566111: Change UtilityProcessHost to manage its instance internally Refs https://chromium-review.googlesource.com/c/chromium/src/+/6566111

* 6577970: Remove superfluous includes for base/strings/stringprintf.h in headers
Refs https://chromium-review.googlesource.com/c/chromium/src/+/6577970

* 6568811: Add FunctionCall structured metrics event for DevTools
Refs https://chromium-review.googlesource.com/c/chromium/src/+/6568811

* [PDF Ink Signatures] Support PdfAnnotationsEnabled policy
https://chromium-review.googlesource.com/c/chromium/src/+/6558970

* build: disable libcxx modules for rbe

* chore: bump chromium in DEPS to 139.0.7217.0

* chore: bump chromium in DEPS to 139.0.7218.0

* chore: update patches

fix_use_delegated_generic_capturer_when_available.patch was updated to handle a small change:
6582142: Use content::Create*Capturer in DesktopCaptureDevice. | https://chromium-review.googlesource.com/c/chromium/src/+/6582142

* chore: bump chromium in DEPS to 139.0.7219.0

* chore: update patches

* 6594615: Change Chromium's deployment target to macOS 12
https://chromium-review.googlesource.com/c/chromium/src/+/6594615

Updated the assertion message to match the docs structure now too. I removed the callout to the supported versions doc because it has moved and doesn't contain minimum platform version information.

* 6606232: [views] Remove DesktopWindowTreeHostWin::window_enlargement_
https://chromium-review.googlesource.com/c/chromium/src/+/6606232

|NativeWindow::GetContentMinimumSize| and |NativeWindow::GetContentMaximumSize| may be good opportunities for a refactor now.

* add squirrel.mac patch for removed function

This was triggered by the macOS 12.0 deployment upgrade change.

See: https://developer.apple.com/documentation/coreservices/1444079-uttypeconformsto?language=objc

* 6582142: Use content::Create*Capturer in DesktopCaptureDevice.
https://chromium-review.googlesource.com/c/chromium/src/+/6582142

* 6579732: Two minor API "quality of life" cleanups in OSCrypt Async
https://chromium-review.googlesource.com/c/chromium/src/+/6579732

* chore: add include for base::SingleThreadTaskRunner

Not sure what change caused this, I expect it would be a removed include somewhere else, but it's likely not important to track down.

* chore: update libcxx filenames

* chore: update CI build-tools commit target for macOS SDK 15.4

The following change uses an API that was added in the macOS 15.4 SDK. Support for that SDK version was added later than the current build-tools commit target.

6575804: Use a quick-and-dirty solution to avoid glitching with paste-and-go | https://chromium-review.googlesource.com/c/chromium/src/+/6575804

See: https://developer.apple.com/documentation/appkit/nspasteboard/accessbehavior-swift.enum?language=objc

* fixup! 6606232: [views] Remove DesktopWindowTreeHostWin::window_enlargement_ https://chromium-review.googlesource.com/c/chromium/src/+/6606232

* chore: bump chromium in DEPS to 139.0.7220.0

* chore: update patches

Minor changes due to:

6613978: pwa: let events fall through in the transparent area of TopContainerView | https://chromium-review.googlesource.com/c/chromium/src/+/6613978
6614778: Refactor auto pip tab observer for Android support | https://chromium-review.googlesource.com/c/chromium/src/+/6614778

* 6543986: Mac: decouple deserializing and applying sandbox policy
https://chromium-review.googlesource.com/c/chromium/src/+/6543986

The DecodeVarInt and DecodeString functions look benign from a MAS perspective. I suspect they were patched out to avoid "unused function" errors. Their complements for encoding are unpatched, supporting this idea.

The code that uses these functions was refactored out of the section that we patch out. Instead of patching out that new function, I decided to treat it the same as the serialization function that is unpatched.

* chore: bump chromium in DEPS to 139.0.7222.0

* chore: bump chromium in DEPS to 139.0.7224.0

* chore: bump chromium in DEPS to 139.0.7226.0

* chore: bump chromium in DEPS to 139.0.7228.0

* chore: update patches

* Don't use static variable for UseExternalPopupMenus

https://chromium-review.googlesource.com/c/chromium/src/+/6534657

* Reland "Roll libc++ from a01c02c9d4ac to a9cc573e7c59

https://chromium-review.googlesource.com/c/chromium/src/+/6607589

* chore: bump chromium in DEPS to 139.0.7219.0

* chore: update patches

* revert Don't use static variable for UseExternalPopupMenus

* tls: remove deprecated tls.createSecurePair and SecurePair

https://github.com/nodejs/node/pull/57361

* Revert "Reland "Roll libc++ from a01c02c9d4ac to a9cc573e7c59"

This reverts commit 33e1436a0c.

* test: cleanup api-desktop-capturer-spec.ts

* test: more cleanup of api-desktop-capturer-spec.ts

* chore: debug dcheck error in webrtc on linux

* fixup patch

* add debugging to desktop capturer spec

* test: fixup api-desktop-capturer-spec.ts for linux

* chore: remove debugging patch

* Revert "fixup! 6606232: [views] Remove DesktopWindowTreeHostWin::window_enlargement_ https://chromium-review.googlesource.com/c/chromium/src/+/6606232"

This reverts commit 32e75651c1.

* Revert "6606232: [views] Remove DesktopWindowTreeHostWin::window_enlargement_"

This reverts commit 89c51aa1c7.

* [views] Remove DesktopWindowTreeHostWin::window_enlargement_

https://chromium-review.googlesource.com/c/chromium/src/+/6606232

Reverting as we need this functionality for now.

* fixup: remove patch that was accidentally added back

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: Samuel Maddock <smaddock@slack-corp.com>
Co-authored-by: deepak1556 <hop2deep@gmail.com>
Co-authored-by: clavin <clavin@electronjs.org>
Co-authored-by: John Kleinschmidt <jkleinsc@electronjs.org>
2025-06-16 12:46:06 -05:00
Shelley Vohr
96fcc2f8c8 chore: exempt upgrade-follow-up issues from stale (#47460)
chore: exempt upgrade-follow-upissues from stale
2025-06-14 21:43:57 -07:00
Charles Kerr
3c9b8475a2 refactor: move gin::Converter<PreloadScript> impl to a .cc file (#47445)
refactor: move gin::Converter<PreloadScript> impl to a .cc file
2025-06-13 10:15:32 +02:00
Charles Kerr
6f915e85e2 refactor: have ShowSaveDialogSync() return a std::optional<base::FilePath> (#47428)
* refactor: have ShowSaveDialogSync() return a std::optional<base::FilePath>

* fixup! refactor: have ShowSaveDialogSync() return a std::optional<base::FilePath>
2025-06-12 12:25:40 +02:00
Anny Yang
0259abe920 docs: update remaining references to electron-quick-start (#47405)
* chore: udpate remaining references to electron-quick-start

* chore: Update docs/tutorial/tutorial-1-prerequisites.md

Co-authored-by: Niklas Wenzel <dev@nikwen.de>

* chore: Update docs/tutorial/tutorial-3-preload.md

Co-authored-by: Niklas Wenzel <dev@nikwen.de>

* chore: Update docs/tutorial/tutorial-2-first-app.md

Co-authored-by: Niklas Wenzel <dev@nikwen.de>

* chore: linebreak

* chore: swap minimal-repro for npx create-electron-app

* chore: add back code commands

* chore: add whitespace

* chore: remove reference to repo containing old quick start

---------

Co-authored-by: Niklas Wenzel <dev@nikwen.de>
2025-06-12 10:32:17 +02:00
Shelley Vohr
38fe14041d fix: crash calling Fetch.continueResponse with WebContentsView (#47434)
fix: crash calling Fetch.continueResponse with WebContentsView
2025-06-11 15:43:47 +02:00
dependabot[bot]
996945d3e3 build(deps): bump github/codeql-action from 3.28.18 to 3.28.19 (#47426)
Bumps [github/codeql-action](https://github.com/github/codeql-action) from 3.28.18 to 3.28.19.
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](ff0a06e83c...fca7ace96b)

---
updated-dependencies:
- dependency-name: github/codeql-action
  dependency-version: 3.28.19
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-06-11 11:24:03 +02:00
Niklas Wenzel
d7ef8b79ae docs: mention kwallet6 command line option (#47427) 2025-06-10 16:12:31 -04:00
Erick Zhao
6aa3665b96 docs: no class inheritance (#47403) 2025-06-10 10:00:06 +02:00
Robo
c964296ec3 feat: add support for --no-experimental-global-navigator (#47370)
chore: add support for --no-experimental-global-navigator
2025-06-09 14:57:27 +09:00
David Sanders
6f48e3ab12 ci: fix up branch CI audit workflow (#47404) 2025-06-07 09:58:48 +02:00
Shelley Vohr
06bc59be88 fix: rework lifetime mgmt of ClearDataTask/ClearDataOperation (#47361)
* fix: rework lifetime mgmt of ClearDataTask/ClearDataOperation

* Update shell/browser/api/electron_api_session.cc

Co-authored-by: Robo <hop2deep@gmail.com>

* Update shell/browser/api/electron_api_session.cc

Co-authored-by: Robo <hop2deep@gmail.com>

* Update shell/browser/api/electron_api_session.cc

Co-authored-by: Robo <hop2deep@gmail.com>

* Update shell/browser/api/electron_api_session.cc

Co-authored-by: Robo <hop2deep@gmail.com>

---------

Co-authored-by: Robo <hop2deep@gmail.com>
2025-06-07 08:00:30 +02:00
David Sanders
0b84c68229 ci: ignore network-related error annotations in audit (#47333)
* ci: ignore network-related error annotation in audit

* chore: add another error message
2025-06-06 16:52:25 -04:00
Shelley Vohr
09a0926c5b fix: printing PDF via webContents.print() (#47377)
fix: printing PDF via webContents.print()
2025-06-06 14:20:37 -04:00
Shelley Vohr
6606230813 fix: silent printing of PDFs with webContents.print (#47378)
fix: silent printing
2025-06-06 14:19:08 -04:00
David Sanders
a42afaa866 chore: fix docs lint (#47389) 2025-06-06 10:01:26 +02:00
John Kleinschmidt
b1f0ab11c5 build: cache gitcache dir (#47328)
* revert build: migrate to new chromium git auth

* build: cache gitcache dir
2025-06-05 17:00:21 -04:00
David Sanders
4c3e2eb560 build(deps-dev): bump husky and lint-staged (#47291) 2025-06-05 20:23:55 +02:00
Niklas Wenzel
72340e79e8 docs: remove electron-quick-start from README (#47359)
Refs https://github.com/electron/.permissions/pull/293

The repo was renamed to `minimal-repro` and is no longer intended to be used as a way to start new projects (see PR above).

Since we really want bugs in `electron/electron` to be reported with a Fiddle gist instead of a standalone repo (makes reproducing and bisecting sooo much easier and safer!), I removed the repo from the README completely instead of mentioning as an issue reproduction starting point.
2025-06-05 20:12:21 +02:00
Niklas Wenzel
7196a28d3a docs: mention Azure Trusted Signing (#47323) 2025-06-05 19:13:39 +02:00
Shelley Vohr
6c96979b6c chore: remove unused spec-chromium (#47367)
chore: remove unused spec-chromium
2025-06-05 15:50:19 +02:00
Felix Rieseberg
5cbab906c9 docs: Add Swift/macOS tutorial (#46697)
Co-authored-by: Felix Rieseberg <fr@makenotion.com>
2025-06-05 15:45:04 +02:00
Erick Zhao
2a51a997eb docs: update link to runAsNode fuse (#47350) 2025-06-05 10:03:58 +02:00
Shelley Vohr
fbb3fa7503 feat: allow intercepting mouse events (#47280)
* feat: allow intercepting mouse events

* test: add specs

* Update spec/api-web-contents-spec.ts

Co-authored-by: David Sanders <dsanders11@ucsbalum.com>

---------

Co-authored-by: David Sanders <dsanders11@ucsbalum.com>
2025-06-04 14:10:33 +02:00
Shelley Vohr
c22f94037a docs: document possible print failureReasons (#47337)
docs: document possible print failureReasons
2025-06-04 14:09:24 +02:00
John Kleinschmidt
ba7c3bbdf7 chore: update patches (#47346) 2025-06-03 13:52:17 -04:00
electron-roller[bot]
53fd879043 chore: bump chromium to 138.0.7190.0 (main) (#47107)
* chore: bump chromium in DEPS to 138.0.7180.0

* 6546797: Add a metric for the overall success of the "safe storage" item retrieval.

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6546797

* 6548078: extensions: Fix TODO in ScriptInjectionTracker for desktop Android

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6548078

* 6544950: Revert "FSA: Only normalize the hardcoded rules once during initialization"

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6544950

* chore: bump chromium in DEPS to 138.0.7181.0

* chore: update patches

* fix: correctly clamp HSL shift values between 0 and 1

* chore: bump DEPS to 138.0.7183.0

* 6553142: Remove SelectFileDialogLinuxKde | https://chromium-review.googlesource.com/c/chromium/src/+/6553142

* chore: update patches

* chore: bump chromium in DEPS to 138.0.7184.0

* chore: bump chromium in DEPS to 138.0.7186.0

* chore: bump chromium in DEPS to 138.0.7190.0

* chore: update patches

* 6547778: Remove some superfluous //ui/gfx includes from //chrome headers | https://chromium-review.googlesource.com/c/chromium/src/+/6547778

* 6556022: Reland FSA: Only normalize the hardcoded rules once during initialization | https://chromium-review.googlesource.com/c/chromium/src/+/6556022

* fix: remove pdf_extension_util::AddAdditionalData
https://chromium-review.googlesource.com/c/chromium/src/+/4099130

This was removed 2 years ago in Chrome.

* fix: provide BrowserContext to pdf_extension_util::AddAdditionalData
https://chromium-review.googlesource.com/c/chromium/src/+/6558173

* fixup! 6556022: Reland FSA: Only normalize the hardcoded rules once during initialization | https://chromium-review.googlesource.com/c/chromium/src/+/6556022

* fix: pass in navigation throttle registry
https://chromium-review.googlesource.com/c/chromium/src/+/6536175

* fixup! 6556022: Reland "FSA: Only normalize the hardcoded rules once during initialization" | https://chromium-review.googlesource.com/c/chromium/src/+/6556022

This partially reverts commit 20d709dd15ba0ff332e24ee314149d642dc5d47c.

* 6545984: corner-shape: render dashed & dotted borders
Refs https://chromium-review.googlesource.com/c/chromium/src/+/6545984

* Update corner smoothing expected images

* Apply "future" revert commit to fix windows build

> Reason for revert: Multiple eng reporting that this is causing build failures due to too-long pathnames, with no immediate feasible workaround

This issue also affects our CI builds.

Problematic CL in current roll: 6494836: [webgl] Add stub WebGL[2]RenderingContextWebGPU | https://chromium-review.googlesource.com/c/chromium/src/+/6494836
"Future" revert CL: 6565622: Revert "[webgl] Add stub WebGL[2]RenderingContextWebGPU" | https://chromium-review.googlesource.com/c/chromium/src/+/6565622

This patch should automatically disappear when we roll the revert.

* 6533919: win: don't add WS_CAPTION style to popup windows
https://chromium-review.googlesource.com/c/chromium/src/+/6533919

This mirrors the change made earlier to the code ours is based on: 6374074: [headless] Provide headless aware window metrics on Windows | https://chromium-review.googlesource.com/c/chromium/src/+/6374074

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: David Sanders <dsanders11@ucsbalum.com>
Co-authored-by: Keeley Hammond <khammond@slack-corp.com>
Co-authored-by: Samuel Maddock <smaddock@slack-corp.com>
Co-authored-by: clavin <clavin@electronjs.org>
2025-06-03 11:19:20 -04:00
Shelley Vohr
5f5e8d012d fix: add back fallback wasm-trap handling (#47186)
* fix: add back fallback wasm-trap handling

Refs https://chromium-review.googlesource.com/c/chromium/src/+/5372409

This change sets up wasm-trap handling for the case where content_shell
has not enabled crash reporting but moves the responsibility to
ElectronRendererClient. The default ContentRendererClient assumes
that crash reporting is enabled (crashpad enabled by default) and does
not set up its own handler.

* chore: fix build

---------

Co-authored-by: deepak1556 <hop2deep@gmail.com>
2025-06-03 15:31:23 +02:00
Calvin
508c601996 fix: do not load source for electron module in ESM loader synchronous flow (#46810) 2025-06-03 12:50:17 +02:00
Sta Zhu
158176f0f3 fix: addChildView() crashes when adding a closed WebContentsView (#47099)
fix: addChildView() crashes when add a closed WebContentsView
2025-06-03 10:53:25 +02:00
dependabot[bot]
d1e64c37a2 build(deps): bump ossf/scorecard-action from 2.4.1 to 2.4.2 (#47329)
Bumps [ossf/scorecard-action](https://github.com/ossf/scorecard-action) from 2.4.1 to 2.4.2.
- [Release notes](https://github.com/ossf/scorecard-action/releases)
- [Changelog](https://github.com/ossf/scorecard-action/blob/main/RELEASE.md)
- [Commits](f49aabe0b5...05b42c6244)

---
updated-dependencies:
- dependency-name: ossf/scorecard-action
  dependency-version: 2.4.2
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-06-03 10:18:03 +02:00
Shelley Vohr
17ba863f69 docs: correct 'select-bluetooth-device' requirement (#47325) 2025-06-03 10:16:16 +02:00
electron-roller[bot]
82a59d9894 chore: bump node to v22.16.0 (main) (#47217)
* chore: bump node in DEPS to v22.16.0

* crypto: remove BoringSSL dh-primes addition

https://github.com/nodejs/node/pull/57023

* tools: enable linter in test/fixtures/test\-runner/output

https://github.com/nodejs/node/pull/57698

* src: improve thread safety of TaskQueue

https://github.com/nodejs/node/pull/57910

* buffer: define global v8::CFunction objects as const

https://github.com/nodejs/node/pull/57676

* src: disable abseil deadlock detection

https://github.com/nodejs/node/pull/57582

* zlib: fix pointer alignment

https://github.com/nodejs/node/pull/57727

* chore: fixup patch indices

* src: set default config as node.config.json

https://github.com/nodejs/node/pull/57171

* src: update std::vector<v8::Local<T>> to use v8::LocalVector<T>

https://github.com/nodejs/node/pull/57578

* test: disable chmod tests failing in Docker

https://github.com/nodejs/node/issues/58326

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
2025-06-02 17:30:15 -04:00
David Sanders
55006fe9a8 ci: change patches stats DataDog metric type to gauge (#47319) 2025-06-02 14:49:44 -04:00
zeeker999
dc5efca0f6 feat: [net] add "priority" option to net.request (#42628)
document the default value of priority option

Update the priority test to not use the httpbin.org as server

Fixed the lint errors

Fixed the build error
2025-05-30 15:28:13 -04:00
David Sanders
cf6c662702 ci: upload stats about patches to DataDog (#47206) 2025-05-30 11:14:57 -04:00
Shelley Vohr
c84e8c6c22 feat: expose win.isContentProtected() (#47242)
* feat: expose win.isContentProtected()

* chore: remove stray _isContentProtected
2025-05-30 11:00:13 +02:00
John Kleinschmidt
46921d3652 docs: document commit signing requirement (#47290) 2025-05-30 10:59:29 +02:00
David Sanders
b303413a04 build: drop shx dependency (#47293) 2025-05-30 10:59:11 +02:00
David Sanders
83524adf17 chore: fix lint for ImageView doc (#47304) 2025-05-29 17:10:41 -04:00
David Sanders
14b3183eb5 ci: add a problem matcher for ESLint output (#47303) 2025-05-29 16:58:17 -04:00
David Sanders
0d70389ccb chore: lint code blocks in docs with ESLint (#42113) 2025-05-29 12:45:26 -07:00
Niklas Wenzel
4e61f5b26f fix: Squirrel.Mac crash when zip extraction fails (#47271)
* fix: Squirrel.Mac crash when zip extraction process fails to launch

* chore: add end-to-end test
2025-05-29 10:31:46 -07:00
Will Anderson
5b5f900e34 docs: add documentation for ImageView (#46760)
* docs: Add documentation for ImageView

* docs: Add ImageView main process module list in README.md

* test: Add some basic tests for ImageView

* test: Fill out Window embedding tests to better reflect how someone might use an ImageView

* docs: Add notes about using ImageView as a splash screen

Co-authored-by: Niklas Wenzel <dev@nikwen.de>

* docs: Update ImageView example to show a more complete splash screen example

* docs: Remove view resizing logic since the ImageView automatically gets resized

---------

Co-authored-by: Niklas Wenzel <dev@nikwen.de>
2025-05-29 10:24:16 -07:00
David Sanders
2e0b4eca94 build: remove unnecessary eslint-plugin-standard package (#47283) 2025-05-28 13:58:14 +02:00
David Sanders
3a32f25750 ci: audit important branches for CI errors (#47207)
* ci: audit important branches for CI errors

* chore: move message to Slack workflow
2025-05-27 11:35:33 -04:00
Erick Zhao
f6b8ee0731 chore: add .eslintrc.json for docs/fiddles (#47269) 2025-05-27 09:13:10 -05:00
Robo
5ccbfa2faf fix: regression with directory selection in macOS dialogs (#47259) 2025-05-27 19:08:11 +09:00
Shelley Vohr
f89c2a0ef4 fix: titlebar showing in content protected window (#47241)
Closes https://github.com/electron/electron/issues/47152.
2025-05-26 09:46:04 +02:00
Shelley Vohr
c6f368acc6 chore: debug crash on DevTools SetOwnerWindow (#47243) 2025-05-26 09:45:43 +02:00
David Sanders
5e3b5ef04c chore: update @electron/lint-roller to 3.1.1 (#47202)
* chore: update @electron/lint-roller to 3.1.1

* docs: fix broken link in breaking-changes.md

* chore: fix for Node.js versions without require(esm)
2025-05-25 07:58:55 -05:00
John Kleinschmidt
ac5e3c76f3 build: migrate to new chromium git auth (#47230) 2025-05-25 07:57:20 -05:00
Gellert Hegyi
b9b96a96f7 feat: add menu item role palette and header (#45538)
* feat: add menu item role `palette` and `header`

* adds comments

* refactors new role items to new item types

* docs: custom type

* docs: note types only available on mac 14+

---------

Co-authored-by: Samuel Maddock <smaddock@slack-corp.com>
2025-05-23 12:43:49 -04:00
Charles Kerr
2248de847d refactor: use base::fixed_flat_set in NativeWindowViews::SetAlwaysOnTop() (#47201)
refactor: use base::fixed_flat_set in NativeWindowViews::SetAlwaysOnTop()
2025-05-22 18:20:39 -05:00
Charles Kerr
38e7ff944e refactor: make NativeWindow::has_frame_ const (#47200)
* refactor: make NativeWindow::is_modal_ const

* refactor: make NativeWindow::title_bar_style_ const and private

* refactor: make NativeWindow::has_client_frame() protected

refactor: make NativeWindow::transparent() protected

* refactor: make NativeWindow::enable_larger_than_screen() protected

* refactor: make NativeWindow::has_frame_ const

* fixup! refactor: make NativeWindow::has_client_frame() protected

fix: GetExpandedWindowSize()
2025-05-22 17:32:46 -05:00
David Sanders
8f09d7037b ci: add problem matcher for patch conflict output (#47183) 2025-05-22 09:27:23 -04:00
David Sanders
d0102ff392 ci: add problem matcher for clang output (#46577) 2025-05-22 09:25:57 -04:00
Keeley Hammond
274e1df1ca build: revert bump @octokit/rest from 20.1.1 to 21.1.1 (#47208)
Revert "build(deps-dev): bump @octokit/rest from 20.1.1 to 21.1.1 (#47159)"

This reverts commit 517f5c15b9.
2025-05-21 18:39:24 -07:00
John Kleinschmidt
b2d0074cc6 build: fix depot tool pathing on Windows (#47194)
build: properly set depot_tools pathing for Windows
2025-05-21 16:05:50 -07:00
Charles Kerr
2e8fc17f07 refactor: pass views::Widget* into constructors of our TreeHosts and NativeWidgets (#47177)
* refactor: remove unnecessary downcast in MenuViews::PopupAt()

* refactor: pass a views::Widget as an arg to the ElectronDesktopWindowTreeHostLinux ctor

* refactor: pass a views::Widget as an arg to the ElectronDesktopNativeWidgetAura ctor

* refactor: pass a views::Widget as an arg to the ElectronDesktopWindowTreeHostWin ctor

* refactor: create desktop_window_tree_host_ in the ElectronDesktopNativeWidgetAura constructor

* fixup! refactor: create desktop_window_tree_host_ in the ElectronDesktopNativeWidgetAura constructor

fix: tyop
2025-05-21 16:02:55 -05:00
Charles Kerr
4af0c5d762 refactor: make NativeWindow::transparent_ const (#47172)
* refactor: use in-class member initialization for NativeWindow::widget_

* refactor: make NativeWindow::transparent_ const

refactor: make NativeWindow::enable_larger_than_screen_ const

* chore: make linter happy after rebase
2025-05-21 19:42:08 +02:00
Charles Kerr
a7a3e10300 refactor: prefer base::circular_deque over std::deque (#47171)
* refactor: use base::circular_deque in ResolveProxyHelper

* refactor: use base::circular_deque in GetExtraCrashKeys()

refactor: reduce visibility of kMaxCrashKeyValueSize

This change is to match Chromium's usage advice from
base/containers/README.md: `base:circular_deque` is preferred over
`std::deque` to provide consistent performance across platforms.
2025-05-21 12:04:36 -05:00
Shelley Vohr
7b77a24211 fix: remove extra 'suspend'/'resume' handling from powerMonitor (#47162)
fix: remove extra 'suspend'/'resume' handling from powerMonitor
2025-05-21 10:00:38 -05:00
David Sanders
7112c592c9 test: strip color output in ESM spec (#47185) 2025-05-21 10:50:06 +02:00
Charles Kerr
d6638f9564 refactor: make NativeWindow::pending_transitions_ a base::queue (#47157)
refactor: make NativeWindow::pending_transitions a base::queue

Follow the base/containers/README.md advice that "Chromium code should
always use `base::circular_deque` or `base::queue` in preference to
`std::deque` or `std::queue` due to memory usage and platform variation."
2025-05-20 17:35:51 -05:00
Charles Kerr
9f8bcc4d98 refactor: make NativeWindow::has_client_frame_ const (#47156) 2025-05-20 17:14:28 -05:00
Charles Kerr
21155679a0 refactor: add NativeWindowViews::GetClientFrameViewLinux() (#47130)
* refactor: add NativeWindowViews::GetClientFrameViewLinux()

* chore: clarify code comment
2025-05-20 14:15:06 -05:00
Charles Kerr
211faed848 refactor: add NativeWindow::IsActive() (#47148)
this was already present on macOS; use in NativeWindowViews too
2025-05-20 11:08:44 -04:00
Shelley Vohr
296e39456a refactor: match upstream macOS a11y handling (#47144) 2025-05-20 11:06:57 -04:00
John Kleinschmidt
a19198d784 build: update_depot_tools on initial install (#47160)
this ensures that python is setup for proper use from depot_tools
2025-05-20 10:40:48 -04:00
reito
263c76df09 fix: prevent gc monitor 2nd pass crash (#46987) 2025-05-20 22:54:03 +09:00
dependabot[bot]
517f5c15b9 build(deps-dev): bump @octokit/rest from 20.1.1 to 21.1.1 (#47159)
Bumps [@octokit/rest](https://github.com/octokit/rest.js) from 20.1.1 to 21.1.1.
- [Release notes](https://github.com/octokit/rest.js/releases)
- [Commits](https://github.com/octokit/rest.js/compare/v20.1.1...v21.1.1)

---
updated-dependencies:
- dependency-name: "@octokit/rest"
  dependency-version: 21.1.1
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-05-20 09:57:30 +02:00
dependabot[bot]
d29293556d build(deps): bump github/codeql-action from 3.28.15 to 3.28.18 (#47158)
Bumps [github/codeql-action](https://github.com/github/codeql-action) from 3.28.15 to 3.28.18.
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](45775bd823...ff0a06e83c)

---
updated-dependencies:
- dependency-name: github/codeql-action
  dependency-version: 3.28.18
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-05-20 09:56:54 +02:00
Shelley Vohr
e0ea069859 build: remove fix_linter_error.patch (#47150)
build: remove fix_linter_error.patch
2025-05-19 22:52:01 +02:00
electron-roller[bot]
7cc76c094a chore: bump node to v22.15.1 (main) (#47105)
* chore: bump node in DEPS to v22.15.1

* chore: fixup patch indices

* src: fix error handling on async crypto operations

https://github.com/nodejs-private/node-private/pull/709

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
2025-05-19 16:12:48 -04:00
Charles Kerr
3660432f42 refactor: NativeWindows should prefer widget() over GetWidget() for internal use (#47133) 2025-05-19 21:43:16 +02:00
Charles Kerr
687e50b4f3 refactor: add NativeWindowViews::SetTitleBarOverlay() (#47126)
* refactor: move SetTitleBarOverlay() impl to NativeWindowViews

* refactor: make NativeWindowViews::set_overlay_button_color() private

refactor: make NativeWindowViews::set_overlay_symbol_color() private

refactor: make NativeWindow::set_titlebar_overlay_height() protected

* refactor: simplify downcasting in NativeWindowViews::SetTitleBarOverlay()
2025-05-19 08:19:03 -05:00
David Sanders
d426667a01 build(dev-deps): update @electron/lint-roller and markdownlint-cli2 (#47082) 2025-05-19 14:19:04 +02:00
Charles Kerr
208bbc0504 refactor: add NativeWindow::SetShape() (#47131)
use NativeWindow::SetShape() in api::BaseWindow
2025-05-19 10:29:29 +02:00
dependabot[bot]
e2f496cfbc build(deps-dev): bump @typescript-eslint/eslint-plugin from 8.7.0 to 8.32.1 (#47135)
build(deps-dev): bump @typescript-eslint/eslint-plugin

Bumps [@typescript-eslint/eslint-plugin](https://github.com/typescript-eslint/typescript-eslint/tree/HEAD/packages/eslint-plugin) from 8.7.0 to 8.32.1.
- [Release notes](https://github.com/typescript-eslint/typescript-eslint/releases)
- [Changelog](https://github.com/typescript-eslint/typescript-eslint/blob/main/packages/eslint-plugin/CHANGELOG.md)
- [Commits](https://github.com/typescript-eslint/typescript-eslint/commits/v8.32.1/packages/eslint-plugin)

---
updated-dependencies:
- dependency-name: "@typescript-eslint/eslint-plugin"
  dependency-version: 8.32.1
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-05-19 10:27:22 +02:00
Charles Kerr
1da150f9a3 chore: remove gclient sync macOS CI hack patch (#47123)
chore: remove hack_to_allow_gclient_sync_with_host_os_mac_on_linux_in_ci.patch
2025-05-19 10:26:58 +02:00
Calvin
5dd6481e53 fix: explicit microtask scope DCHECK condition (#47134) 2025-05-19 12:08:59 +09:00
dependabot[bot]
d72e622a3f build(deps): bump slackapi/slack-github-action from 2.0.0 to 2.1.0 (#47060)
Bumps [slackapi/slack-github-action](https://github.com/slackapi/slack-github-action) from 2.0.0 to 2.1.0.
- [Release notes](https://github.com/slackapi/slack-github-action/releases)
- [Commits](485a9d42d3...b0fa283ad8)

---
updated-dependencies:
- dependency-name: slackapi/slack-github-action
  dependency-version: 2.1.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-05-16 12:55:00 -05:00
Charles Kerr
8efd24c339 perf: don't create unused menuitem icons (#47100)
GTK >= 3.90.0 removed support for menuitem icons. When Electron is
built with GTK >= 3.90.0, our code builds these icons and then throws
them away unused. Instead, let's just not build them.

Our gtk_util::GdkPixbufFromSkBitmap utility uses BGRAToRGBA and is
expensive to call.
2025-05-16 02:43:03 -05:00
Erick Zhao
dc34e8732c docs: add note on DIP and DPI (#47080) 2025-05-15 16:51:49 -05:00
Charles Kerr
77c58658c5 refactor: decouple NativeWindowViews and GlobalMenuBarX11 (#47094)
The GlobalMenuBar used to hold a raw_ptr reference to its NativeWindow;
but since it doesn't use it & only wants the gfx::AcceleratedWidget info,
let's remove the NativeWindowViews reference.

AFAICT, GlobalMenuBarX11::window_ has never been used
2025-05-15 16:10:56 -05:00
Charles Kerr
d720aea700 refactor: make TrackableObject::weak_map_id() constexpr (#47092)
* refactor: make TrackableObject::weak_map_id() constexpr

refactor: make BaseWindow::GetID() inline and constexpr

* refactor: make NativeWindow::window_id() constexpr too
2025-05-15 16:10:33 -05:00
Charles Kerr
e2bcd8f0aa test: fix desktopCapturer mocha syntax (#47088)
* test: fix desktopCapturer mocha syntax

do not nest `it` calls in desktopCapturer specs

* empty commit
2025-05-15 16:54:49 -04:00
Robo
99a3e360ec fix: opening package paths as directory on macOS (#47077) 2025-05-15 12:47:46 -05:00
electron-roller[bot]
883f48b9b4 chore: bump chromium to 138.0.7178.0 (main) (#47086)
* chore: bump chromium in DEPS to 138.0.7178.0

* 6351556: [source-phase-imports] Support Wasm Source Phase Imports

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6351556

* chore: update patches

* 6509682: extensions: Use ChromeExtensionsBrowserClient on desktop Android, part 2

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6509682

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: David Sanders <dsanders11@ucsbalum.com>
2025-05-15 12:47:07 -05:00
Charles Kerr
9a7b73b533 refactor: use kKeyModifiers in IsAltModifier() (#47066)
We probably didn't use this before because IsAltModifier() was written
two years before the KeyModifiers mask was added upstream in 98ec378a.
2025-05-14 11:00:00 -04:00
Charles Kerr
6170a5af40 chore: combine all the "patch out Profiles" changes into a single patch (#47063)
* chore: fold the profile patches into one patch

* chore: e patches all

* chore: patch out ProfileSelections::ApplyProfileSelection()

Another profile reference. Referenced iff making a debug build.
2025-05-14 09:21:11 -05:00
electron-roller[bot]
d65a856bf3 chore: bump chromium to 138.0.7177.0 (main) (#47081)
* chore: bump chromium in DEPS to 138.0.7177.0

* 6530423: [WebContents] Fix IsNeverComposited() calls during initialization

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6530423

* 6512551: [ios] Enable -Wobjc-property-assign-on-object-type

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6512551

* chore: update patches

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: David Sanders <dsanders11@ucsbalum.com>
2025-05-14 10:08:31 -04:00
Shelley Vohr
f2639d13cc refactor: remove CreateViewForWidget patch (#46981)
* refactor: remove CreateViewForWidget patch

* chore: rm unintended osr change

* Trigger CI

---------

Co-authored-by: deepak1556 <hop2deep@gmail.com>
Co-authored-by: John Kleinschmidt <jkleinsc@electronjs.org>
2025-05-14 21:43:23 +09:00
Charles Kerr
11fa915724 refactor: remove introduce_ozoneplatform_electron_can_call_x11_property.patch (#47075)
* refactor: use x11_util::IsX11() in BuildSubmenuFromModel()

* refactor: use x11_util::IsX11() in ElectronDesktopWindowTreeHostLinux::OnBoundsChanged()

* refactor: use skia_can_fall_back_to_x11 in x11_util::IsX11()

it is identical in practice to electron_can_call_x11 and does not require a Chromium patch

* chore: remove introduce_ozoneplatform_electron_can_call_x11_property.patch

* refactor: use ui::GetOzonePlatformId() to test for x11
2025-05-14 13:38:35 +09:00
David Sanders
9aacc473e6 build: remove patch that landed upstream (#47079) 2025-05-13 20:10:48 -05:00
Charles Kerr
c218128675 chore: remove disable_unload_metrics.patch (#47059) 2025-05-13 14:55:59 -04:00
electron-roller[bot]
e3e647d21e chore: bump chromium to 138.0.7175.0 (main) (#46986)
* chore: bump chromium in DEPS to 138.0.7166.0

* chore: bump chromium in DEPS to 138.0.7166.2

* 6508373: Add WebContents, Tab getters for future Clank navigation capture rework

https://chromium-review.googlesource.com/c/chromium/src/+/6508373

* 6470924: Introduce auto-populated Search Engine icons.

https://chromium-review.googlesource.com/c/chromium/src/+/6470924

* 6502977: Force same tab navigation while actor coordinator is acting on a tab

https://chromium-review.googlesource.com/c/chromium/src/+/6502977

* chore: bump chromium in DEPS to 138.0.7168.0

* chore: update patches

* fix grit patch

* chore: bump Chromium to 138.0.7169.2

* fixup! 6508373: Add WebContents, Tab getters for future Clank navigation capture rework

* 6493688: NavigationThrottleRunner2: void CreateThrottlesForNavigation

https://chromium-review.googlesource.com/c/chromium/src/+/6493688

* 6488755: Reland "WebSQL: Remove WebPreference"

https://chromium-review.googlesource.com/c/chromium/src/+/6488755

* 6428707: FSA: Only normalize the hardcoded rules once during initialization

https://chromium-review.googlesource.com/c/chromium/src/+/6428707

* chore: fixup patch indices

* chore: bump chromium in DEPS to 138.0.7170.0

* 6514121: Remove origin calculation debug info and related methods

 https://chromium-review.googlesource.com/c/chromium/src/+/6514121

* chore: bump chromium in DEPS to 138.0.7172.0

* chore: bump chromium in DEPS to 138.0.7173.0

* chore: bump chromium in DEPS to 138.0.7175.0

* fixup! 6514121: Remove origin calculation debug info and related methods

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6514121

* 6531585: Don't retry LayerTreeSink creation on the high priority queue

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6531585

* 6512253: Modernize base::apple's base bundle ID

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6512253

* fixup! 6428707: FSA: Only normalize the hardcoded rules once during initialization

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6428707

* fixup! 6508373: Add WebContents, Tab getters for future Clank navigation capture rework

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6508373

* chore: update patches

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
Co-authored-by: John Kleinschmidt <jkleinsc@electronjs.org>
Co-authored-by: David Sanders <dsanders11@ucsbalum.com>
2025-05-13 14:51:20 -04:00
Shelley Vohr
7ab032f594 fix: white window flicker on window creation (#47022) 2025-05-10 18:24:35 -05:00
Erick Zhao
2493e530d0 docs: unify [!NOTE] structure (#46893)
* docs: unify [!NOTE] structure

* Update docs/api/command-line.md

Co-authored-by: Niklas Wenzel <dev@nikwen.de>

* Update docs/api/browser-window.md

Co-authored-by: Niklas Wenzel <dev@nikwen.de>

* Update docs/api/download-item.md

Co-authored-by: Niklas Wenzel <dev@nikwen.de>

* Update docs/api/global-shortcut.md

Co-authored-by: Niklas Wenzel <dev@nikwen.de>

* revert line break

---------

Co-authored-by: Niklas Wenzel <dev@nikwen.de>
2025-05-09 14:36:42 -07:00
Michaela Laurencin
10e4f9ad37 feat: enable secondary label for macOS menu (#46887)
* feat: enable secondary label for macOS menu

* Update shell/browser/ui/cocoa/electron_menu_controller.mm

Co-authored-by: Robo <hop2deep@gmail.com>

* fix for lint

* update docs for sublabel

---------

Co-authored-by: Robo <hop2deep@gmail.com>
2025-05-09 12:05:26 -04:00
Michaela Laurencin
b9f0aebb2f feat: enable innerWidth and innerHeight for window open (#46749)
* feat: enable innerWidth and innerHeight for window open

* update comment for added special innerWidth and innerHeight

* update 100 min spec requirement handling

* update testing to include getContentSize

* update macOS min requirement handling

* adjust refactored consts

* update const values from nativewindowviews
2025-05-09 12:03:45 -04:00
Shelley Vohr
8ecd731e96 fix: webview crash on focus (#46979) 2025-05-09 17:56:22 +02:00
Shelley Vohr
75cf8ea96d fix: restore previous Windows screenshotting (#47020)
Fixes https://github.com/electron/electron/issues/45990

We previously made a change in https://github.com/electron/electron/pull/45868
to fix content protection being lost on hide and re-show. However, this
cause a breaking change where protected windows were made opaque black
instead of being hidden as before. This overrides relevant methods in
ElectronDesktopWindowTreeHostWin to restore the previous behavior.
without regressing the original issue.
2025-05-09 09:38:27 -05:00
Aman Karmani
376634c75a feat: add support for --experimental-network-inspection (#46690)
* feat: add support for `--experimental-network-inspection`

* docs: fix minor formatting issues

visible on both GH[1] and the docs site[2]

[1] https://github.com/electron/electron/blob/main/docs/api/command-line-switches.md#nodejs-flags
[2] https://www.electronjs.org/docs/latest/api/command-line-switches#--inspect-brkhostport

* docs: add entry for new nodejs flag
2025-05-09 09:44:14 -04:00
Robo
8e8d3a4f3e fix: use-after-move of bus connection in xdg portal detection (#47008) 2025-05-09 18:32:08 +09:00
Charles Kerr
2cbd968da5 refactor: use gin_helper::Dictionary::ValueOrDefault() (#46982)
* refactor: use ValueOrDefault() in electron_api_web_contents.cc

* refactor: use ValueOrDefault() in electron_api_url_loader.cc

* refactor: use ValueOrDefault() in electron_download_manager_delegate.cc

* refactor: use ValueOrDefault() in electron_touch_bar.mm

* refactor: use ValueOrDefault() in electron_url_loader_factory.cc

* refactor: use ValueOrDefault() in electron_browser_context.cc

* refactor: use ValueOrDefault() in electron_touch_bar.mm

* refactor: use ValueOrDefault() in blink_converter.cc

* feat: add ValueOrDefault() to PersistentDictionary

* empty commit

* refactor: use ValueOrDefault() in blink_converter.cc

* refactor: inline the rectangle base::Value::Dict

* refactor: remove has_scroll temporary

---------

Co-authored-by: Deepak Mohan <hop2deep@gmail.com>
2025-05-08 14:17:22 -05:00
Keeley Hammond
aea7b4ae8c build: update hasher return value (#47009) 2025-05-08 11:34:21 -07:00
Charles Kerr
9f8a629126 refactor: reduce use of NativeWidgetPrivate (#46942)
* refactor: do not use native_widget_private() in NativeWindowViews::SetContentProtection()

refactor: do not use native_widget_private() in NativeWindowViews::IsContentProtected()

* refactor: do not use native_widget_private() in NativeWindowViews::Show()

* chore: remove native_widget_private #include from native_window_views_win

Not needed since Feb 2025: 9199d5c6
2025-05-08 09:02:19 -05:00
Charles Kerr
d4ca829069 test: enable hasShadow tests on Linux (#46984)
refactor: enable hasShadow tests on Linux
2025-05-08 10:07:10 +02:00
Charles Kerr
54a6bbb4cb build: remove skip_atk_toolchain_check.patch (#46988)
chore: remove skip_atk_toolchain_check.patch
2025-05-08 10:06:55 +02:00
Charles Kerr
24f1f7ed57 build: remove deps_add_v8_object_setinternalfieldfornodecore.patch (#46992)
chore: remove deps_add_v8_object_setinternalfieldfornodecore.patch

This was a Node 20-specific workaround that's no longer needed in Node 22.

Xref: https://github.com/nodejs/node/pull/49874.
2025-05-08 09:39:58 +02:00
Keeley Hammond
153dae5b48 build: move release script to new hasher function (#46989)
build: move to new hasher function
2025-05-08 01:15:08 -05:00
Calvin
580fa57a29 refactor: Node.js temporary "explicit" microtask policy scope pattern (#46973)
refactor: Node.js explicit microtask scope pattern
2025-05-08 10:21:39 +09:00
Calvin
37639b5400 refactor: replace gin_helper::MicrotasksScope with v8::MicrotasksScope (#46963)
* Remove microtasks_scope.h and microtasks_scope.cc

* Use v8::MicrotasksScope when ignoring browser checkpoint

These call always skip the browser checkpoint, so they are equivalent to using v8::MicrotasksScope directly (modulo the optional wrapper behavior).

* Remove MicrotasksScope from node_bindings.cc

This code seems contradictory: it explicitly specifies "do not run microtasks" yet runs a microtask checkpoint in the browser process.

Looking at its history, it [was introduced][1] with the intention to not run microtasks, but a [subtle C++ language behavior][2] caused it to do the opposite later in the same roll. Since the original intention was to not run microtasks, and since that is also the simplest explanation, we can assume `ignore_browser_checkpoint` should be true and migrate this to `v8::MicrotasksScope` as it is equivalent (modulo the optional wrapper behavior).

[1]: a4ea80dd47 (diff-efe58cf03c97028f37f801db044d396a5f428686da6595d2c692f1c052bbd09c)
[2]: https://github.com/electron/electron/pull/43185

* Migrate gin_helper/promise.h and gin_helper/promise.cc to v8::MicrotasksScope

Restores the [original][1] behavior of running the microtask checkpoint at destruction, but preserves the behavior of running microtasks in the browser process. This had last changed in the migration to gin_helper::MicroTasks.

[1]: https://github.com/electron/electron/pull/16401
2025-05-07 14:10:34 -05:00
electron-roller[bot]
a8695d4387 chore: bump chromium to 138.0.7166.0 (main) (#46975)
* chore: bump chromium in DEPS to 138.0.7165.0

* 6492127: Add new less invasive context menu mode for mobile interesttarget

https://chromium-review.googlesource.com/c/chromium/src/+/6492127

* chore: fixup patch indices

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
2025-05-07 13:04:15 -04:00
Charles Kerr
924a8da940 refactor: use WidgetDelegate::SetAccessibleTitle() (#46765)
* refactor: use WidgetDelegate::SetAccessibleTitle()

* test: add window.accessibleTitle tests
2025-05-07 10:44:53 -05:00
Shelley Vohr
c16ea8d54e fix: printing when no mediaSize specified (#46937)
fix: printing when no mediaSize specified
2025-05-06 19:12:25 -05:00
Charles Kerr
b7ae162716 refactor: add gin_helper::Dictionary::ValueOrDefault() (#46939)
* feat: add gin_helper::Dictionary::ValueOrDefault()

A convenience function for using a default value if the
specified key isn't present in the dictionary.

* refactor: use ValueOrDefault() in native_window.cc

* refactor: use ValueOrDefault() in native_window_mac.mm

* refactor: use ValueOrDefault() in native_window_views.cc

* refactor: use ValueOrDefault() in electron_api_native_image.cc
2025-05-06 15:20:12 -05:00
Shelley Vohr
e876cecbc7 test: test menu rendering accelerators (#44634)
* test: test menu rendering accelerators

* Update spec/api-menu-spec.ts

Co-authored-by: John Kleinschmidt <jkleinsc@electronjs.org>

---------

Co-authored-by: John Kleinschmidt <jkleinsc@electronjs.org>
2025-05-06 14:09:35 -04:00
electron-roller[bot]
c4ac192aa4 chore: bump chromium to 138.0.7164.0 (main) (#46948)
* chore: bump chromium in DEPS to 138.0.7164.0

* 6508870: Add missing PermissionType mapping and remove default case.

https://chromium-review.googlesource.com/c/chromium/src/+/6508870

* chore: fixup patch indices

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
2025-05-06 14:01:37 -04:00
Charles Kerr
8308ac29c8 refactor: pass gfx::ResizeEdge by value (#46935)
refactor: pass gfx::ResizeEdge by value

It is an enum class, so no reason to pass by reference
2025-05-06 11:57:53 -05:00
Shelley Vohr
206544cbc0 fix: crash on macOS dialog after window-all-closed (#46927)
fix: crash on dialog after window-all-closed
2025-05-06 07:47:50 -05:00
Shelley Vohr
a5ec3f7476 fix: allowed dialog file types with one filter (#46900) 2025-05-06 10:31:00 +02:00
Erick Zhao
be399f2fee docs: use correct heading level for API function (#46892) 2025-05-05 16:10:37 -05:00
electron-roller[bot]
b90de7d07e chore: bump chromium to 138.0.7160.0 (main) (#46915)
* chore: bump chromium in DEPS to 138.0.7158.0

* chore: bump chromium in DEPS to 138.0.7160.0

* 6509206: Move Keychain UI suppression code into apple_keychain.cc

https://chromium-review.googlesource.com/c/chromium/src/+/6509206

* 6489036: Fix DesktopDataControlsDialog for Glic

https://chromium-review.googlesource.com/c/chromium/src/+/6489036

* chore: fixup patch indices

* 6506662: Reland "NavigationThrottleRunner2: content::NavigationThrottleRegistry"

https://chromium-review.googlesource.com/c/chromium/src/+/6506662

* 6499811: [video pip] Add live caption dialog

https://chromium-review.googlesource.com/c/chromium/src/+/6499811

* 6487926: Add GetMaxImageDimension function to ScreenAI service API for OCR.

https://chromium-review.googlesource.com/c/chromium/src/+/6487926

* 6494942: [json] Activate stringify fast-path by default

https://chromium-review.googlesource.com/c/v8/v8/+/6494942

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
2025-05-05 13:58:40 -04:00
Charles Kerr
9460300506 refactor: devirtualize NativeWindow methods (#46904)
* refactor: devirtualize NativeWindow::SetSize()

refactor: devirtualize NativeWindow::GetSize()

refactor: devirtualize NativeWindow::SetPosition()

refactor: devirtualize NativeWindow::GetPosition()

* refactor: devirtualize NativeWinodw::SetMinimumSize()

refactor: devirtualize NativeWinodw::GetMinimumSize()

refactor: devirtualize NativeWinodw::SetMaximumSize()

refactor: devirtualize NativeWinodw::GetMaximumSize()

* refactor: devirtualize NativeWindow::SetSheetOffset()

refactor: devirtualize NativeWindow::GetSheetOffsetX()

refactor: devirtualize NativeWindow::GetSheetOffsetY()

* refactor: devirtualize NativeWindow::GetContentMinimumSize()

refactor: devirtualize NativeWindow::GetContentMaximumSize()
2025-05-05 09:29:05 -05:00
Charles Kerr
3362db0655 refactor: remove some NativeWindow public API (#46919)
* refactor: make NativeWindow::titlebar_overlay_height_ private

* refactor: make NativeWindow::set_has_frame() protected

* refactor: remove NativeWindow::background_material()

It's only used once, in NativeWindow, so use |background_material_| directly.

* refactor: remove NativeWindow::vibrancy()

It's only used once, in a NativeWindow method, so use |vibrancy_| directly.

* refactor: unfriend api::BrowserView

It was added in Oct 2022 by 23d4a25 for access to protected NativeWindow
methods add_inspectable_view() and remove_inspectable_view().

That dependency was removed in Nov 2022 by 184ac2b, so BrowserView
doesn't need access to NativeWindow's private fields & methods anymore.

* refactor: make NativeWindow::ContentBoundsToWindowBounds() protected

refactor: make NativeWindow::WindowBoundsToContentBounds() protected
2025-05-05 09:28:49 -05:00
Charles Kerr
2e2776611f refactor: simplify NativeWindow::FullScreenTransitionState (#46918)
* refactor: make NativeWindow::fullscreen_transition_state_ private

* refactor: add NativeWindow::is_transitioning_fullscreen() helper

* refactor: remove unused NativeWindow::fullscreen_transition_state()

* refactor: replace NativeWindow::set_fullscreen_transition_state() with NativeWindow::set_is_transitioning_fullscreen()

refactor: remove unused NativeWindow::FullScreenTransitionState
2025-05-05 09:28:29 -05:00
Charles Kerr
1f4f1b4afc refactor: add NativeWindow::FromWidget() helper (#46917)
refactor: add NativeWindow::FromWidet() helper

refactor: make kElectronNativeWindowKey a protected field
2025-05-05 09:27:41 -05:00
electron-roller[bot]
cb445b3bbd chore: bump node to v22.15.0 (main) (#46742)
* chore: bump node in DEPS to v22.15.0

* inspector: fix GN build

https://github.com/nodejs/node/pull/56798

* test: search cctest files

https://github.com/nodejs/node/pull/56791

* crypto: fix missing OPENSSL_NO_ENGINE guard

https://github.com/nodejs/node/pull/57012

* test,crypto: make tests work for BoringSSL

https://github.com/nodejs/node/pull/57021

* module: use synchronous hooks for preparsing in import(cjs)

https://github.com/nodejs/node/pull/55698

* deps: update simdjson to 3.12.0

https://github.com/nodejs/node/pull/56874

* build: remove explicit linker call to libm on macOS

https://github.com/nodejs/node/pull/56901

* test: make eval snapshot comparison more flexible

https://github.com/nodejs/node/pull/57020

* src: allow embedder customization of OOMErrorHandler

https://github.com/nodejs/node/pull/57325

* src: do not pass nullptr to std::string ctor

https://github.com/nodejs/node/pull/57354

* src: lock the isolate properly in IsolateData destructor

https://github.com/nodejs/node/pull/57031

* chore: shrink --trace-atomics-wait patch

* chore: fixup patch indices

* build: fix GN build failure

https://github.com/nodejs/node/pull/57013

* crypto: expose security levels

https://github.com/nodejs/node/pull/56601

* zlib: add zstd support

https://github.com/nodejs/node/pull/52100

* test: move crypto related common utilities in common/crypto

https://github.com/nodejs/node/pull/56714

* cli: move --trace-atomics-wait to eol

https://github.com/nodejs/node/pull/52747

* test: disable test-https-client-renegotiation-limit

BoringSSL doesn't support caller-initiated renegotiation - see
https://source.chromium.org/chromium/chromium/src/+/main:third_party/boringssl/src/ssl/ssl_lib.cc;l=1627-1631

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
2025-05-05 10:23:17 +02:00
Robo
91626a8eac fix: xdg portal version detection for file dialogs on linux (#46905)
* chore: use dbus thread for portal version detection

* Update shell/browser/ui/file_dialog_linux_portal.cc

Co-authored-by: Robo <hop2deep@gmail.com>

---------

Co-authored-by: Charles Kerr <charles@charleskerr.com>
2025-05-05 16:57:20 +09:00
electron-roller[bot]
5390728cb7 chore: bump chromium to 138.0.7156.0 (main) (#46902)
* chore: bump chromium in DEPS to 138.0.7156.0

* chore: update patches

* chore: ICWYU

* Allow SecKeychain and SecItem implementations of AppleKeychain to coexist

https://chromium-review.googlesource.com/c/chromium/src/+/6444777

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: John Kleinschmidt <jkleinsc@electronjs.org>
2025-05-02 21:06:50 -04:00
Derek Cicerone
074b9344b5 fix: prevent log files being written to current directory on Windows (#44413)
* fix: prevent log files being written to current directory on Windows

* Update shell/common/logging.cc

Co-authored-by: Robo <hop2deep@gmail.com>

* chore: add test

* chore: update includes

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6418805

* chore: address review feedback

---------

Co-authored-by: Robo <hop2deep@gmail.com>
2025-05-02 16:27:29 -05:00
Charles Kerr
3faddd5ae2 refactor: move IsClosed() and IsClosable() tests into NativeWindow::Close() (#46888)
refactor: devirtualize NativeWindow::IsClosed()
2025-05-02 13:21:29 -05:00
Yuri
7153008bfa docs: clarified usage of createFromPath() (#46809)
* docs: clarified usage of createFromPath()

* Update docs/api/native-image.md

Co-authored-by: Niklas Wenzel <dev@nikwen.de>

---------

Co-authored-by: Niklas Wenzel <dev@nikwen.de>
2025-05-02 11:11:54 +02:00
Charles Kerr
f6b297a06a refactor: use base::ObserverList::Notify() (#46875)
* refactor: use ObserverList::Notify() in shell/browser/window_list.cc

* refactor: use ObserverList::Notify() in shell/browser/web_contents_zoom_controller.cc

* refactor: use ObserverList::Notify() in shell/browser/usb/usb_chooser_context.cc

* refactor: use ObserverList::Notify() in shell/browser/usb/electron_usb_delegate.cc

* refactor: use ObserverList::Notify() in shell/browser/ui/views/menu_delegate.cc

* refactor: use ObserverList::Notify() in shell/browser/ui/tray_icon.cc

* refactor: use ObserverList::Notify() in shell/browser/ui/electron_menu_model.cc

* refactor: use ObserverList::Notify() in shell/browser/serial/serial_chooser_context.cc

* refactor: use ObserverList::Notify() in shell/browser/native_window.cc

* refactor: use ObserverList::Notify() in shell/browser/serial/electron_serial_delegate.cc

* refactor: use ObserverList::Notify() in shell/browser/browser.cc

* refactor: use ObserverList::Notify() in shell/browser/api/electron_api_web_contents.cc

* refactor: use ObserverList::Notify() in shell/browser/hid/electron_hid_delegate.cc

* refactor: use ObserverList::Notify() in shell/browser/hid/hid_chooser_context.cc
2025-05-02 11:10:52 +02:00
Shelley Vohr
ede84fc327 feat: support dip <-> screen conversion on Linux X11 (#46211)
feat: support dip <-> screen conversion on Linux
2025-05-02 10:31:45 +02:00
electron-roller[bot]
2b07e6450c chore: bump chromium to 138.0.7154.0 (main) (#46872)
* chore: bump chromium in DEPS to 138.0.7152.0

* chore: update patches

* chore: bump chromium in DEPS to 138.0.7154.0

* chore: update patches

* ozone/wayland: Fix bookmark dropdown right click context menu

https://chromium-review.googlesource.com/c/chromium/src/+/6488801

* Use base::cstring_view in base::Environment

https://chromium-review.googlesource.com/c/chromium/src/+/6494292

* [A11yPerformance] Remove Add/Remove AXMode methods

https://chromium-review.googlesource.com/c/chromium/src/+/6418444

xref: https://chromium-review.googlesource.com/c/chromium/src/+/6383275

* build: update filenames.libcxx.gni

* Use base::cstring_view in base::Environment

https://chromium-review.googlesource.com/c/chromium/src/+/6494292

* Use getters to expose NativePixmapHandle from GpuMemoryBufferHandle

https://chromium-review.googlesource.com/c/chromium/src/+/6374406

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: John Kleinschmidt <jkleinsc@electronjs.org>
2025-05-01 23:53:40 -05:00
Keeley Hammond
63114e2b8e fix: revert macOS content protection logic refactor (#46886)
Revert "refactor: use upstream content protection logic on macOS (#46813)"

This reverts commit 34adb976b6.
2025-05-01 13:49:55 -07:00
Charles Kerr
df4564dc39 refactor: don't call deprecated WidgetDelegate API in NativeWindowViews (#46858)
* refactor: don't call RegisterDeleteDelegateCallback()

move NativeWindowViews' on-widget-delegate-destroyed callback logic to
the NativeWindowViews destructor.

Since NativeWindowViews subclasses from WidgetDelegate and |this| *is*
the delegate being destroyed, we can handle this more cleanly in
~NativeWindowViews() instead of in a separate callback.

* chore: remove NativeWindowViews from the grandfathered-classes-that-can-call-deprecated-views-behavior patch

* refactor: don't call RegisterDeleteDelegateCallback()

RegisterDeleteDelegateCallback() is private upstream API, so we
shouldn't be using it.

Move the on-widget-delegate-destroyed callback logic over to our methods
NativeWindowViews::OnWidgetDestroying() and
NativeWindowViews::OnWidgetDestroyed().
2025-05-01 12:07:20 -05:00
David Sanders
4f89c31956 refactor: add EmitDeprecationWarning helper (#46860)
* refactor: add EmitDeprecationWarning helper

Also switches EmitWarning to using Node's ProcessEmitWarningGeneric

* chore: use node namespace for function call
2025-04-30 13:48:35 -05:00
Charles Kerr
25d77fd1ce refactor: use WidgetDelegate's title property (#46849)
* refactor: use WidgetDelegate::SetTitle()

* Make NativeWindow::SetTitle() and NativeWindow::GetTitle() non-virtual.
  Use WidgetDelegate for their implementation.

* Add NativeWindow::OnTitleChanged(), a new protected virtual method to update
  subclasses (e.g. NativeWindowMac needs to redraw the button proxy).

* In NativeWindowMac, replace SetTitle() and GetTitle() with OnTitleChanged().

* In NativeWindowViews, replace SetTitle() and GetTitle() with OnTitleChanged().

* test: enable BrowserWindow.title tests on Linux

* test: add a test to confirm win.title changes when document.title is set in the renderer
2025-04-30 08:22:27 -07:00
electron-roller[bot]
d842d17ff3 chore: bump chromium to 137.0.7151.0 (main) (#46854)
* chore: bump chromium in DEPS to 137.0.7151.0

* chore: update patches

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: John Kleinschmidt <jkleinsc@electronjs.org>
2025-04-29 16:49:44 -04:00
dependabot[bot]
ecd745305e build(deps): bump actions/download-artifact from 4.2.1 to 4.3.0 (#46852)
Bumps [actions/download-artifact](https://github.com/actions/download-artifact) from 4.2.1 to 4.3.0.
- [Release notes](https://github.com/actions/download-artifact/releases)
- [Commits](95815c38cf...d3f86a106a)

---
updated-dependencies:
- dependency-name: actions/download-artifact
  dependency-version: 4.3.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-04-29 11:20:23 -04:00
Charles Kerr
2734088d20 fix: fix and enable accessibilitySupportEnabled tests (#46825)
* test: do not skip visibleOnAllWorkspaces tests on Windows

That feature is supported on Linux, so move the test from the
"window states (excluding Linux)" section into the
"window states" section.

* fix: nested it() calls in visibleOnAllWorkspaces specs

* test: enable accessibilitySupportEnabled tests

test: check both getters after calling each setter

fix: do not assume the default initial value of accessibilitySupportEnabled

* chore: remove redundant test case

* chore: disable accessibilitySupportEnabled tests on Linux
2025-04-28 23:52:26 -05:00
zoy
4641bc9619 fix: fullscreen fillet / recovery is incorrect (#46641)
* fix: fullscreen fillet / recovery is incorrect

Signed-off-by: ZOY\zoy-l <zoy-l@outlook.com>

* fix: maintain frameless consistency on windows 11

* fix: maintain frameless consistency on windows 11

* chore: modify the comments

---------

Signed-off-by: ZOY\zoy-l <zoy-l@outlook.com>
2025-04-28 16:54:08 -04:00
Charles Kerr
3f3c297c7a fix: enable some tests that were accidentally disabled (#46816)
* test: add platform test on visibleOnAllWorkspaces tests

visibleOnAllWorkspaces is not supported on Windows

* test: do not skip visibleOnAllWorkspaces tests on Windows

That feature is supported on Linux, so move the test from the
"window states (excluding Linux)" section into the
"window states" section.

* fix: nested it() calls in visibleOnAllWorkspaces specs

* chore: make the process.platform test simpler

* fix: tests that were not run in api-app-spec due to nested it()

* fix: tests that were not run in api-browser-window-spec due to nested it()

* chore: annotate disabled test

* fix: enable `autoHideMenuBar` tests on Linux and Windows (#46818)

* fix: enable autoHideMenuBar tests

* docs: mark autoHideMenuBar as supported on Linux, Windows
2025-04-28 12:32:57 -05:00
Bruno Pitrus
062d3a6168 fix: build error with enable_electron_extensions=false (#46812)
Fix build error with enable_electron_extensions=false

In file included from ../../base/allocator/partition_allocator/src/partition_alloc/pointers/raw_ptr_backup_ref_impl.h:13,
                 from ../../base/allocator/partition_allocator/src/partition_alloc/pointers/raw_ptr.h:50,
                 from ../../base/memory/raw_ptr.h:11,
                 from ../../base/memory/weak_ptr.h:82,
                 from ../../electron/shell/browser/usb/electron_usb_delegate.h:14,
                 from ../../electron/shell/browser/usb/electron_usb_delegate.cc:5:
../../base/allocator/partition_allocator/src/partition_alloc/partition_address_space.h:279:3: warning: multi-line comment [-Wcomment]
  279 |   //       \
      |   ^
../../base/allocator/partition_allocator/src/partition_alloc/partition_address_space.h:281:3: warning: multi-line comment [-Wcomment]
  281 |   //         \
      |   ^
In file included from /usr/include/c++/14/memory:78,
                 from ../../electron/shell/browser/usb/electron_usb_delegate.h:8:
/usr/include/c++/14/bits/unique_ptr.h: In instantiation of ‘void std::default_delete<_Tp>::operator()(_Tp*) const [with _Tp = device::mojom::UsbDeviceInfo]’:
/usr/include/c++/14/bits/unique_ptr.h:399:17:   required from ‘std::unique_ptr<_Tp, _Dp>::~unique_ptr() [with _Tp = device::mojom::UsbDeviceInfo; _Dp = std::default_delete<device::mojom::UsbDeviceInfo>]’
  399 |           get_deleter()(std::move(__ptr));
      |           ~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~
../../mojo/public/cpp/bindings/struct_ptr.h:48:3:   required from ‘constexpr void std::destroy_at(_Tp*) [with _Tp = mojo::StructPtr<device::mojom::UsbDeviceInfo>]’
   48 |   ~StructPtr() = default;
      |   ^
/usr/include/c++/14/bits/stl_construct.h:149:22:   required from ‘constexpr void std::_Destroy(_Tp*) [with _Tp = mojo::StructPtr<device::mojom::UsbDeviceInfo>]’
  149 |       std::destroy_at(__pointer);
      |       ~~~~~~~~~~~~~~~^~~~~~~~~~~
/usr/include/c++/14/bits/stl_construct.h:163:19:   required from ‘static constexpr void std::_Destroy_aux<<anonymous> >::__destroy(_ForwardIterator, _ForwardIterator) [with _ForwardIterator = mojo::StructPtr<device::mojom::UsbDeviceInfo>*; bool <anonymous> = false]’
  163 |             std::_Destroy(std::__addressof(*__first));
      |             ~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~
/usr/include/c++/14/bits/stl_construct.h:193:44:   required from ‘constexpr void std::_Destroy(_ForwardIterator, _ForwardIterator) [with _ForwardIterator = mojo::StructPtr<device::mojom::UsbDeviceInfo>*]’
  193 |         return std::_Destroy_aux<false>::__destroy(__first, __last);
      |                ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~
/usr/include/c++/14/bits/alloc_traits.h:981:20:   required from ‘constexpr void std::_Destroy(_ForwardIterator, _ForwardIterator, allocator<_T2>&) [with _ForwardIterator = mojo::StructPtr<device::mojom::UsbDeviceInfo>*; _Tp = mojo::StructPtr<device::mojom::UsbDeviceInfo>]’
  981 |       std::_Destroy(__first, __last);
      |       ~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~
/usr/include/c++/14/bits/stl_vector.h:735:15:   required from ‘constexpr std::vector<_Tp, _Alloc>::~vector() [with _Tp = mojo::StructPtr<device::mojom::UsbDeviceInfo>; _Alloc = std::allocator<mojo::StructPtr<device::mojom::UsbDeviceInfo> >]’
  735 |         std::_Destroy(this->_M_impl._M_start, this->_M_impl._M_finish,
      |         ~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  736 |                       _M_get_Tp_allocator());
      |                       ~~~~~~~~~~~~~~~~~~~~~~
../../electron/shell/browser/usb/electron_usb_delegate.cc:231:74:   required from here
  231 |     std::move(callback).Run(std::vector<device::mojom::UsbDeviceInfoPtr>());
      |                                                                          ^
/usr/include/c++/14/bits/unique_ptr.h:91:23: error: invalid application of ‘sizeof’ to incomplete type ‘device::mojom::UsbDeviceInfo’
   91 |         static_assert(sizeof(_Tp)>0,
      |                       ^~~~~~~~~~~
2025-04-28 11:56:17 -04:00
electron-roller[bot]
f2240e07f0 chore: bump chromium to 137.0.7149.0 (main) (#46777)
* chore: bump chromium in DEPS to 137.0.7144.0

* chore: bump chromium in DEPS to 137.0.7145.0

* chore: bump chromium in DEPS to 137.0.7147.0

* chore: update patches

* Remove deprecated GetVar(std::string_view, std::string*) overload

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6468873

* fixup! Remove deprecated GetVar(std::string_view, std::string*) overload

* fixup! Remove deprecated GetVar(std::string_view, std::string*) overload

* chore: bump chromium in DEPS to 137.0.7149.0

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: deepak1556 <hop2deep@gmail.com>
2025-04-28 11:39:12 -04:00
David Sanders
0c103f390c test: refactor deprecate-helpers.ts to warning-helpers.ts (#46808)
Add a generic expectWarningMessages and start checking warning names
2025-04-28 11:18:34 -04:00
Charles Kerr
27f6adf8df fix: run visibleOnAllWorkspaces tests on the right platforms (#46815)
* test: add platform test on visibleOnAllWorkspaces tests

visibleOnAllWorkspaces is not supported on Windows

* test: do not skip visibleOnAllWorkspaces tests on Windows

That feature is supported on Linux, so move the test from the
"window states (excluding Linux)" section into the
"window states" section.

* fix: nested it() calls in visibleOnAllWorkspaces specs

* chore: make the process.platform test simpler
2025-04-28 10:34:00 -04:00
Shelley Vohr
b03c71213e refactor: use upstream content protection logic on macOS (#46780)
* refactor: use upstream content protection logic on macOS

* Update shell/browser/native_window.h

Co-authored-by: Charles Kerr <charles@charleskerr.com>

---------

Co-authored-by: Charles Kerr <charles@charleskerr.com>
2025-04-26 11:31:30 -05:00
Charles Kerr
c2ab63f6d7 refactor: use absl::InlinedVector in ToV8(ElectronPermissionManager) (#44854)
perf: use a stack-allocated string_view array in ToV8(USBProtectedClasses)
2025-04-25 16:11:15 -05:00
Calvin
b92c68b053 docs: call out breaking change for GTK 4 default on GNOME (#46793)
docs: add breaking change for GTK 4 default on GNOME
2025-04-25 13:31:28 -07:00
Charles Kerr
450b2d0ba3 refactor: remove public method BrowserWindow::GetWeakPtr() (#46763)
refactor: remove public method electron::api::BrowserWindow::GetWeakPtr()
2025-04-25 15:01:52 -05:00
Charles Kerr
b40b4dc015 refactor: use std::map::try_emplace() over std::map::insert() (#46761)
refactor: prefer std::map::try_emplace() over std::map::insert()
2025-04-25 13:11:53 -05:00
Evan Simkowitz
8fa7d324d1 fix: set XDG_CURRENT_DESKTOP env var back to original value before invoking xdg utils (#45310)
* Fix XDG_CURRENT_DESKTOP before invoking XDGUtil

* apply suggestion

* use existing XDG_CURRENT_DESKTOP const
2025-04-25 11:31:36 -05:00
Felix Rieseberg
7fa297a849 docs: Add ObjC/macOS tutorial (#46694) 2025-04-25 10:29:25 -05:00
John Kleinschmidt
55505ba4df docs: additional update of breaking changes for 36-x-y (#46781) 2025-04-25 11:28:33 -04:00
Shelley Vohr
372cdb5dee fix: bluetooth crash in select-bluetooth-device event (#46745)
fix: bluetooth crash on bluetooth off
2025-04-25 10:26:19 -05:00
Calvin
973e5d0249 build: update NMV to 136 for Electron 37 (#46764)
build: update NMV to 136 for Electron 36
2025-04-25 11:20:29 -04:00
Michaela Laurencin
0171f648b1 docs: correct breaking-changes.md for 36.0.0 release (#46762) 2025-04-25 16:10:35 +02:00
Charles Kerr
74c4ae0b55 refactor: use net::CanonicalCookie::IsDomainMatch() (#46748)
* refactor: use net::CanonicalCookie::IsDomainMatch()

Previously we had been rolling our own impl

* test: add pattern-matching tests for our cookie API
2025-04-25 16:08:16 +02:00
Charles Kerr
06a99d6770 refactor: make node Buffers more friendly to base::span / std::span (#46724)
* refactor: add electron::Buffer namespace; move the Buffer as_byte_span() into it

* feat: add electron::Buffer::Copy()

a span-friendly version of node::Buffer::Copy()

* refactor: use electron::Buffer::Copy() in electron_api_base_window.cc

* refactor: use electron::Buffer::Copy() in electron_api_data_pipe_holder.cc

* refactor: use electron::Buffer::Copy() in electron_api_safe_storage.cc

* refactor: use electron::Buffer::Copy() in electron_api_clipboard.cc

* refactor: use electron::Buffer::Copy() in osr_converter.cc

* refactor: use electron::Buffer::Copy() in electron_api_native_image.cc

* refactor: use electron::Buffer::Copy() in net_converter.cc

* refactor: use electron::Buffer::Copy() in electron_api_web_contents.cc

* refactor: make NewEmptyBuffer() return a Local<Value>
2025-04-25 08:00:09 -05:00
Shelley Vohr
1976e935e7 fix: missing HandleScope in RemoveFromParentChildWindows (#46758) 2025-04-25 14:04:25 +02:00
Calvin
51dbe69e45 fix: vibrancy window border (#46648)
* fix: vibrancy window border

* Use WidgetDelegate::OnWidgetInitialized instead
2025-04-25 11:42:48 +02:00
Calvin
08318dc05d fix: corner smoothing with 0 radii (#46751) 2025-04-25 10:54:04 +02:00
wujinli
3e78bbde6a fix: crash when renderer process crashes while webview is reloading (#46735)
WebView uses WebContentsViewChildFrame, which doesn't have a Focus impl
and triggers a fatal NOTREACHED.
2025-04-25 10:10:27 +02:00
electron-roller[bot]
37f8db15e9 chore: bump chromium to 137.0.7143.0 (main) (#46757)
* chore: bump chromium in DEPS to 137.0.7142.0

* chore: bump chromium in DEPS to 137.0.7143.0

* Add accelerator API to get shortcut vector representation

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6442193

* chore: update patches

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: deepak1556 <hop2deep@gmail.com>
2025-04-25 14:53:51 +09:00
electron-roller[bot]
08b7a1f801 chore: bump chromium to 137.0.7141.0 (main) (#46725)
* chore: bump chromium in DEPS to 137.0.7139.0

* chore: bump chromium in DEPS to 137.0.7141.0

* chore: update patches

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6474596
Refs https://chromium-review.googlesource.com/c/chromium/src/+/6443472
Refs https://chromium-review.googlesource.com/c/chromium/src/+/6471184

* [ServiceWorker] Pipe is_for_service_worker into OverrideURLLoaderFactoryParams

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6459481

* Reland "[PermissionOptions] Use PermissionDescriptorPtr in PermissionControllerDelegate"

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6455975

* clickiness: Check attestation and user settings on origins

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6356796

* extensions : Move ReloadExtension from ExtensionService

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6472812
Refs https://chromium-review.googlesource.com/c/chromium/src/+/6472777

* fixup! Update AppleKeychain API to be friendlier

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6443472

* chore: script/gen-libc++-filenames.js

* Rename ColorVariant::CovertToSkColor() to ColorVariant::ResolveToSkColor()

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6373793

* [headless] Provide headless aware window metrics on Windows

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6374074

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: deepak1556 <hop2deep@gmail.com>
2025-04-24 17:18:38 +09:00
Charles Kerr
e9f279afd1 chore: remove WebContents.getNativeView() (#46734)
chore: remove never-used WebContents.getNativeView().

This was added in https://github.com/electron/electron/pull/10308 but
was never used and never documented, not even as experimental API.
2025-04-23 20:33:50 -05:00
Charles Kerr
c7b0bdab7e fix: explicitly call GetNativeNSView() on macOS (#46733)
* fix: explicitly call GetNativeNSView() on macOS

* chore: move macOS impl to a .mm file

This is needed in order to access gfx::NativeView::GetNativeNSView()
2025-04-23 17:55:18 -05:00
Charles Kerr
686ae47696 refactor: remove redundant NativeImage::GetBitmap() (#46696)
* refactor: remove redundant NativeImage::GetBitmap()

* docs: mark NativeImage.getBitmap() as deprecated

* have getBitmap() emit a deprecation warning

* docs: update obsolete refefence to getBitmap()

* test: update obsolete refefences to getBitmap()

---------

Co-authored-by: David Sanders <dsanders11@ucsbalum.com>
2025-04-23 11:00:43 +02:00
electron-roller[bot]
dd03cceda0 chore: bump chromium to 137.0.7128.1 (main) (#46482)
* chore: bump chromium in DEPS to 137.0.7107.0

* chore: bump chromium in DEPS to 137.0.7109.0

* chore: bump chromium in DEPS to 137.0.7111.0

* chore: bump chromium in DEPS to 137.0.7113.0

* 6384240: Remove double-declaration for accessibility on macOS | https://chromium-review.googlesource.com/c/chromium/src/+/6384240

* 6422872: Remove unused includes in isolation_info_mojom_traits.h | https://chromium-review.googlesource.com/c/chromium/src/+/6422872

* chore: update patches

* 6400733: Avoid ipc_message_macros.h usage in some foo_param_traits_macros.h files | https://chromium-review.googlesource.com/c/chromium/src/+/6400733

* chore: update patches

* 6423410: Enable unsafe buffer warnings for chromium, try #3. | https://chromium-review.googlesource.com/c/chromium/src/+/6423410

* chore: iwyu

* refactor: prefer value initialization over memset()

From the looks up upstream commits in base/, it looks like memset()
could trigger `-Wunsafe-buffer-usage` warnings soon?

Value initialization is more C++ish and less error-prone anyway,
due to memset()'s easily swappable parameters.

* refactor: NotifyIcon::InitIconData() returns a NOTIFYICONDATA

This follows F.20 in the C++ Core Guidelines and also removes the need
for memset()

* 6423410: Enable unsafe buffer warnings for chromium, try #3. | https://chromium-review.googlesource.com/c/chromium/src/+/6423410

remove all uses of:

- strcmp()

* fixup!  6423410: Enable unsafe buffer warnings for chromium, try #3. | https://chromium-review.googlesource.com/c/chromium/src/+/6423410

* 6433203: Add a PassKey to RegisterDeleteDelegateCallback(). | https://chromium-review.googlesource.com/c/chromium/src/+/6433203

* chore: bump chromium in DEPS to 137.0.7115.0

* 6387077: [PermissionOptions] Generalize PermissionRequestDescription | https://chromium-review.googlesource.com/c/chromium/src/+/6387077

* chore: update patches

* 6387077: [PermissionOptions] Generalize PermissionRequestDescription | https://chromium-review.googlesource.com/c/chromium/src/+/6387077

* fix: add pragma for MacSDK unsafe buffers | 6423410: Enable unsafe buffer warnings for chromium, try #3. | https://chromium-review.googlesource.com/c/chromium/src/+/6423410

* chore: bump chromium in DEPS to 137.0.7117.0

* chore: update patches

* chore: update filesnames.libcxx.gni

* 6431756: Replace SetOwnedByWidget() bool arg with a PassKey. | https://chromium-review.googlesource.com/c/chromium/src/+/6431756

* 6387077: [PermissionOptions] Generalize PermissionRequestDescription | https://chromium-review.googlesource.com/c/chromium/src/+/6387077

* 6428345: Remove ExtensionService usage from ChromeExtensionRegistrarDelegate | https://chromium-review.googlesource.com/c/chromium/src/+/6428345

* 6384315: Migrate extensions_enabled from ExtensionService to Registrar | https://chromium-review.googlesource.com/c/chromium/src/+/6384315

* 6428749: [extensions] Refactor ExtensionService for AddNewAndUpdateExtension. | https://chromium-review.googlesource.com/c/chromium/src/+/6428749

* chore: bump chromium in DEPS to 137.0.7119.0

* 6440290: corner-shape: support inset shadow | https://chromium-review.googlesource.com/c/chromium/src/+/6440290

* 6429230: FSA: Move blocked paths to the PermissionContext class | https://chromium-review.googlesource.com/c/chromium/src/+/6429230

* chore: update patches

* chore: bump chromium in DEPS to 137.0.7121.0

* chore: update patches

* fix: partially revert 6443473: Remove ItemDelete from the Mac version of AppleKeychain | https://chromium-review.googlesource.com/c/chromium/src/+/6443473

* fix: update filenames.libcxx.gni

* chore: bump chromium in DEPS to 137.0.7123.0

* chore: update patches

* chore: "grandfather in" electron views too

Lock further access to View::set_owned_by_client() | https://chromium-review.googlesource.com/c/chromium/src/+/6448510

* chore: update feat_corner_smoothing_css_rule_and_blink_painting.patch

corner-shape: support inset shadow | https://chromium-review.googlesource.com/c/chromium/src/+/6440290

* refactor: grandfather in AutofillPopupView as a subclass of WidgetDelegateView

Add a PassKey for std::make_unique<WidgetDelegateView>() | https://chromium-review.googlesource.com/c/chromium/src/+/6442265

* Provide dbus appmenu information on Wayland | https://chromium-review.googlesource.com/c/chromium/src/+/6405535

* [extensions] Move OnExtensionInstalled out of ExtensionService. | https://chromium-review.googlesource.com/c/chromium/src/+/6443325

* refactor: grandfather in NativeWindowViews for delete callbacks

6433203: Add a PassKey to RegisterDeleteDelegateCallback(). | https://chromium-review.googlesource.com/c/chromium/src/+/6433203

* chore: merge the four "grandfather" patches into one

* [A11yPerformance] Remove IsAccessibilityAllowed() | 6404386: [A11yPerformance] Remove IsAccessibilityAllowed() | https://chromium-review.googlesource.com/c/chromium/src/+/6404386

NB: the changes here are copied from the upstream changes in
chrome/browser/ui/webui/accessibility/accessibility_ui.cc

* 6420753: [PermissionOptions] Use PermissionDescriptorPtr in PermissionController | https://chromium-review.googlesource.com/c/chromium/src/+/6420753

* 6429573: [accessibility] Move mode change out of AccessibilityNotificationWaiter | https://chromium-review.googlesource.com/c/chromium/src/+/6429573

* chore: e patches all

* 6419936: [win] Change ScreenWin public static methods to virtual | https://chromium-review.googlesource.com/c/chromium/src/+/6419936

* 6423410: Enable unsafe buffer warnings for chromium, try #3. | https://chromium-review.googlesource.com/c/chromium/src/+/6423410

remove all uses of:

- fprintf()
- fputs()
- snprintf()
- vsnprintf()

* fix: size conversion FTBFS on Win

* 6423410: Enable unsafe buffer warnings for chromium, try #3. | https://chromium-review.googlesource.com/c/chromium/src/+/6423410

remove all uses of:

- wcscpy_s()

* 6423410: Enable unsafe buffer warnings for chromium, try #3. | https://chromium-review.googlesource.com/c/chromium/src/+/6423410

remove all uses of:

- wcsncpy_s()

* chore: update mas_avoid_private_macos_api_usage.patch.patch

6394283: Remove double-declaration for accessibility on iOS | https://chromium-review.googlesource.com/c/chromium/src/+/6394283

Lots of context shear in this commit but the only interesting part is:

-+  return nullptr;
++  return {};

Which is needed because the return type is sometimes not a pointer.

* chore: e patches all

* chore: disable -Wmacro-redefined warning in electron_main_win.cc

* chore: bump chromium in DEPS to 137.0.7123.5

* refactor: patch electron PermissionTypes into blink

6387077: [PermissionOptions] Generalize PermissionRequestDescription | https://chromium-review.googlesource.com/c/chromium/src/+/6387077

* chore: e patches all

* chore: remove the box_painter_base.cc part of feat_corner_smoothing_css_rule_and_blink_painting.patch

as per code review @ https://github.com/electron/electron/pull/46482#pullrequestreview-2777338370

* test: enable window-smaller-than-64x64 test on Linux

* chore: bump chromium in DEPS to 137.0.7124.1

* chore: bump chromium in DEPS to 137.0.7125.1

* chore: bump chromium in DEPS to 137.0.7127.3

* 6459201: [Extensions] Remove ExtensionSystem::FinishDelayedInstallationIfReady() | https://chromium-review.googlesource.com/c/chromium/src/+/6459201

* 6454796: [Extensions] Move (most) registrar delayed install logic to //extensions | https://chromium-review.googlesource.com/c/chromium/src/+/6454796

* chore: bump chromium in DEPS to 137.0.7128.1

* chore: e patches all

* chore: node ./script/gen-libc++-filenames.js

* [views] Gate DesktopWindowTreeHostWin::window_enlargement_ behind flag

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6428649

* feat: allow opt-out animated_content_sampler.

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6438681

* Trigger CI

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: Keeley Hammond <khammond@slack-corp.com>
Co-authored-by: Charles Kerr <charles@charleskerr.com>
Co-authored-by: Keeley Hammond <vertedinde@electronjs.org>
Co-authored-by: deepak1556 <hop2deep@gmail.com>
Co-authored-by: John Kleinschmidt <jkleinsc@electronjs.org>
2025-04-22 15:53:29 -04:00
Kolja
d0e13cc262 fix: file dialog filters not working correctly (#46660) 2025-04-22 13:31:04 +02:00
Shelley Vohr
858a93f886 build: don't kill ssh sessions on checkout failure (#46708) 2025-04-22 13:30:27 +02:00
Michaela Laurencin
e383eaa465 fix: stop menu minimization if set false (#46279) 2025-04-22 10:58:30 +02:00
Milan Burda
274b148554 docs: cleanup docs/tutorial/custom-window-styles.md (#46597) 2025-04-22 10:23:35 +02:00
Charles Kerr
7083419361 refactor: make electron::api::BaseWindow fields private (#46689)
refactor: make electron::api::BaseWindow fields private
2025-04-22 10:19:11 +02:00
reito
ac2c0c76fe fix: osr stutter fix backport for electron. (#46650)
* fix: osr stutter fix backport for electron.

* nit: chromium upstream patch link
2025-04-22 10:18:21 +02:00
Michaela Laurencin
3ad87787f8 docs: update timelines for E37 (#46704) 2025-04-21 13:34:02 -07:00
Robo
ec8f7f185e fix: crash on reconversion with google IME and editcontext on macOS (#46688) 2025-04-21 09:49:14 +09:00
Calvin
f15fa56e38 refactor: reduce & remove no-op MicrotasksScope calls (#46681)
* fix: do not run microtasks in V8Serializer in browser process

* Remove no-op MicrotasksScope in `shell/browser/api/electron_api_auto_updater.cc`

This call was added in https://github.com/electron/electron/pull/40576 as an expansion of `gin_helper::EmitEvent`.

Since this only runs in the browser process and `bool ignore_browser_checkpoint = true` this code is a no-op.

Node should perform a microtask checkpoint if necessary in `node::MakeCallback`.

* Remove no-op MicrotasksScope in `shell/common/api/electron_bindings.cc`

This method is only called by the browser process. The containing function, `ElectronBindings::DidReceiveMemoryDump`, is only used in two places:

* `ElectronBindings::GetProcessMemoryInfo` in the same file, which has a `CHECK` that it's running in the browser process at the top.
* From `shell/browser/api/electron_api_web_contents.cc`, which is only run in the browser process.

Added a DCHECK for clarity and validation.

* Replace `gin_helper::MicrotasksScope` with `v8::MicrotasksScope` in `shell/renderer/`

The browser check is unnecessary in the renderer. Since `gin_helper::MicrotasksScope` will always act exactly like `v8::MicrotasksScope`, it's clear to just use the v8 object directly. This also brings them in line with the many other uses of `v8::MicrotasksScope` in `shell/renderer/`.
2025-04-19 12:18:03 -05:00
Charles Kerr
297c4297b1 perf: avoid triple map lookup in ElectronHidDelegate::GetContextObserver() (#46672)
perf: avoid triple map lookup in ElectronHidDelegate::GetContextObserver()
2025-04-19 10:51:52 -05:00
Calvin
3a982ecad5 fix: do not run microtasks in V8Serializer in browser process (#46668) 2025-04-19 11:43:02 +09:00
Charles Kerr
926a6ee8bd refactor: remove WebContentsPermissionHelper::PermissionTypes::KEYBOARD_LOCK (#46670)
refactor: remove electron::WebContentsPermissionHelper::PermissionTypes::KEYBOARD_LOCK

This was added in 344aba0. In the time when this PR initially went up and
when 344aba0 landed, upstream added blink::PermissionTypes::KEYBOARD_LOCK.
Our duplicate copy can be removed.
2025-04-18 16:14:45 -05:00
Shelley Vohr
437542767a fix: backgroundMaterial on initial activate (#46657)
* fix: backgroundMaterial on initial activate

Closes https://github.com/electron/electron/issues/38466

* Update patches/chromium/fix_activate_background_material_on_windows.patch

Co-authored-by: Charles Kerr <charles@charleskerr.com>

---------

Co-authored-by: Charles Kerr <charles@charleskerr.com>
2025-04-17 20:34:45 +02:00
Shelley Vohr
a29e1170b9 feat: support Web Serial & WebUSB blocklists (#46600) 2025-04-17 20:34:34 +02:00
Shelley Vohr
352a403efd fix: postMessage crash with invalid transferrable (#46639) 2025-04-17 15:09:48 +02:00
John Kleinschmidt
e8117f8e40 build: update build tools (#46656)
* build: update build tools

* chore: fix core.fscache

* chore: fix core.preloadindex

---------

Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
2025-04-17 10:32:17 +02:00
Shelley Vohr
32fea719b3 refactor: migrate to non-deprecated allowedContentTypes on macOS (#46623)
refactor: migrated to non-deprecated allowedContentTypes on macOS
2025-04-15 09:51:34 -05:00
Shelley Vohr
14df4aab83 fix: window border on Gnome Wayland (#46624) 2025-04-15 15:45:33 +02:00
dependabot[bot]
24e46849c7 build(deps): bump actions/setup-node from 4.3.0 to 4.4.0 (#46636)
Bumps [actions/setup-node](https://github.com/actions/setup-node) from 4.3.0 to 4.4.0.
- [Release notes](https://github.com/actions/setup-node/releases)
- [Commits](cdca7365b2...49933ea528)

---
updated-dependencies:
- dependency-name: actions/setup-node
  dependency-version: 4.4.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-04-15 15:44:04 +02:00
Shelley Vohr
489d30edfb build: roll build-images (#46625) 2025-04-14 16:10:46 -04:00
Shelley Vohr
e748b521b2 test: fix node spec disabled tests (#46627) 2025-04-14 11:38:27 -04:00
Shelley Vohr
51bffb533e fix: paint and flash issues on macOS (#46615)
* fix: paint and flash issues on macOS

* Adhere to paintWhenInitiallyHidden
2025-04-14 16:29:07 +02:00
Shelley Vohr
62b5b5f99d fix: handle potential missing close event property (#46605)
fix: handle missing close event property
2025-04-11 13:07:26 -04:00
Keeley Hammond
a9b2ec514b fix: fallback to old MacOS context menu behavior if no frame is present (#46595)
* fix: fallback to old MacOS context menu behavior if no frame is present

Co-authored-by: georgexu99 <georgexu99@electronjs.org>
Co-authored-by: erickzhao <erickzhao@electronjs.org>
Co-authored-by: clavin <calvin@electronjs.org>

* docs: add additional option for focusedFrame

* fix: handle frame found, but no view update from rfh

* fix: fix conditional

Co-authored-by: Calvin <clavin@users.noreply.github.com>

---------

Co-authored-by: georgexu99 <georgexu99@electronjs.org>
Co-authored-by: erickzhao <erickzhao@electronjs.org>
Co-authored-by: clavin <calvin@electronjs.org>
Co-authored-by: Calvin <clavin@users.noreply.github.com>
2025-04-11 10:15:35 -04:00
Shelley Vohr
3064b24c9d refactor: use default printing path when no user options (#46587) 2025-04-11 10:14:29 -04:00
David Sanders
74d641c7b3 build: ignore files in .git when running markdownlint-cli2 (#46608) 2025-04-10 18:37:07 -05:00
Shelley Vohr
446d0769ed feat: expose nativeTheme.shouldUseDarkColorsForSystemIntegratedUI (#46438)
feat: expose shouldUseDarkColorsForSystemIntegratedUI

Closes https://github.com/electron/electron/issues/46429.
Refs https://github.com/electron/electron/pull/19735.

This PR adds a new API `shouldUseDarkColorsForSystemIntegratedUI` to the
`nativeTheme` module. This API returns a boolean indicating whether the
system is using dark colors for system integrated UI elements. This is
useful for applications that want to adapt their UI to match the system
theme, especially for those that use system integrated UI elements like
the shell theme or taskbar appearance.
2025-04-10 12:08:29 +02:00
Jemil Suleimanov
013133867b docs: unify documentation example and fiddle for IPC pattern-1 (#46517)
* docs: unify documentation examples and fiddle

* docs: remove changes in ipc documentation
2025-04-10 12:08:10 +02:00
Yuri
de407e82b7 docs: updated tray doc with tooltip removing (#46515)
added tooltip removing doc
2025-04-09 11:50:08 -04:00
Charles Kerr
c6e6a03a24 fix: NativeWindow.window_id() returns same value for all windows (#46562)
fix: NativeWindow.window_id() returns same value for all windows
2025-04-09 10:45:06 -05:00
Shelley Vohr
c1c74b0a6c fix: re-enable OOP printing on Linux (#46529) 2025-04-09 15:42:16 +02:00
Shelley Vohr
45a0494287 fix: remove obsoleted --inspect-brk logic (#46560)
fix: remove obsoleted --inspect-brk logic
2025-04-09 15:35:40 +02:00
Shelley Vohr
521108e2a5 fix: crash on parent window close and focur/blur (#46559) 2025-04-09 15:35:30 +02:00
dependabot[bot]
93a51cc756 build(deps): bump github/codeql-action from 3.28.13 to 3.28.15 (#46554)
Bumps [github/codeql-action](https://github.com/github/codeql-action) from 3.28.13 to 3.28.15.
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](1b549b9259...45775bd823)

---
updated-dependencies:
- dependency-name: github/codeql-action
  dependency-version: 3.28.15
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-04-09 10:36:38 +02:00
Charles Kerr
ab23758e51 refactor: use v8::True(isolate) and v8::False(isolate) (#46544) 2025-04-08 12:58:39 -05:00
Charles Kerr
9069542d0b refactor: remove unnecessary const_cast (#46543)
refactor: remove unnecessary const_cast

unnecessary since July 2019 in 50b9c70
2025-04-08 12:58:28 -05:00
Charles Kerr
636cbc19ac refactor: simplify some BaseWindow JS getters (#46542)
* refactor: return a std::array<int 2> from BaseWindow::GetMaximumSize()

* refactor: return a std::array<int 2> from BaseWindow::GetMinimumSize()

* refactor: return a std::array<int 2> from BaseWindow::GetPosition()

* refactor: return a std::array<int 2> from BaseWindow::GetSize()

* refactor: return a std::array<int 2> from BaseWindow::GetContentSize()

* refactor: extract helper method ToArray(const gfx::Size)

* refactor: #include correctness
2025-04-08 10:58:12 -05:00
Shelley Vohr
1a6de10da8 fix: assert.ok in the renderer process (#46528)
fix: assert.ok in the renderer process
2025-04-08 07:09:54 -05:00
Charles Kerr
b1731407bc refactor: make TrackableObjectBase::weak_map_id_ const (#46524)
refactor: make TrackableObjectBase::weak_map_id_ const

simplify declaration and initialization
2025-04-07 20:49:05 -05:00
Charles Kerr
4bb7a4ceb0 refactor: make api::View methods const, private (#46545)
* refactor: make api::View::GetBounds() const

* refactor: make api::View::OnViewBoundsChanged() private

refactor: make api::View::OnViewIsDeleting() private

refactor: make api::View::OnChildViewRemoved() private

* refactor: make ChildPair private
2025-04-07 16:23:36 -05:00
Shelley Vohr
e22b83abf2 build: update codespaces config (#46533) 2025-04-07 16:29:33 -04:00
Niklas Wenzel
bbc9d1cdc1 build: emphasize the need for a testcase in our issue template (#46447) 2025-04-07 10:50:59 -07:00
Charles Kerr
85dce12be3 refactor: migrate to View::AddChildView(std::unique_ptr<ui::View*>) (#46474)
* refactor: use AddChildView(std::unique_ptr<View>) in OpaqueFrameView::CreateButton()

Xref: https://issues.chromium.org/issues/40485510

* refactor: use AddChildView(std::unique_ptr<View>) in MenuBar::RebuildChildren()

* refactor: use AddChildView(std::unique_ptr<View>) for ClientFrameViewLinux labels

* refactor: use AddChildView(std::unique_ptr<View>) for ClientFrameViewLinux buttons

* refactor: use AddChildView(std::unique_ptr<View>) in AutofillPopupView

* refactor: use AddChildViewRaw() to flag the edge cases that we still need to fix

* chore: use west coast const for consistency
2025-04-07 09:20:46 -05:00
Charles Kerr
a6875c732c docs: note that titleBarOverlay.symbolColor is supported on Linux (#46492)
docs: note that titleBarOverlay.symbolColor is supported on Linux

this is supported via OpaqueFrameView
2025-04-07 11:10:54 +02:00
Charles Kerr
c0fdf09f28 perf: on Windows, make Archive::HeaderIntegrity() faster (#46509)
* perf: do not clone the map each time we call Archive::HeaderIntegrity()

* perf: use absl::flat_hash_map for the integrity cache

* perf: do not clone the JSON payload string

* perf: preallocate capacity for the integrity cache

* perf: use move variant of insert_or_assign()

* refactor: simplify integrity cache building

remove unnecessary std::optional<>

* refactor: use base::FindOrNull()

* refactor: remove unused #includes

* refactor: make variable types explicit

* fix: make res_size unsigned

* refactor: put GetIntegrityConfigCache() in an unnamed namespace

refator: put LoadIntegrityConfig() in an unnamed namespace

* fix: oops, missing rel_path_utf8 key

* fix: oops, fix Wunreachable-code-return
2025-04-07 11:10:29 +02:00
Charles Kerr
41d8f90d68 refactor: use base::flat_set in WebContents::DidUpdateFaviconUrl() (#46475)
* refactor: add gin::Converter<std::span>::ToV8()

* feat: add ToV8(const base::flat_set<T>&)

* perf: use a flat_set in WebContents::TitleWasSet()

* refactor: add gin::Converter<std::array>::ToV8()
2025-04-07 10:16:02 +02:00
Charles Kerr
3c5c9c8e19 perf: avoid redundant virtual method call in NativeWindowViews::SetEnabledInternal() (#46508)
perf: avoid redundant virtual method call in NativeWindowViews::SetEnabledInternal()

Why waste time make lot call when few call do trick?
2025-04-06 19:02:04 -07:00
Hailey
ac18decc56 revert: allow NSMenuItems to be disabled (#46502)
Revert "fix: allow NSMenuItems to be disabled (#46307)"

This reverts commit ac616ef41d.
2025-04-06 20:42:05 -05:00
Charles Kerr
052da50aeb refactor: remove unused electron::api::App::FileIconCallback (#46490)
refactor: remove electron::api::App::FileIconCallback

last use removed in 2018 by 3f15f516
2025-04-05 00:39:17 -05:00
Charles Kerr
4e33d1690d refactor: instantiate navigation_entries local variable on the stack (#46453)
* refactor: instantiate navigation_entries on the stack instead of the heap

* refactor: reserve the full size of navigation_entries

* refactor: use emplace_back to simplify the code a little
2025-04-04 16:55:27 -05:00
Shelley Vohr
c2ae4afb8f fix: destroy parent port backend when JS env exits (#46437)
* fix: destroy parent port backend when JS env exits

* fix: close parent port before destroying

---------

Co-authored-by: deepak1556 <hop2deep@gmail.com>
2025-04-04 11:02:54 -05:00
Felix Rieseberg
e81e3acd2d docs: Add C++/Win32 tutorial (#46160)
* docs: Add C++/Win32 tutorial

* Update docs/tutorial/native-code-and-electron-cpp-win32.md

Co-authored-by: Erick Zhao <erick@hotmail.ca>

* Update docs/tutorial/native-code-and-electron-cpp-win32.md

Co-authored-by: Erick Zhao <erick@hotmail.ca>

* Update docs/tutorial/native-code-and-electron-cpp-win32.md

Co-authored-by: Erick Zhao <erick@hotmail.ca>

* Update docs/tutorial/native-code-and-electron-cpp-win32.md

Co-authored-by: Erick Zhao <erick@hotmail.ca>

* Update docs/tutorial/native-code-and-electron-cpp-win32.md

Co-authored-by: Erick Zhao <erick@hotmail.ca>

* docs: make linter happy

---------

Co-authored-by: Erick Zhao <erick@hotmail.ca>
Co-authored-by: Charles Kerr <charles@charleskerr.com>
2025-04-04 08:00:45 -05:00
electron-roller[bot]
9c019b6147 chore: bump chromium to 136.0.7095.0 (main) (#46118)
* chore: bump chromium in DEPS to 136.0.7076.0

* chore: bump chromium in DEPS to 136.0.7077.0

* 6368856: Migrate absl variant.h and utility.h in content (part 2/2) | https://chromium-review.googlesource.com/c/chromium/src/+/6368856

* 6356528: Clean up LegacyRenderWidgetHostHWND code | https://chromium-review.googlesource.com/c/chromium/src/+/6356528

* chore: export patches

* 6339113: [Viewport Segments] Add CDP commands to override Viewport Segments without overriding other device properties. | https://chromium-review.googlesource.com/c/chromium/src/+/6339113

* 6352169: [DevTools][MultiInstance] Support new tab in another window on Android | https://chromium-review.googlesource.com/c/chromium/src/+/6352169

* 6368856: Migrate absl variant.h and utility.h in content (part 2/2) | https://chromium-review.googlesource.com/c/chromium/src/+/6368856

* 6360858:Clickiness: Wire response from URLLoader to DB, add e2e tests| https://chromium-review.googlesource.com/c/chromium/src/+/6360858

* chore: bump chromium in DEPS to 136.0.7079.0

* chore: export patches

* chore: bump chromium in DEPS to 136.0.7081.0

* chore: export patches

* chore: bump chromium in DEPS to 136.0.7083.0

* 6361987: Remove double-declaration with gfx::NativeView and gfx::NativeWindow | https://chromium-review.googlesource.com/c/chromium/src/+/6361987

* chore: export patches

* chore: bump chromium in DEPS to 136.0.7087.0

* chore: export patches

* fix: include node patch for missing AtomicsWaitEvent
https://chromium-review.googlesource.com/c/chromium/src/+/6385540

* build: add depot_tools python to path

* fix: cppgc init and unregistering v8 isolate

https://chromium-review.googlesource.com/c/v8/v8/+/6333562

CppGc is now initialized earlier so Node can skip reinitializing it.

Additionally, gin::IsolateHandle was attempting to destruct an already destructed
v8::Isolate upon electron::JavaScriptEnvironment destruction. By removing the call
to NodePlatform::UnregisterIsolate, this fixes the crash on app shutdown.

* fix: unregister isolate after destruction

See code comment.

* chore: bump chromium in DEPS to 136.0.7095.0

* chore: sync patches

* fix: add script_parsing::ContentScriptType parameter
https://chromium-review.googlesource.com/c/chromium/src/+/6298395

* fix: migrate content::BrowserAccessibilityState methods
https://chromium-review.googlesource.com/c/chromium/src/+/6401437
https://chromium-review.googlesource.com/c/chromium/src/+/6383275

* feat: enableHappyEyeballs option for host resolver
https://chromium-review.googlesource.com/c/chromium/src/+/6332599

* fix: add new cookie exclusion reason
https://chromium-review.googlesource.com/c/chromium/src/+/6343479

* fix: add new url loader method
https://chromium-review.googlesource.com/c/chromium/src/+/6337340

* fix: add new cppgc header file for electron_node headers
https://chromium-review.googlesource.com/c/v8/v8/+/6348644

* fix: disable CREL on Linux ARM64
https://chromium-review.googlesource.com/q/I3a62f02f564f07be63173b0773b4ecaffbe939b9

* fixup! fix: add new cppgc header file for electron_node headers https://chromium-review.googlesource.com/c/v8/v8/+/6348644

* chore: update corner smoothing patch

* fixup! chore: update corner smoothing patch

* chore: disable NAN weak tests

These two tests are incompatible with a V8 change that disallows running JS code from a weak finalizer callback.

Ref: https://chromium-review.googlesource.com/c/v8/v8/+/4733273

* test: fix task starvation in node test

A V8 change makes these contexts get collected in a task that is posted
and run asynchronously. The tests were synchronously GC'ing in an
infinite loop, preventing the task loop from running the task that would
GC these contexts.

This change should be upstreamed in some way.

Ref: https://chromium-review.googlesource.com/c/v8/v8/+/4733273

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: alice <alice@makenotion.com>
Co-authored-by: Samuel Maddock <smaddock@slack-corp.com>
Co-authored-by: John Kleinschmidt <jkleinsc@electronjs.org>
Co-authored-by: clavin <clavin@electronjs.org>
2025-04-03 19:02:49 -05:00
Charles Kerr
0a5da83a1b perf: avoid redundant map lookup in HidChooserContext::DeviceChanged() (#46451)
perf: avoid redundant map lookup in HidChooserContext::DeviceChanged()
2025-04-03 17:51:37 -05:00
Fedor Indutny
7601af5200 fix: don't copy 'package.json's out of ASAR file (#46390)
New Node.js module resolution system reads `package.json` from imported
modules by reading from the file natively in C++ without calling into
`fs.readFileSync`. The ASAR FS wrapper code had copied files out into a
temporary folder as a workaround, but it is inefficient and does not
cover all module resolution mechanisms in Node.js.

In this change we expose `overrideReadFileSync` method on the `modules`
binding in Node.js, and use this override to call into ASAR-supporting
`fs.readFileSync`.
2025-04-03 13:39:53 -07:00
yangllu
e46b0c8ddc fix: gin_helper::Promise in GPUInfoManager must be destroyed before destroying Node/V8 (#46434)
* fix: gin_helper::Promise in GPUInfoManager must be destroyed before destroying Node/V8

* fix: use CleanedUpAtExit to control the lifetime of GPUInfoManager
2025-04-03 10:12:12 -07:00
Samuel Attard
0e3246e20d fix: ensure maximize is emitted when reduce motion is enabled on macOS (#46459)
* fix: ensure maximize is emitted when reduce motion is enabled on macOS

* Revert "build: reenable graphics effects for macOS tests (#46454)"

This reverts commit 682ea345ac.
2025-04-03 11:14:16 -05:00
Charles Kerr
0ff98810ba fix: NativeWindowViews::GetRestoredState() can return wrong state when maximized (#46450)
fix: NativeWindowViews::GetRestoredState() returning wrong state

Introduced by the af58931 Chromium 131.0.6744.0 roll, specifically
https://github.com/electron/electron/pull/43948/commits/9840662#diff-f9d7ef7

98406626
2025-04-03 08:55:04 -05:00
Shelley Vohr
f48680a983 fix: zlib pointer alignment (#46435)
fix: fix zlib pointer alignment
2025-04-03 09:35:38 -04:00
Niklas Wenzel
682ea345ac build: reenable graphics effects for macOS tests (#46454) 2025-04-02 21:33:12 -05:00
Charles Kerr
a21c805ece perf: avoid redundant call to virtual methods GetProcess() and GetID() (#46409) 2025-04-02 11:57:09 -05:00
Charles Kerr
6f24dbaab4 perf: prefer absl::flat_hash_set over std::set when sorted order is not needed (#46410)
* perf: use an absl::flat_hash_set for UsbChooserContext::ephemeral_devices_

* perf: use an absl::flat_hash_set for GlobalMenuBarRegistrarX11::live_windows_

* perf: use an absl::flat_hash_set for NativeWindowViews::forwarding_windows_

* perf: use an absl::flat_hash_set for OffScreenRenderWidgetHostView::guest_host_views_

perf: use an absl::flat_hash_set for OffScreenRenderWidgetHostView::proxy_views_

* perf: use an absl::flat_hash_set for NativeWindow::injected_frames_

* perf: use an absl::flat_hash_set for NativeWindow::background_throttling_sources_
2025-04-02 11:03:36 -05:00
Charles Kerr
36e233797c perf: cache the return value of IsX11() (#46391)
* perf: cache the return value of IsX11()

* fix: mark as nodiscard for those who call, but mark as maybe_unused for Windows
2025-04-01 15:28:01 -05:00
Shelley Vohr
c02e5bc72c build: make it clearer when cookie auth runs (#46406) 2025-04-01 10:44:51 -07:00
Charles Kerr
5499c800a7 perf: avoid redundant map lookup in UsbChooserContext::OnDeviceRemoved() (#46387) 2025-04-01 12:39:34 -05:00
Charles Kerr
0492f0f745 perf: have ErrorThrower lazily lookup the current isolate (#46388)
perf: have ErrorThrower lazy-lookup the current isolate

ErrorThrower's default constructor is marked as "should rarely if ever
be used" because it's expensive to call.

Unfortunately, nearly every instance of ErrorThrower comes as an argument
in gin_helper's JS-->C++ function marshalling where a thrower is
default-constructed and then populated in gin_helper::GetNextArgument()
with an assignment operator to a temporary ErrorThrower constructed
with the gin::Arguments' isolate.

tldr: most of the time we use the slow constructor first, then throw
that work away unused by overwriting with a fast-constructed one.

This refactor avoids that cost by deferring the expensive work to
`ErrorThrower::isolate()`, where it happens only as a fallback iff
isolate_ hasn't been set.
2025-04-01 12:25:27 -05:00
Charles Kerr
ac1ffb1bff fix: leaked gfx::Canvas in AutofillPopupView::OnPaint() (#46384)
* perf: avoid redundant call to popup_bounds_in_view()

* refactor: use a std::optional<> for paint_canvas local

* fix: fix leaked gfx::Canvas in AutofillPopupView::OnPaint()

* refactor: remove redundant get() call when testing smart pointer for nonempty

* refactor: remove unnecessary draw_canvas variable

* refactor: rename bitmap to offscreen_bitmap for symmetry

* refactor: avoid another redundant call to popup_bounds_in_view()
2025-04-01 11:22:26 -05:00
Charles Kerr
5a6f1ede6a feat!: remove support for ProtocolResponse.session null value (#46264)
BREAKING CHANGE

This was deprecated in f7ba0d3b & is now being removed for Electron 37.
2025-04-01 08:52:12 -05:00
zoy
0e687d3082 fix: rounded corners disappear momentarily on window close (#46382)
fix: Explicitly set rounded corners in borderless mode on Windows 11

Signed-off-by: zoy <zoy-l@outlook.com>
2025-04-01 15:43:54 +02:00
Calvin
08da2b0b07 chore: move build files to build/ dir (#46368) 2025-04-01 13:42:14 +02:00
Shelley Vohr
9c4720766d fix: UtilityProcess.fork crash before app ready (#46380)
fix: UtilityProcess.fork crash before app ready
2025-04-01 13:42:03 +02:00
Shelley Vohr
5da75c4a97 feat: support system-context-menu on Linux (#45848)
feat: support system-context-menu on Linux
2025-04-01 11:00:39 +02:00
Charles Kerr
77833eddfb perf: avoid unnecessary vector copy in GetMimeTypeToExtensionIdMap() (#46373)
* perf: avoid making an unnecessary copy of the vector

MimeTypesHandler::GetMIMETypeAllowlist() returns a const&, so we can
iterate that directly instead of making a temporary copy of it.

* perf: move the call to ExtensionRegistry::Get() outside of the loop

Also, keep the previous behavior of not calling it at all if there
aren't any whitelisted extensions.

* perf: avoid redundant map lookup

* refactor: const correctness

* refactor: cleanup
2025-03-31 21:52:49 -05:00
Calvin
1730062c8f fix: flicker and ghosting in transparent windows on macOS (#46353)
* fix: transparent flicker on MAS

* Gate condition on `IsTranslucent` instead
2025-03-31 18:12:35 -05:00
Calvin
09135443a0 feat: Corner Smoothing CSS rule (Reland) (#46278)
* feat: Corner Smoothing CSS rule (Reland)

Reland of #45185

* Fix patch conflicts

* fixup! Fix patch conflicts

* Update expected image

The dashed border is subtly different. The new version is correct and the old one was incorrect.
2025-03-31 11:22:23 -05:00
Charles Kerr
fcd836e34f refactor: remove field unused weak_factory_ (#46363)
refactor: remove unused weak_factory_

Appears to have been added in e3f61b46 but never used
2025-03-31 10:39:21 +02:00
Charles Kerr
28fd7c5a17 perf: improve temporaries in WebWorkerObserver::WorkerScriptReadyForEvaluation() (#46347)
refactor: small refactor to WebWorkerObserver::WorkerScriptReadyForEvaluation()

- replace a std::vector<std::string> local with a compile-time array
  of std::string_view
- remove .c_str() pessimization when making v8 Strings from string_views
2025-03-30 23:21:39 -05:00
Charles Kerr
ae6930030a perf: prefer absl::flat_hash_set over std::unordered_set (#46348)
* perf: use absl::flat_hash_set in SpellCheckClient::SpellCheckText()

* perf: use absl::flat_hash_set in MessagePort::DisentanglePorts()
2025-03-30 23:21:18 -05:00
Charles Kerr
2fa4fb0da9 refactor: use v8::String::Empty() when creating empty strings (#46349)
refactor: use v8::String::Empty() when creating empty strings
2025-03-30 21:14:18 -05:00
Charles Kerr
bf93427cbb perf: avoid double map lookup in HidChooserContext::DeviceRemoved() (#46343) 2025-03-28 21:34:24 -05:00
Charles Kerr
72fc65d2c5 perf: avoid 3x call to GetID() in RegisterPendingSiteInstance() (#46339)
perf: avoid 3x call to GetID() in RegisterPendingSiteInstance()
2025-03-28 21:33:45 -05:00
Charles Kerr
2baa4a3514 perf: avoid a double-map lookup in NotificationPresenter::RemoveNotification() (#46338)
perf: avoid a double-map lokup in NotificationPresenter::RemoveNotification()
2025-03-28 21:33:11 -05:00
Samuel Attard
49aba471dc feat: add support for associating a Menu with a WebFrameMain (#45138)
* feat: add support for associating a Menu with a WebFrameMain

This allows certain OS level features to activate such as Writing Tools, Autofill.. and Services.

There appears to be a bug in macOS where the responder chain isn't traversed if the menu is not popped up using an event, as such we spoof a fake mouse event at the write coordinates in the right window and use that to open the menu.

* build: fix build on non-mac

* build: oops missed a header

* fix: safely handle optional T* by checking nullptr too

* build: fix gn check and build errors

* docs: suggested changes

* feat: default `frame` to `window.webContents.mainFrame` when possible

* fix: avoid deref nullptr view

* Revert "feat: default `frame` to `window.webContents.mainFrame` when possible"

This reverts commit 2e88836819.

* fix: lint

* Remove redundant scoped objects

This code, including the comments, matches almost exactly the behavior of this argument to the function.

* Add ScopedPumpMessagesInPrivateModes patch

* More null pointer safety

---------

Co-authored-by: clavin <clavin@electronjs.org>
2025-03-28 11:50:07 -07:00
Charles Kerr
46b108e9a4 perf: avoid redundant map lookups in GetStorageMask() (#46315)
* perf: avoid a redundant map lookuop in GetStorageMask()

* perf: avoid a redundant map lookup in GetDataTypeMask()
2025-03-28 00:25:25 -05:00
Hailey
ac616ef41d fix: allow NSMenuItems to be disabled (#46307)
* fix: disable NSMenu autoenable feature to allow disabling of NSMenuItems

* style: fix linter issues and update comments

* chore: remove unneeded comment
2025-03-27 17:43:46 -07:00
Charles Kerr
e09712f0e1 perf: avoid a triple-redundant map lookup in ViewsDelegate::GetAppbarAutohideEdges() (#46306)
perf: avoid a triple-redundant map lookup in ViewsDelegate::GetAppbarAutohideEdges()
2025-03-27 14:32:27 -05:00
Charles Kerr
35c90fd807 perf: avoid double map lookup in WebFrameMain::UpdateRenderFrameHost() (#46293)
perf: avoid double map lookup in WebFrameMain::UpdateRenderFrameHost()
2025-03-27 14:32:01 -05:00
Shelley Vohr
756423e81e build: validate Chromium cookie authentication (#46274) 2025-03-27 14:29:01 -05:00
Shelley Vohr
dc61a6ab80 fix: possible crash in shell.readShortcutLink (#46294)
fix: possible crash in shell.readShortcutLink
2025-03-27 14:27:32 -05:00
Shelley Vohr
a0c859fc4f build: roll build-images SHAs (#46291) 2025-03-27 10:39:02 +01:00
Shelley Vohr
17e38230d5 fix: crash when drag-dropping some files (#46253)
* fix: crash when drag-dropping some files

* fix: extra destination context scope
2025-03-26 17:17:23 -05:00
Charles Kerr
3ae285b614 perf: avoid std::map temporaries in WebContents::DevToolsRequestFileSystems() (#46268)
* perf: move the GetDevToolsWebContents() call outside of the loop

* perf: remove std::map temporary in WebContents::DevToolsRequestFileSystems()

* refactor: remove unused GetAddedFileSystemPaths()

* perf: remove std::vector temporary in WebContents::DevToolsRequestFileSystems()
2025-03-26 16:26:56 -05:00
Shelley Vohr
3212f60d69 fix: set userAgent on navigationHistory.restore() (#46260)
fix: set userAgent on navigationHistory restore
2025-03-26 10:59:19 -05:00
Charles Kerr
a5076a663b perf: avoid redundant map lookup in WebContents::DevToolsIndexPath() (#46254)
perf: avoid double map lookup in WebContents::DevToolsIndexPath()
2025-03-26 10:30:02 -05:00
Shelley Vohr
d2c2261c58 fix: hard crash on invalid command line switches (#46004)
* fix: hard crash on invalid command line switch

* Update docs/api/command-line.md

Co-authored-by: Niklas Wenzel <dev@nikwen.de>

* chore: feedback from review

* docs: Add breaking change note

---------

Co-authored-by: Niklas Wenzel <dev@nikwen.de>
2025-03-26 08:14:03 -05:00
Charles Kerr
8412d78310 perf: avoid redundant map lookup in AddComponentResourceEntries() (#46255)
* perf: avoid double map lookup in ElectronComponentExtensionResourceManager::AddComponentResourceEntries()

* perf: move the path key when calling try_emplace()
2025-03-26 08:12:16 -05:00
Charles Kerr
48a38c0289 fix: build failure when printing is disabled (#46283)
fix: ftbfs when printing is disabled
2025-03-26 10:04:39 +01:00
Charles Kerr
6e44662f15 perf: avoid redundant map lookup in WebFrameMain constructor (#46238)
perf: avoid double map lookup in WebFrameMain constructor
2025-03-25 16:53:24 -05:00
Charles Kerr
c8d3184a95 refactor: migrate hashing code to new upstream crypto::hash API (#46237)
* refactor: migrate AsarFileValidator to crypto::hash

This change migrates AsarFileValidator's uses of crypto::secure_hash
to the new crypto::hash API, which has more memory safety and less
heap allocations.

Xref: https://chromium-review.googlesource.com/c/chromium/src/+/6287609

* refactor: migrate ValidateIntegrityOrDie to crypto::hash

This change migrates ValidateIntegrityOrDie's use of crypto::SHA256Hash
to the new crypto::hash API, which has more memory safety and less heap
allocations.

Xref: https://chromium-review.googlesource.com/c/chromium/src/+/6287609
2025-03-25 15:01:17 -05:00
dependabot[bot]
bb0ddcad27 build(deps): bump actions/setup-node from 4.2.0 to 4.3.0 (#46092)
Bumps [actions/setup-node](https://github.com/actions/setup-node) from 4.2.0 to 4.3.0.
- [Release notes](https://github.com/actions/setup-node/releases)
- [Commits](1d0ff469b7...cdca7365b2)

---
updated-dependencies:
- dependency-name: actions/setup-node
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-03-25 13:29:22 -05:00
John Kleinschmidt
4eda76de36 build: fixup windows source cache for release (#46236)
* build: fixup windows source cache for release

* build: fixup ffmpeg gn gen

* build: add build-tools depot_tools to PATH

There are some cases where it is still expected that depot_tools be in the path

* put back regular gn gen for ffmpeg

* build: add retry to moving source cache

This resolves the error: `Move-Item : The process cannot access the file because it is being used by another process.`
2025-03-25 14:24:58 -04:00
Charles Kerr
ced8fdbce8 perf: avoid std::map temporaries in IsDevToolsFileSystemAdded() (#46230)
* refactor: extract-method GetAddedFileSystems()

* refactor: use GetAddedFileSystems() in GetAddedFileSystemPaths()

* refactor: use GetAddedFileSystems() in IsDevToolsFileSystemAdded()
2025-03-25 11:42:58 -05:00
Charles Kerr
f7ba0d3b4b docs: deprecate setting ProtocolResponse.session to null (#46131)
* docs: deprecate setting ProtocolResponse.session to null

* docs: mark null ProtocolResponse.session as deprecated in struct docs

* Update docs/breaking-changes.md

Co-authored-by: Keeley Hammond <vertedinde@electronjs.org>

---------

Co-authored-by: Keeley Hammond <vertedinde@electronjs.org>
2025-03-25 10:04:21 -05:00
Charles Kerr
4f4e23a3b3 perf: avoid redundant map lookups in GlobalShortcut (#46229)
* perf: avoid redundant map lookup in GlobalShortcut::OnKeyPressed()

* perf: avoid redundant map lookup in GlobalShortcut::ExecuteCommand()
2025-03-25 09:46:03 -05:00
Shelley Vohr
1d6cb348b4 fix: webContents.printToPDF() with cross-process subframes (#46218)
fix: webContents.printToPDF() with cross-process subframes
2025-03-25 08:16:47 -05:00
dependabot[bot]
8e856dfdb8 build(deps): bump github/codeql-action from 3.28.11 to 3.28.13 (#46240)
Bumps [github/codeql-action](https://github.com/github/codeql-action) from 3.28.11 to 3.28.13.
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](6bb031afdd...1b549b9259)

---
updated-dependencies:
- dependency-name: github/codeql-action
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-03-25 12:21:23 +01:00
John Beutner
cf82c3215f perf: don't wait for thumbnails if they were not requested on macOS (#46138)
When using the SCK thumbnail capturer, the first refresh has the list of
sources, and the second refresh has the thumbnails. If thumbnails are
not needed, only wait for the first refresh.
2025-03-25 12:20:38 +01:00
Robo
307d4f94c7 fix: oob string read when parsing node_options (#46210)
* fix: oob string read when parsing node_options

* chore: re-enable test

* fix: missing linux server env for tests
2025-03-25 19:33:10 +09:00
dependabot[bot]
cfada0347e build(deps): bump actions/download-artifact from 4.1.9 to 4.2.1 (#46239) 2025-03-25 08:47:33 +01:00
dependabot[bot]
7cb921369b build(deps): bump actions/upload-artifact from 4.6.1 to 4.6.2 (#46241) 2025-03-25 08:46:18 +01:00
Robo
a86e44b176 fix: NODE_OPTIONS parsing for child processes on macOS (#46209)
* fix: NODE_OPTIONS parsing for child processes on macOS

* chore: temporarily disable test

* chore: apply review feedback

* chore: fix build
2025-03-25 13:01:37 +09:00
Calvin
abaef13c0b fix: Revert "feat: Corner Smoothing CSS rule" (#46231)
Revert "feat: Corner Smoothing CSS rule (#45185)"

This reverts commit b75e802280.
2025-03-24 20:36:49 +01:00
John Beutner
cfd64b5f89 fix: handle OnDelegatedSourceListDismissed asynchronously (#46112)
This fixes a crash with the PipeWire capturer caused by a Chromium
change introduced in
https://chromium-review.googlesource.com/c/chromium/src/+/5783826.

DesktopMediaListBase now calls Refresh(true) after dispatching
DesktopMediaListObserver::OnDelegatedSourceListDismissed, so it's
important not to call DesktopCapturer::HandleFailure (which deallocates
the DesktopMediaList) synchronously from OnDelegatedSourceListDismissed.
2025-03-24 20:09:11 +01:00
John Kleinschmidt
cbcd779610 build: fixup release builds (#46228) 2025-03-24 14:34:57 -04:00
Calvin
b75e802280 feat: Corner Smoothing CSS rule (#45185)
* feat: Corner Smoothing

* Patch Blink to add CSS rule and Painting

* Add `system-ui` keyword

* Add `cornerSmoothingCSS` web preference

* Add tests

* Documentation

* fixup! Documentation

* fix: initialize smoothness value

* Use a 1.0 scale factor in tests

* Fix tests for CI

* Fix tests

* fixup! Merge branch 'main' into clavin/corner-smoothing

* Add code docs

* Document `system-ui` keyword values

* Address review comments

* fixup! Address review comments

* Address review comments

* Update patch to address upstream changes

The patch went from 694 lines to 505 lines, which is a 27.2% smaller!

* fixup! Update patch to address upstream changes
2025-03-24 11:46:12 -04:00
Shelley Vohr
9ec14b91e7 feat: add BrowserWindow.isSnapped() (#46079)
* feat: add BrowserWindow.isSnapped() on Windows

* docs: mark _Readonly_
2025-03-24 12:09:14 +01:00
Shelley Vohr
47cf4e7bfd fix: Wayland resizing border (#46155)
* fix: Wayland resizing border

Closes https://github.com/electron/electron/issues/44543
Refs CL:5180720

Fixes an issue where the resizing border didn't work as expected on Wayland windows.

* fix: border insets when fullscreen
2025-03-24 12:08:24 +01:00
Charles Kerr
b8150f33db refactor: remove unused weak_factory_ in electron_management_api_delegate.cc (#46200)
refactor: remove unused weak_factory_

Appears to have been added in 3745b76da but never used
2025-03-24 12:07:49 +01:00
Charles Kerr
02a4bd5942 refactor: remove unused method ProxyingWebSocket::web_request_api() (#46201)
Appears to have been added in c608d6d7 but never used
2025-03-24 10:09:24 +01:00
Charles Kerr
7ed4f0ca27 perf: use absl::flat_hash_map instead of std::unordered_map (#46202)
* perf: make ElectronUsbDelegate::controller_map_ an absl::flat_hash_map

* perf: make ElectronSerialDelegate::controller_map_ an absl::flat_hash_map

* perf: make ElectronHidDelegate::controller_map_ an absl::flat_hash_map

* perf: make FrameTreeNodeIdMap an absl::flat_hash_map

* perf: make AutofillDriverFactory::driver_map_ an absl::flat_hash_map

* perf: make asar::Archive::external_files_ an absl::flat_hash_map

* perf: make VersionIdMap an absl::flat_hash_map

* perf: make ObjectCache::proxy_map_ an absl::flat_hash_map

* docs: add TODO to investigate absl map in KeyWeakMap
2025-03-24 10:09:14 +01:00
Shelley Vohr
964090d086 fix: ensure TraverseParent bails on resource path exit (#46100)
* fix: ensure TraverseParent bails on resource path exit

* Address review changes
2025-03-24 10:06:59 +01:00
Erik Moura
e9082ea57a docs: fix capitalization for InputEvent.modifiers (#46130) 2025-03-23 16:38:15 -05:00
Charles Kerr
5623c96dd7 refactor: remove unused field ServiceWorkerMain::weak_factory_ (#46171)
refactor: remove unused field ServiceWorkerMain::weak_factory_

Added in a467d06, appears to have never been used
2025-03-23 10:14:45 +01:00
Charles Kerr
3fd35abe98 refactor: remove unused method ElectronBrowserContext::GetWeakPtr() (#46170)
* refactor: use forward declaration of MediaDeviceIDSalt in electron_browser_context.h

* refactor: remove unused #include from browser_context.h

* refactor: remove unused ElectronBrowserContext::GetWeakPtr()

last use removed in Aug 2020 by bac2f46
2025-03-22 10:15:15 -05:00
Charles Kerr
a81e11d9de refactor: use = default to define trivial destructors (#46165)
refactor: use '= default' to define trivial destructors
2025-03-21 16:15:34 -05:00
John Kleinschmidt
db47267be4 build: Use windows src cache (#45881)
build: use source cache on windows
2025-03-21 14:45:08 -04:00
Charles Kerr
6723bfbe32 refactor: reduce coupling in electron::api::Protocol (#46122)
* refactor: decouple api::Protocol from ElectronBrowserContext

now they do not know about each other

* refactor: make electron::api::ProtocolError private

* refactor: remove unused isolate arg in Protocol constructor

* refactor: use =default for trivial destructor
2025-03-21 07:33:25 -05:00
Shelley Vohr
603057b198 fix: remove File.path from types (#46005) 2025-03-21 08:40:49 +01:00
Shelley Vohr
9ccc63d682 fix: add missing cpp_heap to Node.js worker CreateParams (#46104) 2025-03-21 08:40:28 +01:00
LZL
4d7161f36e feat: add ffmpeg.dll to delay load configuration (#46151)
feat: set ffmpeg.dll as a delay-loaded DLL

Updated the /DELAYLOAD linker config in BUILD.gn to set ffmpeg.dll
as a delay-loaded DLL. This reduces startup overhead and prevents unnecessary
loading when ffmpeg-related functionality is not used (e.g., the browser process
was unnecessarily loading it).
2025-03-21 16:24:34 +09:00
Shelley Vohr
32141eacfb refactor: use upstream Widget::IsVisibleOnAllWorkspaces() (#45887)
* refactor: use upstream Widget::IsVisibleOnAllWorkspaces()

* chore: add to breaking changes
2025-03-20 23:43:47 -05:00
Charles Kerr
1b5db9989e refactor: make URLPipeLoader private (#46113)
Move the URLPipeLoader class into an anonymous namespace in
electron_url_loader_factory.cc.
2025-03-20 15:47:47 -05:00
Charles Kerr
46967ca9c9 refactor: Add ElectronBrowserContext::BrowserContexts() (#46089)
* refactor: add ElectronBrowserContext::BrowserContexts()

* refactor: use ElectronBrowserContext::BrowserContexts() in ElectronBrowserMainParts::PostMainMessageLoopRun()

* refactor: use ElectronBrowserContext::BrowserContexts() in ElectronExtensionsBrowserClient::IsValidContext()

* refactor: use ElectronBrowserContext::BrowserContexts() in ElectronExtensionsBrowserClient::BroadcastEventToRenderers()

* refactor: move PartitionKey, BrowserContextMap private

* refactor: add ElectronBrowserContext::IsValidContext()

decouple ElectronExtensionsBrowserClient from the internals of ElectronBrowserContext
2025-03-20 11:17:26 -05:00
Charles Kerr
273baf4ec2 refactor: use base::NumberToString() (#46141)
base::NumberToString() is slightly more efficient than
absl::StrFormat("%u").
2025-03-20 10:13:28 +01:00
Charles Kerr
c4800d9934 refactor: remove ToV8(isolate, const char*) (#46108) 2025-03-20 10:04:50 +01:00
Shelley Vohr
86cc9f626f fix: APNS token ids are lowercase ASCII (#46101) 2025-03-20 07:57:50 +01:00
Shelley Vohr
09a3bcf0f0 fix: webContents.print() crash on Linux (#46087) 2025-03-20 06:41:00 +01:00
Shelley Vohr
bf64967b68 build: combine pipewire patches (#46129) 2025-03-19 23:26:06 -05:00
Niklas Wenzel
bf1d377e08 docs: use optional chaining for app.dock (#46119)
docs: use optional chaining for app.dock
2025-03-19 18:34:03 -05:00
Shelley Vohr
d424c3aee7 test: disable parallel/test-worker-resource-limits (#46105)
test: disable parallel/test-worker-resource-limits
2025-03-19 22:03:26 +01:00
Niklas Wenzel
e4d660af86 docs: fix code example in breaking-changes.md (#46093) 2025-03-19 11:20:22 +01:00
Shelley Vohr
2efd75e2ca build: fail for out of date patches on forks (#46080) 2025-03-19 10:05:51 +01:00
electron-roller[bot]
b13f05e2dc chore: bump chromium to 136.0.7067.0 (main) (#46018)
* chore: bump chromium in DEPS to 136.0.7066.0

* chore: bump chromium in DEPS to 136.0.7067.0

* 6325710: [LNA] Add Local Network Access permission type

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6325710

* 6342514: Create frame mojo endpoints in renderer during window.open()

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6342514

* 6344040: Create widget mojo endpoints in renderer process for window.open()

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6344040

* chore: update patches

* 6349218: Move ExtensionService::install_directory() to ExtensionRegistrar

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6349218

* 6349395: Move ExtensionService::extensions_enabled() to ExtensionRegistrar

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6349395

* 6331510: Migrate views::Background class to ui::ColorVariant | https://chromium-review.googlesource.com/c/chromium/src/+/6331510

* build: reorder set-cookie step https://github.com/electron/electron/pull/46091

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: David Sanders <dsanders11@ucsbalum.com>
Co-authored-by: alice <alice@makenotion.com>
2025-03-18 19:20:54 -04:00
Shelley Vohr
dcbab692c0 test: fix app.dock for corrected type (#46110)
test: fix app.dock for corrected type
2025-03-18 17:44:39 -04:00
Niklas Wenzel
71f3ff6bf2 docs: fix types of app.dock (#46073) 2025-03-18 13:14:08 +01:00
Alice Zhao
ff0a14a7c6 build: move set chromium cookie before build tools step (#46091)
build: move set cookie before build tools
2025-03-18 10:07:05 +01:00
Charles Kerr
4bf99c9bea refactor: add ElectronBrowserContext::GetDefaultBrowserContext() (#46065)
* refactor: add ElectronBrowserContext::DestroyAllContexts()

Simpler semantics than previous implementation; also hides the
"default context must be destroyed last" implementation detail.

* refactor: add ElectronBrowserContext::GetDefaultBrowserContext()

clearer semantics than everyone calling From("", false)
2025-03-17 08:43:23 -05:00
Charles Kerr
9513486bf3 refactor: use GetDefaultStoragePartition() instead of GetStoragePartition(nullptr) (#46064)
refactor: use GetDefaultStoragePartition()

Use GetDefaultStorageParition() instead of GetStoragePartition(nullptr)

- It improves code uniformity, since we use get-default everywhere else
- It's more readable
- It's marginally faster, since GetStoragePartition() has more steps

Added in 49b0a1bf4a
2025-03-17 08:39:55 -05:00
Charles Kerr
bea7d618f1 fix: warning in file picker UI (#46067) 2025-03-16 20:49:15 -05:00
Charles Kerr
4ad20ccb39 chore: e patches all (#46068) 2025-03-16 14:04:01 -05:00
Charles Kerr
73a017577e perf: avoid redundant map lookup in ElectronBrowserContext::From() (#46044)
perf: avoid redundant map lookup in ElectronBrowserContext::FromPath()
2025-03-15 09:51:20 -05:00
Shelley Vohr
2d8a547692 build: fix compound bash conditional in patchup (#46047) 2025-03-15 09:57:59 +01:00
Charles Kerr
5f0603ed28 fix: ElectronBrowserContext raw_ptr bug + remove dead code (#46030)
refactor: remove unused ElectronBrowserContext::extension_system()

Last use removed on Jul 21, 2020 by 2fb14f5 in PR #24575

This fixes a raw_ptr warning by letting us remove the raw_ptr field
`ElectronBrowserContext::extension_system_`.
2025-03-14 23:35:10 -05:00
Sam Maddock
afca4e271e feat: ServiceWorkerMain.scriptURL (#45863)
feat: serviceWorker.scriptURL
2025-03-14 21:00:13 -04:00
Charles Kerr
30d2fadb28 refactor: replace base::StringPrintf() calls with absl::StrFormat() (#46024)
The former is now a pass-through for the latter and is slated for removal

Xref: https://issues.chromium.org/issues/40241565

https://chromium-review.googlesource.com/c/chromium/src/+/4907781
2025-03-14 17:14:32 -05:00
Charles Kerr
3271b82094 refactor: remove unused system header includes (#46015)
* chore: remove unused #include <string>

* chore: remove unused #include <optional>

* chore: remove unused #include <vector>

* chore: remove unused #include <string_view>

* chore: remove unused #include <memory>

* chore: remove unused #include <utility>

* chore: remove unused #include <tuple>

* chore: remove unused #include <unordered_set>

* chore: remove unused #include <functional>

* chore: iwyu <set>

* chore: iwyu <map>
2025-03-14 10:59:15 -05:00
Shelley Vohr
c0e180758b fix: don't crash Utility Processes on unhandled rejections (#45921)
* fix: don't crash on unhandled rejections

* Update docs/breaking-changes.md

Co-authored-by: Niklas Wenzel <dev@nikwen.de>

---------

Co-authored-by: Niklas Wenzel <dev@nikwen.de>
2025-03-14 09:09:02 -05:00
Shelley Vohr
5817d27429 fix: take Snapped status into account when showing a window (#46006) 2025-03-14 09:07:27 -05:00
Michaela Laurencin
4812b4e6c2 fix: prevent title change for within page navigation (#45981)
* fix: prevent title change for on page navigation

* add back and forward testing

* update Chromium comment

* remove errant script tag
2025-03-14 12:10:23 +01:00
Shelley Vohr
7c0b7b417b fix: emit context-menu event in Windows draggable regions (#45851)
fix: emit context-menu event in Windows draggable regions
2025-03-14 10:29:29 +01:00
Charles Kerr
785fe5f3b6 refactor: make a variadic gin_helper::internal::InvokeFactory() (#45988)
refactor: make a variadic gin_helper::internal::InvokeFactory()
2025-03-13 17:24:49 -05:00
Shelley Vohr
502a6b0166 build: roll sysroots again (#46016) 2025-03-13 16:28:53 -05:00
Shelley Vohr
4a28e60e89 fix: package import existence verification (#45997) 2025-03-13 14:51:43 -05:00
Shelley Vohr
a90d50e13f fix: don't crash Web Workers on unhandled rejections (#45992) 2025-03-13 13:09:23 -05:00
electron-roller[bot]
962d8b325a chore: bump chromium to 136.0.7064.0 (main) (#45985)
* chore: bump chromium in DEPS to 136.0.7063.0

* chore: bump chromium in DEPS to 136.0.7064.0

* 6169919: Instantiate Linux (or CrOS) system fonts using Fontations

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6169919

* 6341209: Remove file-wide unsafe buffer suppression from content/ [1 of N].

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6341209

* chore: update patches

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: David Sanders <dsanders11@ucsbalum.com>
2025-03-13 12:02:06 -05:00
Charles Kerr
c813bc2a92 refactor: use private inheritance from mojo::MessageReceiver (#45973)
* refactor: make UtilityProcessWrapper inherit privately from mojo::MessageReceiver

* refactor: make ParentPort inherit privately from mojo::MessageReceiver

* refactor: make MessagePort inherit privately from mojo::MessageReceiver
2025-03-12 19:06:41 +01:00
Shelley Vohr
5ce41bac8d fix: system-context-menu should only fire in draggable regions (#45893)
fix: system-context-menu should only fire in draggable regions
2025-03-12 13:47:58 +01:00
David Sanders
6bc7bde229 ci: don't fail branch created workflow if previous board not found (#45986) 2025-03-12 09:27:40 +01:00
electron-roller[bot]
2de8fd7d93 chore: bump chromium to 136.0.7062.0 (main) (#45957)
* chore: bump chromium in DEPS to 136.0.7059.0

* chore: bump chromium in DEPS to 136.0.7060.0

* chore: bump chromium in DEPS to 136.0.7062.0

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
2025-03-11 17:44:08 -04:00
Shelley Vohr
dcd319cfbe build: roll sysroots to pick up glibc fix (#45974) 2025-03-11 17:31:48 -04:00
Shelley Vohr
cd56b96544 refactor: remove usage of V8's {Attach|Detach}CppHeap() (#45922)
* refactor: remove usage of V8's {Attach|Detach}CppHeap()

* chore: remove revert patch
2025-03-11 18:54:33 +01:00
Charles Kerr
22262c14f1 test: fix timing issue in utilityProcess test fixtures (#45964)
* fix: potential timing issue in utilityProcess test

* fix: potential timing issue in utilityProcess esm test
2025-03-11 17:41:42 +01:00
dependabot[bot]
6e056709be build(deps): bump github/codeql-action from 3.28.10 to 3.28.11 (#45970)
Bumps [github/codeql-action](https://github.com/github/codeql-action) from 3.28.10 to 3.28.11.
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](b56ba49b26...6bb031afdd)

---
updated-dependencies:
- dependency-name: github/codeql-action
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-03-11 10:44:00 -05:00
dependabot[bot]
2f63b20acf build(deps): bump dsanders11/project-actions from 1.5.2 to 1.7.0 (#45969)
Bumps [dsanders11/project-actions](https://github.com/dsanders11/project-actions) from 1.5.2 to 1.7.0.
- [Release notes](https://github.com/dsanders11/project-actions/releases)
- [Changelog](https://github.com/dsanders11/project-actions/blob/main/.releaserc.json)
- [Commits](7fc3c5441a...2134fe7cc7)

---
updated-dependencies:
- dependency-name: dsanders11/project-actions
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-03-11 10:43:46 -05:00
Felix Rieseberg
eb126eecb0 docs: Add 'Native Code and Electron' (#45882)
* docs: Add 'Native Code and Electron'

* docs: Add node-gyp requirements

* Update docs/tutorial/native-code-and-electron.md

Co-authored-by: Erick Zhao <erick@hotmail.ca>

* Cross-platform clean command

* Mention napi-rs

* Apply suggestions from code review

Co-authored-by: Erick Zhao <erick@hotmail.ca>

* Fix lint, fix more comments

* Apply suggestions from code review

Co-authored-by: Erick Zhao <erick@hotmail.ca>

---------

Co-authored-by: Erick Zhao <erick@hotmail.ca>
2025-03-10 13:45:33 -07:00
Shelley Vohr
4e1a915f1a build: remove patches merged upstream (#45963) 2025-03-10 20:00:28 +01:00
Charles Kerr
f2b09ff0bd fix: remove redundant MediaCaptureDevicesDispatcher::GetInstance() call (#45929)
fix: remove redundant MediaCaptureDevicesDispatcher::GetInstance() call

This appears to be a copy-paste error introduced in 465dee2c
2025-03-10 09:44:24 -05:00
electron-roller[bot]
b0c11371e0 chore: bump chromium to 136.0.7058.1 (main) (#45928)
* chore: bump chromium in DEPS to 136.0.7056.0

* chore: update mas_avoid_private_macos_api_usage.patch.patch

no manual changes; patch applied with fuzz

* chore: update fix_adapt_exclusive_access_for_electron_needs.patch

patch applied manually due to context shear

6319958: [FS] Replace GURL with url::Origin for Excluisve Access Bubble | https://chromium-review.googlesource.com/c/chromium/src/+/6319958

* chore: update feat_allow_usage_of_sccontentsharingpicker_on_supported_platforms.patch

no manual changes; patch applied with fuzz

6311876: Expose captured surface resolution for MacOS | https://chromium-review.googlesource.com/c/chromium/src/+/6311876

* chore: e patches all

* 6319958: [FS] Replace GURL with url::Origin for Excluisve Access Bubble | https://chromium-review.googlesource.com/c/chromium/src/+/6319958

* 6326673: views: Delete the single-parameter Widget::InitParams constructor. | https://chromium-review.googlesource.com/c/chromium/src/+/6326673

* https://chromium-review.googlesource.com/c/chromium/src/+/6331102

* 6331102: [A11yPerformance] Rename AXMode::kScreenReader to kExtendedProperties | https://chromium-review.googlesource.com/c/chromium/src/+/6331102

Sync with shell/browser/ui/webui/accessibility_ui.cc to
upstream chrome/browser/accessibility/accessibility_ui.cc
changes in 4af8657

* chore: bump Chromium 136.0.7058.1 (#45933)

chore: bump chromium in DEPS to 136.0.7058.1

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: Charles Kerr <charles@charleskerr.com>
2025-03-10 00:30:34 -05:00
Samuel Attard
9b2e7db469 chore: cherry-pick 9dacf5694dfd from chromium (#45936) 2025-03-09 16:26:06 -07:00
Samuel Attard
f04c06a0db chore: cherry-pick 521faebc8a7c from chromium (#45941) 2025-03-09 16:23:04 -07:00
Charles Kerr
8ac061ebe7 fix: race condition in utilityProcess tests (#45926) 2025-03-09 17:37:35 -05:00
Milan Burda
b30f31e1f6 refactor: eliminate duplicate code in spec/api-process-spec.ts (#45927) 2025-03-09 17:37:14 -05:00
Charles Kerr
288ef37b1d perf: prefer base::SplitStringPiece() over base::SplitString() (#45924)
* perf: use base::SplitStringPiece() in SetNodeOptions()

* perf: use base::SplitStringPiece() in StringToAccelerator()

* refactor: StringToAccelerator() now takes a std::string_view
2025-03-09 17:36:13 -05:00
electron-roller[bot]
20414f66ca chore!: bump chromium to 136.0.7054.0 (main) (#45923)
* chore: bump chromium in DEPS to 136.0.7054.0

* chore: update allow_in-process_windows_to_have_different_web_prefs.patch

Xref: https://chromium-review.googlesource.com/c/chromium/src/+/5906158

patch applied manually due to context shear

* chore: e patches all

* refactor!: Session.clearStorageData(syncable)

Xref: https://chromium-review.googlesource.com/c/chromium/src/+/6309405

Remove syncable type from opts.quota in Session.clearStorageData(opts)
because it that category has been removed upstream.

BREAKING CHANGE: Removed ses.clearDataStorage({ quota: 'syncable' })

* docs: deprecate Session.clearDataStorage({ quota })

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: Charles Kerr <charles@charleskerr.com>
2025-03-07 17:49:21 -06:00
electron-roller[bot]
458b14b8ed chore: bump chromium to 136.0.7053.1 (main) (#45906)
* chore: bump chromium in DEPS to 136.0.7052.0

* chore: update mas_avoid_private_macos_api_usage.patch.patch

https://chromium-review.googlesource.com/c/chromium/src/+/6318359

patch applied manually due to context shear

* chore: update preconnect_manager.patch

Xref: https://chromium-review.googlesource.com/c/chromium/src/+/6318420

patch applied manually due to context shear

* chore: e patches all

* chore: bump chromium to 136.0.7053.1

* chore: update fix_remove_profiles_from_spellcheck_service.patch

Xref: https://chromium-review.googlesource.com/c/chromium/src/+/6326575

patch applied manually due to context shear

* chore: e patches all

* chore: revert removal of v8 API used by Node.js

* devtools: Remove DevToolsUIBindings::SendJsonRequest() | https://chromium-review.googlesource.com/c/chromium/src/+/6326236

* 6244461: Merge //content/common/user_agent.cc into //components/embedder_support:user_agent | https://chromium-review.googlesource.com/c/chromium/src/+/6244461

* 6313744: Migrate views::Background factory methods to ColorVariant | https://chromium-review.googlesource.com/c/chromium/src/+/6313744

* 6314545: Remove multiple argument support from base::ToString() | https://chromium-review.googlesource.com/c/chromium/src/+/6314545

* 6317362: [Extensions] Inline MessagingDelegate::CreateReceiverForTab() | https://chromium-review.googlesource.com/c/chromium/src/+/6317362

* 6308998: Add SettingAccess structured metrics event for DevTools | https://chromium-review.googlesource.com/c/chromium/src/+/6308998

* 6295214: Remove redundant state field in per-extension preferences | https://chromium-review.googlesource.com/c/chromium/src/+/6295214

NB: this change is copied from the upstream change to extensions/shell/browser/shell_extension_loader.cc

* fix: ui/ linter error

This is showing up in an eslint build step in Electron:

> /__w/electron/electron/src/out/Default/gen/ui/webui/resources/cr_elements/preprocessed/cr_menu_selector/cr_menu_selector.ts
>   77:23  error  This assertion is unnecessary since the receiver accepts the original type of the expression  @typescript-eslint/no-unnecessary-type-assertion
>
> ✖ 1 problem (1 error, 0 warnings)
>   1 error and 0 warnings potentially fixable with the `--fix` option.

However, removing the assertion causes a typescript build failure:

> gen/ui/webui/resources/cr_elements/preprocessed/cr_menu_selector/cr_menu_selector.ts:77:23 - error TS2345: Argument of type 'HTMLElement | null' is not assignable to parameter of type 'HTMLElement'.
>   Type 'null' is not assignable to type 'HTMLElement'.
>
> 77         items.indexOf(this.querySelector<HTMLElement>(':focus'));
>                          ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

So I think the two different steps may be picking up typescript definitions.

This patch should be removed after the issue is tracked down
and fixed in a followup task.

* fix: -Wnonnull warning

Fixes this warning:

> 2025-03-07T01:05:01.8637705Z ../../third_party/electron_node/src/debug_utils.cc(257,12): error: null passed to a callee that requires a non-null argument [-Werror,-Wnonnull]
> 2025-03-07T01:05:01.8638267Z   257 |     return nullptr;
> 2025-03-07T01:05:01.8638481Z       |            ^~~~~~~
> 2025-03-07T01:05:01.8638700Z 1 error generated.

Not sure why this warning was never triggered before; `git blame`
indicates this code hasn't changed in ages:

> c40a8273ef2 (Michaël Zasso    2024-05-10 09:50:20 +0200 255) #endif  // DEBUG
> 8e2d33f1562 (Anna Henningsen  2018-06-07 16:54:29 +0200 256)     }
> 247b5130595 (Refael Ackermann 2018-10-22 15:07:00 -0400 257)     return nullptr;
> 247b5130595 (Refael Ackermann 2018-10-22 15:07:00 -0400 258)   }

Presumably this is failing in this Chromium roll due to a
clang version bump.

We should remove this patch after upstreaming it.

* docs: add upstream pr link for Node patch

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: Charles Kerr <charles@charleskerr.com>
2025-03-07 11:35:59 -06:00
Robo
530ccfe350 fix: resolve font list in default prefernce values (#45905)
* fix: resolve font list in default prefernce values

* chore: fix unsafe buffer usage

* docs: add code comment
2025-03-07 18:22:03 +09:00
Robo
041ada1586 build: match upstream with unsafe buffer paths (#45853)
* build: match upstream with unsafe buffer paths

* Don't assume STL iterators are pointers

Refs https://issues.chromium.org/issues/328308661

* chore: spanify process_singleton_win.cc
2025-03-06 16:04:18 -05:00
yangllu
d987bee007 fix: javascript heap OOM is not raised (#45895)
fix: javascript heap oom is not raised in node::OOMErrorHandler

node::OOMErrorHandler terminates the process directly without raising an
oom exception. To fix it, set an oom handler into node from electron.
2025-03-06 17:34:19 +01:00
Erick Zhao
431a791a99 chore: emphasize documentation style guide (#45639)
docs: emphasize documentation style guide
2025-03-06 17:17:06 +01:00
dependabot[bot]
9441cf4627 build(deps): bump dsanders11/project-actions from 1.5.1 to 1.5.2 (#45901)
Bumps [dsanders11/project-actions](https://github.com/dsanders11/project-actions) from 1.5.1 to 1.5.2.
- [Release notes](https://github.com/dsanders11/project-actions/releases)
- [Changelog](https://github.com/dsanders11/project-actions/blob/main/.releaserc.json)
- [Commits](9c80cd31f5...7fc3c5441a)

---
updated-dependencies:
- dependency-name: dsanders11/project-actions
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-03-06 16:38:31 +01:00
Charles Kerr
bb1c3dff21 chore: bump chromium to 135.0.7049.7 (main) (#45900)
chore: bump chromium in DEPS to 135.0.7049.7
2025-03-05 16:36:52 -05:00
electron-roller[bot]
49a27cba6b chore: bump chromium to 135.0.7049.5 (main) (#45898)
chore: bump chromium in DEPS to 135.0.7049.5

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
2025-03-05 09:47:38 -06:00
Shelley Vohr
99c943df23 fix: setContentProtection(true) after hide on Windows (#45868)
fix: content protection after hide on Windows

https://chromium-review.googlesource.com/c/chromium/src/+/5789117
2025-03-04 16:39:59 -05:00
Sam Maddock
8c11764800 feat: WebContents.focusedFrame (#45667)
feat: webContents.focusedFrame
2025-03-04 11:38:58 -05:00
electron-roller[bot]
54136042c6 chore: bump chromium to 135.0.7049.0 (main) (#45885)
* chore: bump chromium in DEPS to 135.0.7049.0

* 6312439: Revert "Preconnect to the Glic FRE when the button is hovered."

https://chromium-review.googlesource.com/c/chromium/src/+/6312439

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
2025-03-04 11:20:25 -05:00
dependabot[bot]
28ed8a821a build(deps): bump actions/download-artifact from 4.1.8 to 4.1.9 (#45883)
Bumps [actions/download-artifact](https://github.com/actions/download-artifact) from 4.1.8 to 4.1.9.
- [Release notes](https://github.com/actions/download-artifact/releases)
- [Commits](fa0a91b85d...cc20338598)

---
updated-dependencies:
- dependency-name: actions/download-artifact
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-03-04 12:44:46 +01:00
Niklas Wenzel
ec9b589402 ci: preserve blocked/* labels on collaborator comments (#45877)
ci: keep `blocked/*` labels on collaborator comments
2025-03-04 10:49:14 +01:00
marekharanczyk
2a7133b7a6 fix: correct electron gin embedder indices (#45389)
fix: correct gin embedder indices.

Move electron extra embedders to the end of the enum so they do not
interfere with chromium embedders indices.
Also use kEmbedderBlinkTag directly in its index calculation without
adding extra indices from other tags.
2025-03-03 17:03:54 -05:00
electron-roller[bot]
64158114aa chore: bump chromium to 135.0.7047.0 (main) (#45873)
chore: bump chromium in DEPS to 135.0.7047.0

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
2025-03-03 19:15:23 +01:00
electron-roller[bot]
e8631b2f3a chore: bump chromium to 135.0.7047.0 (main) (#45859)
* chore: bump chromium in DEPS to 135.0.7043.0

* chore: bump chromium in DEPS to 135.0.7045.0

* 6305947: Preconnect to the Glic FRE when the button is hovered.

https://chromium-review.googlesource.com/c/chromium/src/+/6305947

* 6207093: Remove line_bounds from ImeCompositionRangeChanged

https://chromium-review.googlesource.com/c/chromium/src/+/6207093

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
2025-03-03 14:26:52 +01:00
Sam Maddock
21ad7cdda5 test: service worker contextBridge leak (#45852)
* test: contextBridge prototype leak in service workers

* test: deep prototype checks
2025-03-01 09:56:03 +01:00
electron-roller[bot]
add374ef6a chore: bump chromium to 135.0.7041.2 (main) (#45850)
* chore: bump chromium in DEPS to 135.0.7041.2

* [Extensions] Remove ExtensionsBrowserClient::GetUserAgent()

https://chromium-review.googlesource.com/c/chromium/src/+/6306854

* chore: update patches

* [api] Remove deprecated FunctionCallbackInfo::Holder()

https://chromium-review.googlesource.com/c/v8/v8/+/6309166

* [test] Add createExternalizableTwoByteString to extension

https://chromium-review.googlesource.com/c/v8/v8/+/6304942

* fixup [test] Add createExternalizableTwoByteString to extension

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: John Kleinschmidt <jkleinsc@electronjs.org>
2025-02-28 17:29:23 -05:00
David Sanders
eac270bea7 build: bump NMV to 135 (#45789) 2025-02-28 09:53:02 -05:00
co63oc
36ec9d7236 docs: fix spelling errors in code comments (#45842)
chore: Fix typos
2025-02-28 12:24:00 +01:00
Michaela Laurencin
3041fd66cd docs: update timelines for E36 (#45785)
Update electron-timelines.md
2025-02-28 11:24:40 +01:00
Charles Kerr
b504f65ace docs: update breaking-changes.md for 35.0.0 (#45822)
* docs: update breaking-changes.md for 35.0.0

* fixup! docs: update breaking-changes.md for 35.0.0

docs: make lint happy
2025-02-27 22:01:26 -06:00
electron-roller[bot]
5cb87b7110 chore: bump chromium to 135.0.7040.0 (main) (#45846)
chore: bump chromium in DEPS to 135.0.7040.0

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
2025-02-27 21:59:50 -06:00
Charles Kerr
d19cac6772 docs: fix PrinterInfo info in breaking-changes.md (#45843)
> ### Removed:`isDefault` and `status` properties on `PrinterInfo`
> These properties have been removed from the PrinterInfo Object
> because they have been removed from upstream Chromium.

These properties won't be removed until Electron 36, but
breaking-changes.md lists them as being removed in 35.
This PR corrects the error.
2025-02-27 17:49:58 -06:00
Shelley Vohr
eac1a7ff68 fix: context-menu event emitted in draggable regions (#45813)
* fix: context-menu event emitted in draggable regions

* fix: only trigger on mouse release
2025-02-27 14:44:46 -05:00
electron-roller[bot]
00089a951b chore: bump chromium to 135.0.7039.0 (main) (#45836)
* chore: bump chromium in DEPS to 135.0.7039.0

* chore: update patches

* extensions: Refactor ExtensionService GrantPermissionsAndEnableExtension

https://chromium-review.googlesource.com/c/chromium/src/+/6302374

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: John Kleinschmidt <jkleinsc@electronjs.org>
2025-02-27 13:20:42 -05:00
reito
b8d0f18ff8 docs: add docs about shared texture mode osr (#45670)
* docs: add docs about shared texture mode osr

* docs: add docs about shared texture mode osr

* docs: fix dot

* 更新 web-contents.md

Co-authored-by: Sam Maddock <samuel.maddock@gmail.com>

---------

Co-authored-by: Sam Maddock <samuel.maddock@gmail.com>
2025-02-27 11:10:58 -05:00
co63oc
96c2022483 chore: Fix typos (#45825) 2025-02-27 14:31:21 +01:00
Dietrich Ayala
ff05d4a96c docs: dialog.md - typo fix s/wndow/window/ (#45831)
Update dialog.md - typo fix
2025-02-27 10:32:42 +01:00
Charles Kerr
989918a59c refactor: simplify Invoker::IsOK() (#45803)
* refactor: simplify Invoker::IsOK()

* refactor: might as well make it [[nodiscard]] as well
2025-02-26 18:50:57 -06:00
electron-roller[bot]
6c4b5d81dd chore: bump chromium to 135.0.7037.0 (main) (#45811)
* chore: bump chromium in DEPS to 135.0.7036.0

* chore: bump chromium in DEPS to 135.0.7037.0

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
2025-02-26 17:30:11 +01:00
Charles Kerr
7d045dcddb refactor: remove unused gin_helper::WrappableBase::GetWrapper(v8::Isolate*) (#45793)
refactor: remove unused EventEmitter::GetWrapper(v8::Isolate*)
2025-02-25 19:50:09 -06:00
Charles Kerr
199f6d64db perf: avoid redundant method calls in EventEmitter (#45786)
* refactor: move EventEmitter::EmitWithEvent() into EventEmitter::Emit()

* perf: remove redundant calls to isolate() in EventEmitter::Emit()

* perf: remove redundant calls to GetWrapper() in EventEmitter::EmitEvent()

* perf: remove redundant calls to isolate() in EventEmitter::EmitWithoutEvent()

* perf: remove redundant calls to GetWrapper() in EventEmitter::EmitWithoutEvent()

* refactor: remove unused method EventEmitter::isolate()

* refactor: remove unused method EventEmitter::GetWrapper(v8::Isolate*)

* refactor: remove unused method EventEmitter::GetWrapper()

refactor: make the EventEmitter::Base typedef private

* refactor: remove unused typedef EventEmitter::Base

See "Workarounds" section in
https://isocpp.org/wiki/faq/templates#nondependent-name-lookup-members

* refactor: remove redundant gin_helper:: namespace use
2025-02-25 19:20:33 -06:00
dependabot[bot]
b82e4585cf build(deps): bump github/codeql-action from 3.28.9 to 3.28.10 (#45792)
Bumps [github/codeql-action](https://github.com/github/codeql-action) from 3.28.9 to 3.28.10.
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](9e8d0789d4...b56ba49b26)

---
updated-dependencies:
- dependency-name: github/codeql-action
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-02-25 15:25:24 -05:00
electron-roller[bot]
9303a3fae9 chore: bump chromium to 135.0.7035.0 (main) (#45764)
* chore: bump chromium in DEPS to 135.0.7028.0

* chore: bump chromium in DEPS to 135.0.7029.0

* chore: bump chromium in DEPS to 135.0.7031.0

* chore: bump chromium in DEPS to 135.0.7033.0

* Split //component/embedder_support:browser_util into multiple targets

https://chromium-review.googlesource.com/c/chromium/src/+/6246155

* chore: update patches

* build: update filenames.libcxx.gni

* 6275531: Enable Float16Array

https://chromium-review.googlesource.com/c/chromium/src/+/6275531

* chore: bump chromium in DEPS to 135.0.7035.0

* chore: update patches

* Move Service Process Host files to a separate folder

https://chromium-review.googlesource.com/c/chromium/src/+/6089368

* Remove NOTREACHED()s after return statements

https://chromium-review.googlesource.com/c/chromium/src/+/6297811

* Move ServiceProcessTracker and UtilityProcessClient into separate files

https://chromium-review.googlesource.com/c/chromium/src/+/6088677

* chore: update filenames.libcxx.gni

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: John Kleinschmidt <jkleinsc@electronjs.org>
Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
2025-02-25 15:16:15 -05:00
Keeley Hammond
9b6ba1ced1 fix: re-enable MacWebContentsOcclusion feature flag (#45775) 2025-02-25 09:28:09 -08:00
dependabot[bot]
7870ade07a build(deps): bump ossf/scorecard-action from 2.4.0 to 2.4.1 (#45791)
Bumps [ossf/scorecard-action](https://github.com/ossf/scorecard-action) from 2.4.0 to 2.4.1.
- [Release notes](https://github.com/ossf/scorecard-action/releases)
- [Changelog](https://github.com/ossf/scorecard-action/blob/main/RELEASE.md)
- [Commits](62b2cac7ed...f49aabe0b5)

---
updated-dependencies:
- dependency-name: ossf/scorecard-action
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-02-25 08:13:06 +01:00
dependabot[bot]
9699422cd6 build(deps): bump actions/upload-artifact from 4.6.0 to 4.6.1 (#45790)
Bumps [actions/upload-artifact](https://github.com/actions/upload-artifact) from 4.6.0 to 4.6.1.
- [Release notes](https://github.com/actions/upload-artifact/releases)
- [Commits](65c4c4a1dd...4cec3d8aa0)

---
updated-dependencies:
- dependency-name: actions/upload-artifact
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-02-25 08:13:01 +01:00
Charles Kerr
3ee2ec8e4f build: re-enable unsafe buffer checks (#45770) 2025-02-24 20:06:30 -06:00
Charles Kerr
0de1e8e610 refactor: remove unused v8::Isolate* arg from GlobalShortcut constructor (#45773)
refactor: remove unused isolate arg from GlobalShortcut constructor

has not been used since f1a0d5e811 (#22755)
2025-02-24 19:38:20 -06:00
Shelley Vohr
01554f39a8 revert: drag and drop icons on Windows (#45779)
This reverts commit 698cce6707.
2025-02-24 11:35:29 -06:00
Charles Kerr
69eb076bca refactor: do not use AdaptCallbackForRepeating() in electron_api_url_loader.cc (#45771)
refactor: do not use AdaptCallbackForRepeating in electron_api_url_loader.cc
2025-02-24 11:09:01 -05:00
reito
f3259be73c feat: remove osr framerate limit when use shared texture (#45669)
feat: remove framerate limit, if use shared texture osr.
2025-02-24 10:21:46 -05:00
David Sanders
698cce6707 fix: drag and drop icons on Windows (#45767) 2025-02-24 09:54:08 +01:00
Nilay Arya
3eab549369 docs: added upstream doc links for node, chromium, and v8 in default_app (#45392) 2025-02-22 10:15:36 -06:00
Shelley Vohr
3e51ee516e fix: rework and improve legacyMainResolve patch (#45754)
fix: rework and improve legacyMainResolve patch
2025-02-22 10:06:04 -06:00
Sam Maddock
e3f61b465d refactor: move extension APIs to session.extensions (#45597)
refactor: move extensions to session.extensions
2025-02-21 17:36:51 -06:00
Erick Zhao
a63f6143ea docs: clarify navigationhistory offsets (#45616)
* docs: clarify navigationhistory offsets

* "relative offset"
2025-02-21 17:35:17 -06:00
Charles Kerr
2a383e9ddd refactor: use C++20's contains() method (#45742)
* chore: use std::map<>::contains() instead of count() or find()

* chore: use std::map<>::contains() instead of base::Contains()
2025-02-21 17:33:43 -06:00
electron-roller[bot]
612da3ec47 chore: bump chromium to 135.0.7027.0 (main) (#45677)
* chore: bump chromium in DEPS to 135.0.7021.0

* chore: bump chromium in DEPS to 135.0.7023.0

* chore: update patches

* chore: gen-libc++-filenames.js

* [Extensions] Add a BUILD.gn file for the chrome.system.display API.

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6227347

* chore: bump chromium in DEPS to 135.0.7025.0

* fixup! [Extensions] Add a BUILD.gn file for the chrome.system.display API.

* [DevTools] Add support for automatic workspace folders.

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6275926

* Add UseCounter for potential PNA 2.0 breakage

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6259197

* Remove references to NavigationEntry/Controller in Zoom code.

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6258070

* chore: update patches

* Allow DevTools to record UmaHistogramMediumTimes

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6183713

* chore: update patches

* [gpu] Remove unnecessary media_buildflags include

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6286526

* chore: bump chromium in DEPS to 135.0.7027.0

* chore: update patches

* Remove type alias

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6280957

* [Refactor] Make ExtensionRegistrar a browser keyed service.

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6285230

* Remove unused functions

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6278736

* chore: IWYU

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: deepak1556 <hop2deep@gmail.com>
2025-02-21 14:46:51 -08:00
Keeley Hammond
6248c2436a fix: re-enable synchronous spellcheck on Windows (#45712)
* fix: re-enable synchronous spellcheck on Windows

* revert: fix: empty suggestions with windows platform checker

---------

Co-authored-by: Samuel Maddock <smaddock@slack-corp.com>
2025-02-21 14:45:46 -08:00
Charles Kerr
8d58999135 refactor: use base's map utills in WebFrameMain (#45741)
refactor: use base::FindPtrOrNull() in WebFrameMain::FromFrameTreeNodeId()

refactor: use base::FindPtrOrNull() in WebFrameMain::FromFrameToken()
2025-02-21 15:28:00 -06:00
Shelley Vohr
324fc0f62a fix: crash on getUserMedia with invalid chromeMediaSourceId (#45733)
* fix: crash on getUserMedia with invalid chromeMediaSourceId

* test: add a test
2025-02-21 10:17:52 -06:00
Charles Kerr
f62668e2e3 refactor: use base::as_byte_span() in EncodeToken(). (#45723)
This matches the change in upstream's serial_chooser_context.cc.

https://chromium-review.googlesource.com/c/chromium/src/+/5247305
2025-02-20 20:20:16 -05:00
Charles Kerr
a15fa87558 refactor: use base::as_bytes() in WriteAsciiChunk() (#45724)
refactor: use base::as_bytes() in WriteAsciiChunk()

this avoids a reinterpret_cast and a static_cast
2025-02-20 20:19:48 -05:00
Charles Kerr
ceaa0e26c7 refactor: use base::as_string_view() (#45722)
Use `base::as_string_view()` as a safer alternative to `reinterpret_cast`
in a couple of places.

Xref: https://chromium-review.googlesource.com/c/chromium/src/+/5472408
2025-02-20 18:19:36 -06:00
Shelley Vohr
4867b5dc75 refactor: bluetooth in serial chooser when exclusively wireless serial ports are expected (#45671)
* refactor: bluetooth in serial chooser when exclusively wireless serial ports are expected

https://chromium-review.googlesource.com/c/chromium/src/+/5737296

* chore: review feedback
2025-02-20 16:44:35 -06:00
Shelley Vohr
340fdaf511 feat: allow setting roundedCorners on Windows (#45594)
* feat: allow setting roundedCorners on Windows

* Update docs/api/structures/base-window-options.md

Co-authored-by: Will Anderson <will@itsananderson.com>

---------

Co-authored-by: Will Anderson <will@itsananderson.com>
2025-02-20 15:39:12 -05:00
Sam Maddock
5ea885c87f build: skip chromium git cookie on forks (#45735) 2025-02-20 14:38:20 -05:00
Shelley Vohr
d8baceb08c fix: crash loading about:blank in subframes (#45694)
fix: crash loading about:blank in subframes
2025-02-20 12:07:15 -05:00
Charles Kerr
d6f4982522 fix: possible timing issue in utility-process spec (#45690)
This fixture has been calling process.exit() immediately after writing
to stdout and stderr, which the Node.js docs say is risky behavior:

> Calling process.exit() will force the process to exit as quickly as
> possible even if there are still asynchronous operations pending that
> have not yet completed fully, including I/O operations to
> process.stdout and process.stderr.

This fixture's been around for years without problems (AFAIK).
The writes are very small ('hello\n' and 'world') and finish quickly.
But recently I've been testing on a very slow CI machine. There, I see
this spec flaking when it expects stderr to be 'world' but it gets ''.

This PR changes the fixture to wait for stdout & stderr to flush
before calling process.exit().
2025-02-19 23:28:04 -06:00
Sam Maddock
9d558cec5e fix: action.openPopup function missing (#45697) 2025-02-19 18:05:02 -05:00
Shelley Vohr
159e1a42b3 refactor: track downloads by guid (#45675) 2025-02-19 16:49:34 -06:00
Sam Maddock
b50066f420 fix: extension web workers net request failing (#45698) 2025-02-19 13:08:28 -05:00
Milan Burda
22b7403cd1 chore: remove deprecated systemPreferences.isAeroGlassEnabled() (#45563) 2025-02-18 18:59:00 -06:00
Charles Kerr
670e0ca076 chore: disable 'should lock the keyboard' test on macOS (#45681) 2025-02-18 18:00:01 -06:00
Sam Maddock
ee67bc7dcb fix: dangling speculative frames (#45609)
* fix: dangling speculative frames

* harden lifecycle state checks

* feedback

* add const
2025-02-18 17:52:05 -05:00
John Kleinschmidt
ecd7eb36ac build: remove appveyor bake (#45073) 2025-02-18 12:04:47 -08:00
electron-roller[bot]
47572286f3 chore: bump chromium to 135.0.7015.0 (main) (#45500)
* https://chromium-review.googlesource.com/c/chromium/src/+/6230977

* chore: bump chromium to 135.0.7012.0

* chore: update accelerator.patch

Support parsing Ctrl+Alt shortcuts | https://chromium-review.googlesource.com/c/chromium/src/+/6238137

* 6234236: Reapply bindings: Pass CppHeap on Isolate creation | https://chromium-review.googlesource.com/c/chromium/src/+/6234236

* 6234614: [ios blink] Move to use external begin frame source | https://chromium-review.googlesource.com/c/chromium/src/+/6234614

* chore: update chromium/feat_add_streaming-protocol_registry_to_multibuffer_data_source.patch

no manual changes; patch applied with fuzz

* chore: update chromium/build_libc_as_static_library.patch

no manual changes; patch applied with fuzz

* chore: remove chromium/cherry-pick-dd8e2822e507.patch

landed upstream

* 6188884: Grit: Remove output_all_resource_defines from list of valid attributes. | https://chromium-review.googlesource.com/c/chromium/src/+/6188884

* 6226981: [views-ax] Remove View::GetAccessibleNodeData() method | https://chromium-review.googlesource.com/c/chromum/src/+/6226981

* 6214895: [views-ax] Deprecate View::NotifyAccessibilityEvent | https://chromium-review.googlesource.com/c/chromium/src/+/6214895

* 6196494: Remove ImageView::SetImage() with ImageSkia param | https://chromium-review.googlesource.com/c/chromium/src/+/6196494

* 6236267: [cleanup] Remove unused PrinterBasicInfo fields | https://chromium-review.googlesource.com/c/chromium/src/+/6236267

* refactor: remove status, isDefault properties from PrinterInfo

Xref: https://chromium-review.googlesource.com/c/chromium/src/+/6236267

* chore: lint

* fixup: added mas bypass to new file added in https://chromium-review.googlesource.com/c/chromium/src/+/6208630 see slack for more context

* chore: node script/gen-libc++-filenames.js

* chore: e patches all

* fix: duplicate crdtp symbols

* chore: update patches

* fixup! [Media Features] Remove launched features

---------

Co-authored-by: alice <alice@makenotion.com>
Co-authored-by: Charles Kerr <charles@charleskerr.com>
Co-authored-by: deepak1556 <hop2deep@gmail.com>
2025-02-18 11:51:27 -05:00
Sam Maddock
6be1151ffc fix: win.closeFilePreview recreates panel when called twice (#45319)
* fix: close quick look during tests on macOS

* use longer delay 🤷

* fix: sharedPreviewPanel being recreated on close

* test: ensure preview panel gets closed
2025-02-17 17:25:19 -05:00
Sam Maddock
c0422d7cc9 refactor: dispatch IPC messages from Session (#45452)
* refactor: dispatch IPC messages from Session

* refactor: move MessageHost to Session
2025-02-17 16:36:28 -05:00
reito
e9ba5876d1 fix: osr stutter fix backport for electron. (#45572) 2025-02-17 22:13:44 +01:00
Alice Zhao
02be7c1185 feat: add excludeUrls and modify urls in WebRequestFilter for better URL filtering (#44692)
* feat: add excludeUrls to web request filter

* refactor: add deprecated field

* test: update tests

* lint: newline

* docs: improve API doc

* fix: add is filter defined property to match all urls

* refactor: remove includeUrls

* refactor: remove typescript binding

* refactor: all_url

* refactor: remove isDefined methods

* refactor: remove comment

* fix: logic

* docs: add to breaking changes
2025-02-17 12:40:47 -08:00
Shelley Vohr
7dfcec931a build: run source cache clean daily (#45652) 2025-02-17 13:57:22 -05:00
John Kleinschmidt
a329024793 build: make sure chromium cookie is set everywhere (#45631) 2025-02-14 13:19:43 -05:00
Robo
137a552641 fix: support for v8.setHeapSnapshotNearHeapLimit api (#45606)
* fix: support for v8.setHeapSnapshotNearHeapLimit api

* docs: add  support
2025-02-14 10:00:39 -06:00
electron-roller[bot]
a841d6484c chore: bump node to v22.14.0 (main) (#45578)
* chore: bump node in DEPS to v22.14.0

* src: move more crypto impl detail to ncrypto dep

https://github.com/nodejs/node/pull/56421

* test: move crypto related common utilities in common/crypto

https://github.com/nodejs/node/pull/56714

* module: add findPackageJSON util

https://github.com/nodejs/node/pull/55412

* module: mark evaluation rejection in require(esm) as handled

https://github.com/nodejs/node/pull/56122

* chore: fixup patch indices

* deps: move inspector_protocol to deps

https://github.com/nodejs/node/pull/56649

* fixup! src: move more crypto impl detail to ncrypto dep

* fixup! deps: move inspector_protocol to deps

* fixup! src: move more crypto impl detail to ncrypto dep

* crypto: fix checkPrime crash with large buffers

https://github.com/nodejs/node/pull/56559

* tls: fix error stack conversion in cryptoErrorListToException()

https://github.com/nodejs/node/pull/56554

* module: add findPackageJSON util

https://github.com/nodejs/node/pull/55412

Our revert of native legacyMainResolve makes this very difficult to make
work, so disable for now.

* lib: add typescript support to STDIN eval

https://github.com/nodejs/node/pull/56359

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
2025-02-14 11:05:01 +01:00
Shelley Vohr
2af57c4b6a fix: osr crash on window close (#45573) 2025-02-14 11:01:00 +01:00
Shelley Vohr
47dbab3856 fix: pointer lock permission after focus loss and regain (#45574) 2025-02-14 10:22:13 +01:00
Charles Kerr
a1e4550c9e chore: disable flaky content tracing tests on Linux (#45612) 2025-02-14 10:18:42 +01:00
Charles Kerr
2b8706bf44 chore: change node test timeout from 20m to 30m (#45611) 2025-02-13 17:27:35 -06:00
Shelley Vohr
3a3595f2af build: remove PDF edited saved files patch (#45604) 2025-02-13 14:52:31 -05:00
Shay Molcho
9a2ee763d0 docs: added missing period for consistency and readability (#45333)
Added missing period for consistency and readability

Added a missing period in a specific part of the text to maintain consistency across the document. This ensures a uniform writing style, improves readability, and aligns with the formatting used throughout the content.
2025-02-13 10:55:43 +01:00
Keeley Hammond
237429bb85 build: set chromium cookie on depot tools requests (#45581)
* build: set chromium cookie on depot tools requests

* build: correct secrets syntax

* build: handle windows cmd
2025-02-12 17:44:43 +01:00
Will Anderson
50d1c803dd chore: remove var declarations from DEPS that no longer have any effect (#45535)
* chore: Remove checkout_google_benchmark var that no longer has any effect

This variable stopped having any effect in https://chromium-review.googlesource.com/c/chromium/src/+/4322306

It was removed from Chromium entirely in https://chromium-review.googlesource.com/c/chromium/src/+/4339138

* chore: remove checkout_oculus_sdk and checkout_libaom from DEPS
2025-02-12 10:51:11 +01:00
John Kleinschmidt
0d3e34d0be test: disable unexpectedly quit dialog on macOS (#45553)
* test: disable unexpectedly quit dialog on macOS

* test: take screenshot before keyboard lock test

* Revert "test: take screenshot before keyboard lock test"

This reverts commit 3ba5c6984f.
2025-02-11 21:08:38 -05:00
Charles Kerr
aa06b065c0 chore: bump chromium to 134.0.6998.10 (main) (#45564)
* chore: bump chromium to 134.0.6992.0

* chore: add BrowserProcessImpl::CreateGlobalFeaturesForTesting() stub

Xref: https://chromium-review.googlesource.com/c/chromium/src/+/6216193

Remove GlobalFeatures from TestingBrowserProcess::Init

* chore: bump chromium to 134.0.6994.0

* 6208630: Mac sandbox: don't use protobuf for policy serialization | https://chromium-review.googlesource.com/c/chromium/src/+/6208630

* [PDF] Remove HasUnsupportedFeature Mojo interface

Xref: https://chromium-review.googlesource.com/c/chromium/src/+/6220800

* 6217444: Remove scoped_gdi_object.h type aliases. | https://chromium-review.googlesource.com/c/chromium/src/+/6217444

* chore: bump chromium to 134.0.6998.10

* 6221378: Revert [OBC] Exclude Aliasing Cookies in FilterCookiesWithOptions() | https://chromium-review.googlesource.com/c/chromium/src/+/6221378

* Update ExtensionPrefs::GetDisableReasons to return DisableReasonSet

Xref: https://chromium-review.googlesource.com/c/chromium/src/+/6218840

change copied from 6218840 extensions/shell/browser/shell_extension_loader.cc

* 6218402: Typemap ui.gfx.DXGIHandle <=> gfx::DXGIHandle | https://chromium-review.googlesource.com/c/chromium/src/+/6218402

* chore: disable flaky contentTracing test

not new to this roll; it is happening in main as well

* fixup! chore: disable flaky contentTracing test

---------

Co-authored-by: alice <alice@makenotion.com>
2025-02-11 17:26:39 -06:00
Felix Rieseberg
9f47c9a051 feat: Restore webContents navigation history and page state (#45433)
* feat: Working navigationHistory.restore with just title/url

* feat: Restore page state, too

* chore: Docs, lint, tests

* Implement feedback

* More magic

* Make _awaitNextLoad truly private

* Implement API group feedback

* One more round of feedback
2025-02-11 15:09:38 -08:00
Will Anderson
6fdfca6e49 build: make gen-libc++-filenames.js produce the same results on Windows (#45556) 2025-02-11 12:56:05 +01:00
dependabot[bot]
196352bf0b build(deps): bump github/codeql-action from 3.28.8 to 3.28.9 (#45561)
Bumps [github/codeql-action](https://github.com/github/codeql-action) from 3.28.8 to 3.28.9.
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](dd746615b3...9e8d0789d4)

---
updated-dependencies:
- dependency-name: github/codeql-action
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-02-11 11:39:29 +01:00
Robo
46d316692d fix: asan build on macOS (#45541)
* fix: asan build on macOS

* chore: fix build
2025-02-11 15:04:07 +09:00
Josh Jancourtz
2f288bc7cc docs: fix grammar in preload tutorial summary (#45522) 2025-02-10 16:15:32 -05:00
Calvin
f5025b6246 fix: avoid IPC for renderer webFrame.getZoom... APIs (#45499)
* fix: avoid IPC for renderer `webFrame.getZoom...` APIs

* Remove `DoGetZoomLevel` IPC

* Fix synchronous behavior & nullptr deref

* Use local root
2025-02-10 16:09:11 -05:00
Milan Burda
e055ce7c39 chore: deprecate systemPreferences.isAeroGlassEnabled() (#45434) 2025-02-10 15:17:07 -05:00
John Kleinschmidt
14fe0932f0 test: make sure test window is on top for focus tests (#45435) 2025-02-10 13:40:27 -05:00
dependabot[bot]
3ba85878a5 build(deps): bump github/codeql-action from 3.28.6 to 3.28.8 (#45453)
Bumps [github/codeql-action](https://github.com/github/codeql-action) from 3.28.6 to 3.28.8.
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](17a820bf2e...dd746615b3)

---
updated-dependencies:
- dependency-name: github/codeql-action
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-02-10 19:40:01 +01:00
Keeley Hammond
70168c8bdc fix: fix mksnapshot gen/v8 path (#45488)
* fix: fix mksnapshot gen/v8 path

* build: use 7z compression

* build: unzip mksnapshot on Windows and update zip

* chore: escape backslashes

* chore: try another attempt

* chore: remove rmdir for now

---------

Co-authored-by: John Kleinschmidt <jkleinsc@electronjs.org>
Co-authored-by: David Sanders <dsanders11@ucsbalum.com>
2025-02-10 10:21:29 -05:00
Sam Maddock
e4cd162433 docs: fix powerMonitor event types (#45518)
* fix: powerMonitor event types

* fix: thermal-state-change missing Returns
2025-02-10 10:13:11 -05:00
Calvin
4085185e2d docs: transactions-updated event type (#45527)
fix: `transactions-updated` event type
2025-02-10 10:12:17 -05:00
Shelley Vohr
a141f68c83 refactor: use node::tracing::Agent() directly (#45489)
refactor: use node::tracing::Agent()
2025-02-09 21:36:42 +01:00
Shelley Vohr
9199d5c610 fix: window maximizing with Mica (#45456)
* fix: window maximizing with Mica

* Fix rounded corners after restore
2025-02-07 15:00:36 -05:00
michal-pichlinski-openfin
96460becf9 fix: Update widget visibility in NativeWindowMac::ShowInactive (#45427)
When using `views::WebView` on macOS `NativeWidgetMacNSWindowHost`
contains a layer and compositor responsible for drawing web contents.
To trigger drawing `NativeWidgetMacNSWindowHost::OnVisibilityChanged`
needs to be called and `[NSWindow orderFrontRegardless]` does not trigger
`[NSWindow orderWindow:relativeTo:]` which can change
`NativeWidgetMacNSWindowHost` visiblity with stack:
```
views::NativeWidgetMacNSWindowHost::OnVisibilityChanged(bool)
remote_cocoa::NativeWidgetNSWindowBridge::OnVisibilityChanged()
-[ViewsNSWindowDelegate onWindowOrderChanged:]
-[NativeWidgetMacNSWindow orderWindow:relativeTo:]
```
`views::Widget` has method for showing inactive window:
`views::Widget::ShowInactive` which triggers
`NativeWidgetMacNSWindowHost::OnVisibilityChanged` with stack:
```
views::NativeWidgetMacNSWindowHost::OnVisibilityChanged(bool)
remote_cocoa::NativeWidgetNSWindowBridge::SetVisibilityState(remote_cocoa::mojom::WindowVisibilityState)
views::NativeWidgetMacNSWindowHost::SetVisibilityState(remote_cocoa::mojom::WindowVisibilityState)
views::NativeWidgetMac::Show(ui::mojom::WindowShowState, gfx::Rect const&)
views::Widget::ShowInactive() + 168
```
However this call seems to be insufficient to bring window to front,
therefore `[NSWindow orderFrontRegardless]` still needs to be called.
Calling `views::Widget::ShowInactive` ensures that all logic related to
showing Chromium widget will be properly executed, but onfortunately it
does not call `[NSWindow orderWindow:relativeTo:]` which is used to
disabling headless mode by the `ElectronNSWindow`, therefore we need to
trigger it manually through exposed `[ElectronNSWindow disableHeadlessMode]`.

Fixes: #45415
2025-02-07 11:31:08 -08:00
Charles Kerr
d7c6fb8250 refactor: follow upstream's suggestions on when to use EmptyGURL() (#45498)
- Prefer GURL() when we want to return a non-reference empty URL.

- In ServiceWorkerMain::GetStorageKey(), use a reference instead
  of instantiating a new temporary GURL.

From url/gurl.h:

> // Returns a reference to a singleton empty GURL. This object is for
> // callers who return references but don't have anything to return in
> // some cases. If you just want an empty URL for normal use, prefer
> // GURL().
2025-02-07 13:58:31 -05:00
Charles Kerr
3db691804b chore: bump chromium 134.0.6990.0 (#45507)
* chore: update feat_add_support_for_missing_dialog_features_to_shell_dialogs.patch

Xref: https://chromium-review.googlesource.com/c/chromium/src/+/6219304

Partially upstreamed by @codebytere

* chore: e patches all
2025-02-07 10:25:46 -06:00
David Sanders
4512b2b5c4 chore: remove remaining references to AppVeyor (#45339) 2025-02-07 12:57:36 +01:00
John Kleinschmidt
7bde100a1a build: make sure there is at least 35GB free for source cache (#45501)
build: make sure there is at least 35GB free for cache
2025-02-07 12:03:38 +01:00
Kavindu Udara
d0110d897d docs: remove width and height params (#45331)
remove width and height params
2025-02-07 11:42:16 +01:00
Charles Kerr
ef34892a76 chore: bump chromium 134.0.6989.0 (#45506)
* chore: bump chromium to 134.0.6989.0

* chore: update patches/chromium/cherry-pick-dd8e2822e507.patch

* chore: e patches all
2025-02-07 10:00:09 +01:00
Charles Kerr
67f5ac5bbc fix: RenderFrameHost nullptr dereference (#45487)
* fix: add nullptr tests before using render_frame_

* refactor: extract-method HasRenderFrame()
2025-02-06 22:02:57 -06:00
Milan Burda
517935cd55 refactor: only pass v8::Context to gin_helper::MicrotasksScope constructor (#45484)
refactor: forward v8::Context to v8::MicrotasksScope constructor
2025-02-07 10:44:19 +09:00
Samuel Attard
326957009a chore: cherry-pick dd8e2822e507 from chromium (#45495) 2025-02-06 14:33:42 -08:00
electron-roller[bot]
213165a467 chore: bump chromium to 134.0.6988.0 (main) (#45334)
* chore: bump chromium in DEPS to 134.0.6976.0

* chore: update mas_avoid_private_macos_api_usage.patch.patch
https://chromium-review.googlesource.com/c/chromium/src/+/6171046
process_info_mac.cc -> process_info_mac.mm

* chore: update build_do_not_depend_on_packed_resource_integrity.patch
https://chromium-review.googlesource.com/c/chromium/src/+/6196857

* chore: update feat_add_support_for_missing_dialog_features_to_shell_dialogs.patch
https://chromium-review.googlesource.com/c/chromium/src/+/6182296
https://chromium-review.googlesource.com/c/chromium/src/+/6183404
https://chromium-review.googlesource.com/c/chromium/src/+/6187853

A lot changed in the upstream implementation. There's a good chance I got
this wrong as threading has changed and moved some variables into globals.

* chore: remove build_remove_vr_directx_helpers_dependency.patch
https://chromium-review.googlesource.com/c/chromium/src/+/6186102
This landed upstream

* chore: e patches all

* chore: update net::CookieInclusionStatus::ExclusionReason enum
https://chromium-review.googlesource.com/c/chromium/src/+/6183252
https://chromium-review.googlesource.com/c/chromium/src/+/6185544

* chore: update content::WebAuthenticationDelegate import
https://chromium-review.googlesource.com/c/chromium/src/+/6189769

* Revert "chore: disable focus handling test due to win32/ia32 regression"

This reverts commit 1a57ba5d59.

* chore: bump chromium in DEPS to 134.0.6978.0

* chore: bump chromium in DEPS to 134.0.6980.0

* chore: bump chromium in DEPS to 134.0.6982.0

* chore: bump chromium in DEPS to 134.0.6984.0

* 6196281: Allow direct embedder IsPdfInternalPluginAllowedOrigin() interaction
https://chromium-review.googlesource.com/c/chromium/src/+/6196281

* 6196283: Delete PdfInternalPluginDelegate
https://chromium-review.googlesource.com/c/chromium/src/+/6196283

* chore: update patches

* chore: bump chromium in DEPS to 134.0.6986.0

* chore: update patches

* 6205762: Support option to use window.showSaveFilePicker() in PDF attachment code
https://chromium-review.googlesource.com/c/chromium/src/+/6205762

See also:
* https://issues.chromium.org/issues/373852607
* 5939153: [PDF] Add PdfUseShowSaveFilePicker feature flag | https://chromium-review.googlesource.com/c/chromium/src/+/5939153
* 6205761: Delete spurious Ink-specific code in pdf_viewer.ts | https://chromium-review.googlesource.com/c/chromium/src/+/6205761

* 6209609: Remove WebVector: Automatic changes
https://chromium-review.googlesource.com/c/chromium/src/+/6209609

* 6205488: UI: make QT5 optional
https://chromium-review.googlesource.com/c/chromium/src/+/6205488

* 6178281: Rename pak files from branding strings
https://chromium-review.googlesource.com/c/chromium/src/+/6178281

* fixup! 6209609: Remove WebVector: Automatic changes https://chromium-review.googlesource.com/c/chromium/src/+/6209609

* 6193249: Switch from safe_browsing::EventResult to enterprise_connectors:EventResult
https://chromium-review.googlesource.com/c/chromium/src/+/6193249

* 6197457: Remove Pause/ResumeReadingBodyFromNet IPCs
https://chromium-review.googlesource.com/c/chromium/src/+/6197457

* 6191230: Record total time spent on a picture in picture window
https://chromium-review.googlesource.com/c/chromium/src/+/6191230

* chore: bump chromium in DEPS to 134.0.6988.0

* chore: update patches

* 6215440: Remove base/ranges/.
https://chromium-review.googlesource.com/c/chromium/src/+/6215440

* Disable unsafe buffers error

Not sure what changed, but we're now seeing unsafe buffer errors in Chromium code, at least when using reclient. Will update this comment if we find out the cause.

* 6187853: SelectFileDialogLinuxPortal: Use dbus_xdg::Request and DbusType
https://chromium-review.googlesource.com/c/chromium/src/+/6187853

* fix `setDisplayMediaRequestHandler` test

Given how this test is written, I would expect this assertion to be false. It seems the oppositue was true before, but that was also acknowledged to be suprising. Seems that the underlying implementation is now fixed and works as expected.

* fixup! 6187853: SelectFileDialogLinuxPortal: Use dbus_xdg::Request and DbusType https://chromium-review.googlesource.com/c/chromium/src/+/6187853

* chore: udpate patches

* Multiple PRS: https://chromium-review.googlesource.com/c/chromium/src/+/6185544 | https://chromium-review.googlesource.com/c/chromium/src/+/6183252

* fix: cast enum class to numeric type

* fix: add 1 to MAX_EXCLUSION_REASON because enum values are zero-based, and we want the total count of reasons.

* Reapply "chore: disable focus handling test due to win32/ia32 regression"

This reverts commit 760b1a519b.

* refactor: use ExclusionReasonBitset::kValueCount for size

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: Samuel Maddock <smaddock@slack-corp.com>
Co-authored-by: clavin <clavin@electronjs.org>
Co-authored-by: alice <alice@makenotion.com>
Co-authored-by: John Kleinschmidt <jkleinsc@electronjs.org>
2025-02-06 15:30:54 -05:00
David Sanders
3dad07f338 test: dump Electron process PID to path if environment variable set (#45481) 2025-02-06 09:15:10 -06:00
Anh Le
6adc737a89 docs: use correct headings in tutorial/security.md (#45397) 2025-02-06 11:16:24 +01:00
max54nj
c0282eb9c8 docs: style fixes (#45458)
* docs: fix code field

* docs: add missing space
2025-02-05 15:10:07 -05:00
Maria Alejandra Arias Frontanilla
471b1a873d fix: fix typo in docs why-electron.md (#45437) 2025-02-05 09:26:47 -06:00
Shelley Vohr
aee8ea8b10 fix: WCO not working with some window configurations (#45422) 2025-02-05 12:48:51 +01:00
Shelley Vohr
57cf4fc846 fix: legacyMainResolve respecting permission model (#45421)
fix: legacyMainResolve respecting permission model
2025-02-05 12:48:34 +01:00
Charles Kerr
9fe12cd01b fix: handle exclude aliasing in InclusionStatusToString() (#45454)
* refactor: use MakeFixedFlatMap() in InclusionStatusToString()

* fix: add log message for EXCLUDE_ALIASING

refactor: add static_assert() to ensure our messages stay
in sync with the CookieInclusion reasons in net/cookies/
2025-02-05 12:48:11 +01:00
Shelley Vohr
6486ce8191 build: remove debugger agent timeout patch (#45457) 2025-02-05 12:47:54 +01:00
Robo
bec6ddda70 feat: route deprecated sync clipboard read through permission checks (#45377)
* feat: route deprecated clipboard commands through permission checks

* docs: address review feedback

* fix: enable checks for child windows
2025-02-05 15:13:29 +09:00
Shelley Vohr
e9d5eeb118 build: try removing embedder exception patch (#45429) 2025-02-04 19:39:20 +01:00
Keeley Hammond
c147e4fa81 build: add win toolchain for release builds (#45380)
* build: add win toolchain for release builds

* build: fix installed_software.json script

* chore: run pwsh script within src

* build: fixup uploader arch
2025-02-03 22:06:01 -08:00
Niklas Wenzel
1d27a27813 docs: document deletion of databases directory (#45412) 2025-02-03 16:28:44 -05:00
Niklas Wenzel
d3bead5e0e docs: mention C++20 requirement in breaking changes document (#45413)
* docs: mention C++20 requirement in breaking changes document

* chore: fix linter issue
2025-02-03 13:19:26 -08:00
David Sanders
9f1bb531ba build: always use python3 in script/lib/get-version.js (#45400)
build: always use python3 in script/lib/get-version.js
2025-02-03 16:13:36 -05:00
Shelley Vohr
9971087678 build: remove outdated Node.js serdes patch (#45401)
build: remove outdates Node.js serdes patch
2025-02-03 14:09:02 +01:00
Shelley Vohr
e7fa5c709c fix: incorrect WCO tooltip in RTL (#45405) 2025-02-03 10:50:50 +01:00
Shelley Vohr
7a1d410e0a fix: default path not working on KDE Linux (#45402) 2025-02-03 09:49:48 +01:00
Sam Maddock
e2a7981dd3 feat: view.getVisible() (#44999)
* feat: view.getVisible()

* test: visible apis

* docs: clarify getVisible
2025-01-31 13:27:16 -05:00
Sam Maddock
26da3c5d6e feat: service worker preload scripts for improved extensions support (#44411)
* feat: preload scripts for service workers

* feat: service worker IPC

* test: service worker preload scripts and ipc
2025-01-31 09:32:45 -05:00
Shelley Vohr
bc22ee7897 build: fix slack-github-action for backports (#45388)
build: fix slack-github-action for backports
2025-01-31 10:29:50 +01:00
Shelley Vohr
784201ecee build: try removing Read/WriteBarrier patch (#45393)
build: try removing Read/WriteBarrier patch
2025-01-31 10:29:34 +01:00
Shelley Vohr
6e72cbb5e0 fix: multiple directory selection on Linux (#45373) 2025-01-30 16:34:44 +01:00
Shelley Vohr
233b99a0a8 chore: update chrome.scripting.execute logic (#45369)
chore: update chrome.scripting.execute logic

Refs:
- https://chromium-review.googlesource.com/c/chromium/src/+/6123601
- https://chromium-review.googlesource.com/c/chromium/src/+/6142377
- https://chromium-review.googlesource.com/c/chromium/src/+/6173554
2025-01-30 12:56:44 +01:00
Shelley Vohr
43e328f363 chore: update pdf_viewer_private.idl (#45370)
chore: update pdf_viewer_private.idl

- https://chromium-review.googlesource.com/c/chromium/src/+/6160067
2025-01-30 11:03:27 +01:00
John Kleinschmidt
8543820d98 build: fixup concurrent builds on protected branches (#45355) 2025-01-29 16:47:25 -05:00
electron-roller[bot]
93f4a93e12 chore: bump node to v22.13.1 (main) (#45307)
* chore: bump node in DEPS to v22.13.1

* chore: fixup GN build file

* https://github.com/nodejs/node/pull/55529
* https://github.com/nodejs/node/pull/55798
* https://github.com/nodejs/node/pull/55530

* module: simplify --inspect-brk handling

https://github.com/nodejs/node/pull/55679

* src: fix outdated js2c.cc references

https://github.com/nodejs/node/pull/56133

* crypto: include openssl/rand.h explicitly

https://github.com/nodejs/node/pull/55425

* build: use variable for crypto dep path

https://github.com/nodejs/node/pull/55928

* crypto: fix RSA_PKCS1_PADDING error message

https://github.com/nodejs/node/pull/55629

* build: use variable for simdutf path

https://github.com/nodejs/node/pull/56196

* test,crypto: make crypto tests work with BoringSSL

https://github.com/nodejs/node/pull/55491

* fix: suppress clang -Wdeprecated-declarations in libuv

https://github.com/libuv/libuv/pull/4486

* deps: update libuv to 1.49.1

https://github.com/nodejs/node/pull/55114

* test: make test-node-output-v8-warning more flexible

https://github.com/nodejs/node/pull/55401

* [v22.x] Revert "v8: enable maglev on supported architectures"

https://github.com/nodejs/node/pull/54384

* fix: potential WIN32_LEAN_AND_MEAN redefinition

https://github.com/c-ares/c-ares/pull/869

* deps: update nghttp2 to 1.64.0

https://github.com/nodejs/node/pull/55559

* src: provide workaround for container-overflow

https://github.com/nodejs/node/pull/55591

* build: use variable for simdutf path

https://github.com/nodejs/node/pull/56196

* chore: fixup patch indices

* fixup! module: simplify --inspect-brk handling

* lib: fix fs.readdir recursive async

https://github.com/nodejs/node/pull/56041

* lib: avoid excluding symlinks in recursive fs.readdir with filetypes

https://github.com/nodejs/node/pull/55714/

This doesn't currently play well with ASAR - this should be fixed in a follow up

* test: disable CJS permission test for config.main

This has diverged as a result of our revert of
src,lb: reducing C++ calls of esm legacy main resolve

* fixup! lib: fix fs.readdir recursive async

* deps: update libuv to 1.49.1

https://github.com/nodejs/node/pull/55114

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
2025-01-29 15:41:00 -05:00
Robo
ecd5d0a3a4 fix: crash in gin::wrappable::secondweakcallback (#45368) 2025-01-29 10:20:37 -08:00
Niklas Wenzel
8cf2e46c1f docs: reference security guide in ipcRenderer.on docs (#45325) 2025-01-29 12:50:20 +01:00
dependabot[bot]
50387043d1 build(deps): bump github/codeql-action from 3.28.1 to 3.28.6 (#45351)
Bumps [github/codeql-action](https://github.com/github/codeql-action) from 3.28.1 to 3.28.6.
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](b6a472f63d...17a820bf2e)

---
updated-dependencies:
- dependency-name: github/codeql-action
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-01-29 07:01:15 +01:00
Keeley Hammond
e715607178 build: use Python311 exe (#45360)
build: yse Python311 exe
2025-01-28 11:59:04 -08:00
Milan Burda
0e388bce3e build: add NSPrefersDisplaySafeAreaCompatibilityMode = false to Info.plist (#45318)
build: add NSPrefersDisplaySafeAreaCompatibilityMode = false to Info.plist
2025-01-28 14:58:48 +01:00
dependabot[bot]
9457a56607 build(deps): bump actions/setup-node from 4.1.0 to 4.2.0 (#45353)
Bumps [actions/setup-node](https://github.com/actions/setup-node) from 4.1.0 to 4.2.0.
- [Release notes](https://github.com/actions/setup-node/releases)
- [Commits](39370e3970...1d0ff469b7)

---
updated-dependencies:
- dependency-name: actions/setup-node
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-01-28 14:57:39 +01:00
dependabot[bot]
f9553a35d5 build(deps): bump actions/stale from 9.0.0 to 9.1.0 (#45354)
Bumps [actions/stale](https://github.com/actions/stale) from 9.0.0 to 9.1.0.
- [Release notes](https://github.com/actions/stale/releases)
- [Changelog](https://github.com/actions/stale/blob/main/CHANGELOG.md)
- [Commits](28ca103628...5bef64f19d)

---
updated-dependencies:
- dependency-name: actions/stale
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-01-28 14:56:34 +01:00
dependabot[bot]
e2ef160beb build(deps): bump actions/checkout from 4.1.6 to 4.2.2 (#45352)
Bumps [actions/checkout](https://github.com/actions/checkout) from 4.1.6 to 4.2.2.
- [Release notes](https://github.com/actions/checkout/releases)
- [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md)
- [Commits](https://github.com/actions/checkout/compare/v4.1.6...11bd71901bbe5b1630ceea73d27597364c9af683)

---
updated-dependencies:
- dependency-name: actions/checkout
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-01-28 10:48:35 +01:00
David Lönnhager
ae56a03e33 fix: crash parsing CLSID in shell.readShortcutLink() (#45195)
* fix: crash parsing CLSID in shell.readShortcutLink

* fix: ignore clsid if it could not be set
2025-01-27 15:22:56 -05:00
Keeley Hammond
4629e449a9 build: remove generate-sas-token (#45347) 2025-01-27 12:21:53 -08:00
Keeley Hammond
74c6669a8e build: use windows builders for win-publish (#45340) 2025-01-24 14:43:38 -08:00
Niklas Wenzel
5c67cd9150 docs: fix broken code in drag and drop example (#45332) 2025-01-24 13:28:30 -08:00
Niklas Wenzel
f66a0c2acf build: create maintainer issue template and disable blank issues (#45309)
* build: create maintainer task issue template and disable blank issues

* Implement review feedback by @dsanders11

* Rename issue template file
2025-01-24 13:28:05 -08:00
Sam Maddock
a467d0684e feat: ServiceWorkerMain (#45232)
* feat: ServiceWorkerMain

* refactor: disconnect remote

* handle version_info_ nullptr case

* initiate finish request when possible and enumerate errors

* explicit name for test method

* oops

* fix: wait for redundant version to stop before destroying

* docs: clarify when undefined is returned

* chore: remove extra semicolons
2025-01-24 08:33:44 -05:00
electron-roller[bot]
75eac86506 chore: bump chromium to 134.0.6968.0 (main) (#45172)
* chore: bump chromium in DEPS to 134.0.6948.0

* chore: update can_create_window.patch

https://chromium-review.googlesource.com/c/chromium/src/+/6151982

no patch code changes, but had to manually apply due to upstream context shear

* chore: update proxy_config_monitor.patch

no manual changes; patch applied with fuzz 2

Xref: https://chromium-review.googlesource.com/c/chromium/src/+/6126219

* chore: update build_add_electron_tracing_category.patch

Xref: https://chromium-review.googlesource.com/c/chromium/src/+/6149256

* chore: update adjust_accessibility_ui_for_electron.patch

https://chromium-review.googlesource.com/c/chromium/src/+/6105650

no patch code changes, but had to manually apply due to upstream context shear

* chore: e patches all

* chore: use fully-qualified path for all.gn

Xref: https://chromium-review.googlesource.com/c/chromium/src/+/6154997

* chore: do not use a variable when assigning rtc_use_h264

Xref: https://chromium-review.googlesource.com/c/chromium/src/+/6154997

* Move GlobalShortcutListenerLinux to //ui/base

Xref: https://chromium-review.googlesource.com/c/chromium/src/+/6097375

* [MPArch Guest View] Make WebPreferences queried per frame tree root

Xref: https://chromium-review.googlesource.com/c/chromium/src/+/6096390

* [Status Icons] Allow vector resources

https://chromium-review.googlesource.com/c/chromium/src/+/6139403

* [Extensions] Move MatchOriginAsFallbackBehavior to Mojom

Xref: https://chromium-review.googlesource.com/c/chromium/src/+/6141793

* Remove StrongAlias::Hasher

Xref: https://chromium-review.googlesource.com/c/chromium/src/+/6132291

* Rename text-change and select-change methods and related stuff

Xref: https://chromium-review.googlesource.com/c/chromium/src/+/6148816

* [Code Health] Remove stale feature EnableWebUsbOnExtensionServiceWorker

https://chromium-review.googlesource.com/c/chromium/src/+/6115161

* [Extensions Cleanup] Move creation of tab-based ports to factory method

https://chromium-review.googlesource.com/c/chromium/src/+/6143725

* refactor: add StatusIconGtk::SetIcon()

Xref: https://chromium-review.googlesource.com/c/chromium/src/+/6139403

copied from chrome/browser/status_icons/status_icon.cc

* refactor: add TrayIconLinux::GetIcon()

Xref: https://chromium-review.googlesource.com/c/chromium/src/+/6139403

* chore: update feat_allow_usage_of_sccontentsharingpicker_on_supported_platforms.patch

remove unused filter_ field

* chore: bump chromium in DEPS to 134.0.6950.0

* chore: bump chromium in DEPS to 134.0.6952.0

* chore: bump chromium in DEPS to 134.0.6954.0

* chore: bump chromium in DEPS to 134.0.6956.0

* chore: update Chromium patches

* 6165749: Check scanout support in RenderableGpuMemoryBufferPool | https://chromium-review.googlesource.com/c/chromium/src/+/6165749

* 6106730: [Win] Use DXGI swapchains and DCOMP visuals in software mode | https://chromium-review.googlesource.com/c/chromium/src/+/6106730

* chore: update patches

* chore: bump chromium in DEPS to 134.0.6958.0

* chore: bump chromium in DEPS to 134.0.6960.0

* chore: update chromium patches

* 6168371: Remove extensions GlobalShortcutListener wrapper | https://chromium-review.googlesource.com/c/chromium/src/+/6168371

* chore: update patches

* 6161637: WebUI: Leverage build_webui() in chrome://translate-internals | https://chromium-review.googlesource.com/c/chromium/src/+/6161637

* chore: bump chromium in DEPS to 134.0.6962.0

* 6177329: Remove policy.used_policy_certificates pref on ChromeOS | https://chromium-review.googlesource.com/c/chromium/src/+/6177329

* 6180524: Simplify logic in components/os_crypt/sync/BUILD.gn | https://chromium-review.googlesource.com/c/chromium/src/+/6180524

* 6144831: Enforce --disallow-v8-feature-flag-overrides in the renderer | https://chromium-review.googlesource.com/c/chromium/src/+/6144831

* chore: update patches

* chore: bump chromium in DEPS to 134.0.6964.0

* 6181010: Ensure busy cursor does not show via LaunchWithoutSandbox | https://chromium-review.googlesource.com/c/chromium/src/+/6181010

* chore: update patches

* chore: bump chromium in DEPS to 134.0.6966.0

* 6180598: [api] Remove Reallocate | https://chromium-review.googlesource.com/c/v8/v8/+/6180598

* 6170781: [Refactor] Move UninstallExtension to ExtensionRegistrar. | https://chromium-review.googlesource.com/c/chromium/src/+/6170781

* chore: update filenames.libcxx.gni

* 6168207: cdm: Remove widevine_cdm_version.h | https://chromium-review.googlesource.com/c/chromium/src/+/6168207

* chore: bump chromium in DEPS to 134.0.6968.0

* 6030552: [macOS] Allow using vibrancy with NativeWidgetNSWindowBridge | https://chromium-review.googlesource.com/c/chromium/src/+/6030552

* fix: use explicit copy to replace realloc impl

https://chromium-review.googlesource.com/c/v8/v8/+/6180598
https://issues.chromium.org/issues/331326406

As per recommendation, "File an issue with Node to explicitly copy,because they copy under the hood anyway"

* fixup! 6106730: [Win] Use DXGI swapchains and DCOMP visuals in software mode | https://chromium-review.googlesource.com/c/chromium/src/+/6106730

* fix: undefine win32 StrCat
https://chromium-review.googlesource.com/c/chromium/src/+/6172292

* fix: //device/vr:directx_helpers breaking the build
https://chromium-review.googlesource.com/c/chromium/src/+/6064548

Upstreamed in https://chromium-review.googlesource.com/c/chromium/src/+/6186102

* fix: avoid calling ui::Layer::SetFillsBoundsOpaquely
https://chromium-review.googlesource.com/c/chromium/src/+/6175787

The layer opacity is determined by the background color's alpha value

* fix: build with proprietary_codecs

The explicit setting of rtc_use_h264 is no longer needed since
https://webrtc-review.googlesource.com/c/src/+/62380

* fix: increase empty trace file size threshold

https://chromium-review.googlesource.com/c/chromium/src/+/6176642
Traces now contain a net-constants property to allow them to be converted to a net log.
These contain ~1240 new properties with formatted JSON data.

* fix: node tests missing resource management globals
https://chromium-review.googlesource.com/c/chromium/src/+/6174695

* fixup! fix: use explicit copy to replace realloc impl

* chore: disable focus handling test due to win32/ia32 regression

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: Charles Kerr <charles@charleskerr.com>
Co-authored-by: Keeley Hammond <khammond@slack-corp.com>
Co-authored-by: VerteDinde <vertedinde@electronjs.org>
Co-authored-by: Samuel Maddock <smaddock@slack-corp.com>
Co-authored-by: Samuel Maddock <samuelmaddock@electronjs.org>
2025-01-23 23:07:43 -05:00
Sam Maddock
996477152d feat: contextBridge.executeInMainWorld (#45229) 2025-01-23 21:12:46 -05:00
Sam Maddock
e09577b123 feat: redesign preload APIs (#45230)
* feat: redesign preload APIs

* docs: remove service-worker mentions for now

* fix lint

* remove service-worker ipc code

* add filename

* fix: web preferences preload not included

* fix: missing common init

* fix: preload bundle script error
2025-01-23 21:12:23 -05:00
Felix Rieseberg
26d228ccfe docs: Add note about directly exposing Electron APIs in preload (#45241)
* docs: Add note about directly exposing Electron APIs in preload

* Implement feedback
2025-01-23 13:59:00 -08:00
Keeley Hammond
aafb1ba72c build: migrate Windows release builds to GHA (#45137)
* build: migrate release builds to GHA

* build: alter CI jobs release script
2025-01-23 14:10:24 -05:00
Charles Kerr
db7ef90159 chore: better logging if Node initialization fails (#45286)
feat: better logging if Node initialization fails
2025-01-23 08:55:28 -06:00
electron-roller[bot]
863faea542 chore: bump node to v22.11.0 (main) (#44530)
* chore: bump node in DEPS to v22.11.0

* src: move evp stuff to ncrypto

https://github.com/nodejs/node/pull/54911

* crypto: add Date fields for validTo and validFrom

https://github.com/nodejs/node/pull/54159

* module: fix discrepancy between .ts and .js

https://github.com/nodejs/node/pull/54461

* esm: do not interpret "main" as a URL

https://github.com/nodejs/node/pull/55003

* src: modernize likely/unlikely hints

https://github.com/nodejs/node/pull/55155

* chore: update patch indices

* crypto: add validFromDate and validToDate fields to X509Certificate

https://github.com/nodejs/node/pull/54159

* chore: fixup perfetto patch

* fix: clang warning in simdjson

* src: add receiver to fast api callback methods

https://github.com/nodejs/node/pull/54408

* chore: fixup revert patch

* fixup! esm: do not interpret "main" as a URL

* fixup! crypto: add Date fields for validTo and validFrom

* fix: move ArrayBuffer test patch

* src: fixup Error.stackTraceLimit during snapshot building

https://github.com/nodejs/node/pull/55121

* fix: bad rebase

* chore: fixup amaro

* chore: address feedback from review

* src: revert filesystem::path changes

https://github.com/nodejs/node/pull/55015

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
2025-01-22 12:16:26 -05:00
Shelley Vohr
5aabb6bec5 fix: potential crash in chrome.tabs.update() (#45276)
fix: potential crash in chrome.tabs.update()
2025-01-22 10:02:29 -06:00
dependabot[bot]
5e05dff949 build(deps): bump actions/upload-artifact from 4.5.0 to 4.6.0 (#45274)
Bumps [actions/upload-artifact](https://github.com/actions/upload-artifact) from 4.5.0 to 4.6.0.
- [Release notes](https://github.com/actions/upload-artifact/releases)
- [Commits](6f51ac03b9...65c4c4a1dd)

---
updated-dependencies:
- dependency-name: actions/upload-artifact
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-01-22 12:29:23 +01:00
Maksim Sisov
3ea623364b feat: support global shortcuts via GlobalShortcutsPortal feature with ozone/wayland (#45171)
* fix: backport patch to fix systemd unit activation in Chromium

This backports a patch from Chromium, which fixes systemd unit
activation. That is, a globalShortcuts feature that Chromium has
needs to create a systemd unit and rename it properly. Portal's
global shortcuts uses that name afterwards to map the app with
the shortcuts bound. However, there might be a race between
Chromium binding shortcuts and renaming the unit.

This is a first step to add Portal's globalShortcuts to
Electron.

* feat: Support global shortcuts via GlobalShortcutsPortal feature

Chromium has a new feature called GlobalShortcutsPortal. It
allows clients to use Portal's globalShortcuts to register and
listen to shortcuts.

This patches adds necessary bits, which allows Electron to
use that feature.

In order to make it work, one has to add
--enable-features=GlobalShortcutsPortal

Test: tested manually with a sample app.

* docs: add GlobalShortcutsPortal feature to globalShortcuts docs

Electron supports Portal's globalShortcuts API now via Chromium, and Electron
apps can use that in a Wayland session. Update the docs with the required
feature flag that must be passed to be able to use that implementation.
2025-01-22 11:59:48 +01:00
Erick Zhao
cf67dc8898 docs: add DocCardList component for index doc (#45275) 2025-01-22 10:27:30 +01:00
David Sanders
d7b568a1c0 ci: fix issue workflow failures (#45294) 2025-01-22 09:40:10 +01:00
Charles Kerr
fe9031eb23 refactor: in StopTracing(), use string literals instead of optional<string> (#45270)
refactor: simplify StopTracing() a little by using a string_view instead of an optional<string>

We have compile-time string literals that we're passing to a method
that takes a string_view argument, so we don't need all this extra
optional<string> scaffolding
2025-01-21 17:41:52 -06:00
Charles Kerr
f5eba67f0d refactor: simplify ParseUserScript() (#45269)
refactor: simplify ParseUserScript()

local variable user_script no longer needed after #43205
2025-01-21 15:21:56 -05:00
Charles Kerr
e1762e6e44 fix: consume the file permission callback when used (#45267)
fixes 0e5fe3f regression
2025-01-21 11:59:38 -06:00
Shelley Vohr
9d32b6ddfc fix: webContents.print() with OOP printing (#45266)
* fix: webContents.print() with OOP printing

* Update patches/chromium/printing.patch

Co-authored-by: Robo <hop2deep@gmail.com>

---------

Co-authored-by: Robo <hop2deep@gmail.com>
2025-01-21 11:39:21 -05:00
David Sanders
7a413ff2ad ci: don't fail issue triage workflows if issue not found on project (#45252) 2025-01-21 16:06:24 +01:00
Shelley Vohr
0090d171fd chore: align clipboard blink::web_pref::WebPreferences with upstream (#45277)
chore: align clipboard blink::web_pref::WebPreferences with upstream
2025-01-21 06:50:36 -08:00
dependabot[bot]
980b68e9cc build(deps): bump github/codeql-action from 3.28.0 to 3.28.1 (#45272)
Bumps [github/codeql-action](https://github.com/github/codeql-action) from 3.28.0 to 3.28.1.
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](48ab28a6f5...b6a472f63d)

---
updated-dependencies:
- dependency-name: github/codeql-action
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-01-21 15:12:42 +01:00
dependabot[bot]
44a630e634 build(deps): bump mikefarah/yq from 4.44.6 to 4.45.1 (#45271)
Bumps [mikefarah/yq](https://github.com/mikefarah/yq) from 4.44.6 to 4.45.1.
- [Release notes](https://github.com/mikefarah/yq/releases)
- [Changelog](https://github.com/mikefarah/yq/blob/master/release_notes.txt)
- [Commits](4839dbbf80...8bf425b4d1)

---
updated-dependencies:
- dependency-name: mikefarah/yq
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-01-21 15:12:29 +01:00
Shelley Vohr
81d12fa452 build: fix clang-format duplicate message (#45235) 2025-01-20 11:05:40 +01:00
Shelley Vohr
83666ddc36 fix: page scaling in silent mode printing (#45218) 2025-01-20 11:05:15 +01:00
Shelley Vohr
fa5de40f86 fix: two possible FSA crashes (#45233)
* 5786874: Change Observer: Fix crash when navigating to new page

https://chromium-review.googlesource.com/c/chromium/src/+/5786874

* 5794141: Change Observer: Fix Get*PermissionGrant crash

https://chromium-review.googlesource.com/c/chromium/src/+/5794141
2025-01-20 10:23:57 +01:00
Shelley Vohr
7d05fb2a1b fix: broken OOP window.print() on macOS/Linux (#45214)
fix: broken OOP printing on macOS/Linux
2025-01-20 10:23:44 +01:00
Sam Maddock
51a249f380 chore: skip flaky contentTracing test (#45240) 2025-01-20 09:57:10 +01:00
Sam Maddock
90754e5fd2 test: quit Finder (#45239) 2025-01-20 09:54:26 +01:00
Shelley Vohr
0e5fe3fa60 fix: getAsFileSystemHandle failure when drag-dropping two directories (#45234)
fix: drag-dropping two directories
2025-01-20 09:54:12 +01:00
michal-pichlinski-openfin
6953f5505f refactor: remove InspectableWebContentsViewMac in favor of the Views version (#44628)
* refactor: remove InspectableWebContentsViewMac in favor of the Views version

* cherry-pick: refactor: remove InspectableWebContentsViewMac in favor of the Views version (#41326)

commit e67ab9a93d

Confilcts not resolved, except removal of the files removed
by the original commit.

* resolved conflicts and build issues after cherry-pick

* cherry-picked: fix: add method allowing to disable headless mode in native widget

https://github.com/electron/electron/pull/42996
fixing
https://github.com/electron/electron/issues/42995

* fix: displaying select popup in window created as fullscreen window

`constrainFrameRect:toScreen:` is not being call for windows created
with `fullscreen: true` therefore `headless` mode was not being removed
and `RenderWidgetHostNSViewBridge::DisplayPopupMenu` ignored displaying
popup.

Issue could be fixed by placing additional removal of `headless` mode
in the `toggleFullScreen:`, but `orderWindow:relativeTo:` is called
both for a regular and a fullscreen window, therefore there will be
a single place fixing both cases.

Because `electron::NativeWindowMac` lifetime may be shorter than
`ElectronNSWindow` on which macOS may execute `orderWindow:relativeTo:`
we need to clear `shell_` when `NativeWindow` is being closed.

Fixes #43010.

* fix: Content visibility when using `vibrancy`

We need to put `NSVisualEffectView` before `ViewsCompositorSuperview`
otherwise when using `vibrancy` in `BrowserWindow` `NSVisualEffectView`
will hide content displayed by the compositor.

Fixes #43003
Fixes #42336

In fact main issues reported in these tickets were not present after
cherry-picking original refactor switching to `views::WebView`, so
text could be selected and click event was properly generated. However
both issues testcases were using `vibrancy` and actual content was
invisible, because it was covered by the `NSVisualEffectView`.

* fix: EXCEPTION_ACCESS_VIOLATION crash on BrowserWindow.destroy()

Restored postponed deletion of the `NativeWindow`.

Restoration caused `DCHECK(new_parent_ui_layer->GetCompositor());` failure
in `BrowserCompositorMac::SetParentUiLayer` after the spec test:
`chrome extensions chrome.webRequest does not take precedence over Electron webRequest - http`
with stack:
```
7   Electron Framework 0x000000011fe07830 content::BrowserCompositorMac::SetParentUiLayer(ui::Layer*) + 628
8   Electron Framework 0x000000011fe0c154 content::RenderWidgetHostViewMac::SetParentUiLayer(ui::Layer*) + 220
9   Electron Framework 0x000000011fe226a8 content::WebContentsViewMac::CreateViewForWidget(content::RenderWidgetHost*) + 600
10  Electron Framework 0x000000011fd37e4c content::WebContentsImpl::CreateRenderWidgetHostViewForRenderManager(content::RenderViewHost*) + 164
11  Electron Framework 0x000000011fb32278 content::RenderFrameHostManager::CreateSpeculativeRenderFrame(content::SiteInstanceImpl*, bool, scoped_refptr<content::BrowsingContextState> const&) + 816
12  Electron Framework 0x000000011fb2ab8c content::RenderFrameHostManager::CreateSpeculativeRenderFrameHost(content::SiteInstanceImpl*, content::SiteInstanceImpl*, bool) + 1308
13  Electron Framework 0x000000011fb28598 content::RenderFrameHostManager::GetFrameHostForNavigation(content::NavigationRequest*, content::BrowsingContextGroupSwap*, std::__Cr::basic_string<char, std::__Cr::char_traits<char>, std::__Cr::allocator<char>>*) + 1796
14  Electron Framework 0x000000011fa78660 content::NavigationRequest::SelectFrameHostForOnRequestFailedInternal(bool, bool, std::__Cr::optional<std::__Cr::basic_string<char, std::__Cr::char_traits<char>, std::__Cr::allocator<char>>> const&) + 280
15  Electron Framework 0x000000011fa6a994 content::NavigationRequest::OnRequestFailedInternal(network::URLLoaderCompletionStatus const&, bool, std::__Cr::optional<std::__Cr::basic_string<char, std::__Cr::char_traits<char>, std::__Cr::allocator<char>>> const&, bo
+ 1008
16  Electron Framework 0x000000011fa7772c content::NavigationRequest::OnRequestFailed(network::URLLoaderCompletionStatus const&) + 72
17  Electron Framework 0x000000011f8554ac content::NavigationURLLoaderImpl::NotifyRequestFailed(network::URLLoaderCompletionStatus const&) + 248
```
This was probably the reason of removing `NativeWindow` immediately
in order to cleanup `views_host_` in `WebContentsViewMac` to prevent
using layer without compositor in `WebContentsViewMac::CreateViewForWidget`.

`[ElectronNSWindowDelegate windowWillClose:]` is deleting window host
and the compositor used by the `NativeWindow` therefore detach `NativeWindow`
contents from parent. This will clear `views_host_` and prevent failing
mentioned `DCHECK`.

Fixes #42975

* chore: Applied review suggestions

* refactor: directly cleanup shell

---------

Co-authored-by: Samuel Maddock <smaddock@slack-corp.com>
2025-01-17 10:21:10 -05:00
Felix Rieseberg
45f90cd5dd docs: Why Electron? (#45191)
* docs: Why Electron?

* Apply suggestions from code review

Co-authored-by: Sam Maddock <samuel.maddock@gmail.com>
Co-authored-by: Erick Zhao <erick@hotmail.ca>

* Update docs/why-electron.md

---------

Co-authored-by: Sam Maddock <samuel.maddock@gmail.com>
Co-authored-by: Erick Zhao <erick@hotmail.ca>
2025-01-15 18:32:56 -05:00
Anny Yang
8294f44c74 docs: remove quickstart (#45194) 2025-01-15 14:42:53 -08:00
Calvin
6f7999ad0d fix: session.clearData avoidClosingConnections default to false (#45187) 2025-01-15 11:38:50 -05:00
Keeley Hammond
d829ee3145 build: bump NMV to 133 (#45145) 2025-01-15 11:36:34 -05:00
Keeley Hammond
88b4e1a9b7 build: bump actions/cache past deprecated version (#45192) 2025-01-15 11:33:46 +01:00
dependabot[bot]
7c784a1758 build(deps): bump actions/setup-node from 4.0.4 to 4.1.0 (#45049)
Bumps [actions/setup-node](https://github.com/actions/setup-node) from 4.0.4 to 4.1.0.
- [Release notes](https://github.com/actions/setup-node/releases)
- [Commits](https://github.com/actions/setup-node/compare/v4.0.4...39370e3970a6d050c480ffad4ff0ed4d3fdee5af)

---
updated-dependencies:
- dependency-name: actions/setup-node
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-01-15 11:06:10 +01:00
wujinli
5680c628b6 fix: only remove the 'v' prefix from the git tag name (#45132)
In the old version of get-version.js, it replaces the leading 'v',
i.e. |output.stdout.toString().trim().replace(/^v/g, '')|. However,
in the new version of get-git-version.py, it directly replaces all
'v'. Obviously, it does not conform to the original semantics.
Although it will not affect the existing electron version calculation,
it may affect other developers' customized git-tag-version, such as
v0.0.0-dev.xxx, which will lose the 'v' of dev.
2025-01-13 22:36:03 -05:00
Calvin
e57b69f106 docs: correct breaking changes versions (#45173) 2025-01-13 14:15:24 -08:00
Michaela Laurencin
19ee4464c2 docs: update timelines for E35 (#45167) 2025-01-10 16:21:08 -08:00
electron-roller[bot]
7d05b78479 chore: bump chromium to 133.0.6920.0 (main) (#45055)
* chore: bump chromium in DEPS to 133.0.6902.0

* chore: bump chromium in DEPS to 133.0.6903.0

* chore: update patches

* Update PdfViewer Save File Picker to use showSaveFilePicker.

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6074308

* Code Health: Clean up stale MacWebContentsOcclusion

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6078344

* Change RenderProcessHost::GetID to RenderProcessHost::GetDeprecatedID

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6065543

* [WebRTC] Make WebRTC IP Handling policy a mojo enum

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6063620

* chore: gen filenames.libcxx.gni

* Remove allow_unsafe_buffers pragma in //printing

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6092280

* refactor: to use ChildProcessId where possible

Refs https://issues.chromium.org/issues/379869738

* [Win] Update TabletMode detection code

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6003486

* chore: bump chromium in DEPS to 133.0.6905.0

* chore: update patches

* Reland "Move global shortcut listener to //ui/base"

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6099035

* [shared storage] Implement the batch `with_lock` option for response header

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6072742

* chore: bump chromium in DEPS to 133.0.6907.0

* chore: bump chromium in DEPS to 133.0.6909.0

* chore: bump chromium in DEPS to 133.0.6911.0

* chore: bump chromium in DEPS to 133.0.6912.0

* chore: update patches

* WebUI: Reveal hidden deps to ui/webui/resources.

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6096291

* chore: bump chromium in DEPS to 133.0.6913.0

* chore: bump chromium in DEPS to 133.0.6915.0

* Code Health: Clean up stale base::Feature "AccessibilityTreeForViews"

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6104174

Co-authored-by: David Sanders <dsanders11@ucsbalum.com>

* fix: remove fastapitypedarray usage

* chore: update patches

* chore: script/gen-libc++-filenames.js

* Code Health: Clean up stale base::Feature "WinRetrieveSuggestionsOnlyOnDemand"

Refs https://chromium-review.googlesource.com/c/chromium/src/+/6109477

* fix: empty suggestions with windows platform checker

Amends the fix from https://github.com/electron/electron/pull/29690
since the feature flag is no longer available. We follow the
same pattern as //chrome/browser/renderer_context_menu/spelling_menu_observer.cc
to generate the suggestion list on demand when context menu action
is invoked.

Co-authored-by: David Sanders <dsanders11@ucsbalum.com>

* fixup! fix: empty suggestions with windows platform checker

* fixup! fix: empty suggestions with windows platform checker

* revert: 6078344: Code Health: Clean up stale MacWebContentsOcclusion | https://chromium-review.googlesource.com/c/chromium/src/+/6078344

* Revert "revert: 6078344: Code Health: Clean up stale MacWebContentsOcclusion | https://chromium-review.googlesource.com/c/chromium/src/+/6078344"

This reverts commit 9cacda452e.

* chore: bump to 133.0.6920.0, update patches

* Revert "6078344: Code Health: Clean up stale MacWebContentsOcclusion"

Refs: https://chromium-review.googlesource.com/c/chromium/src/+/6078344

* fixup! Update PdfViewer Save File Picker to use showSaveFilePicker.

---------

Co-authored-by: electron-roller[bot] <84116207+electron-roller[bot]@users.noreply.github.com>
Co-authored-by: deepak1556 <hop2deep@gmail.com>
Co-authored-by: David Sanders <dsanders11@ucsbalum.com>
Co-authored-by: Keeley Hammond <khammond@slack-corp.com>
2025-01-10 10:52:34 -06:00
Charles Kerr
062d14e553 perf: cache whether or not ELECTRON_DEBUG_NOTIFICATIONS env var is set (#45143)
* perf: cache whether or not ELECTRON_DEBUG_NOTIFICATIONS env var is set

* chore: remove unused #include
2025-01-08 20:46:17 -06:00
Charles Kerr
59ed1db9a2 refactor: remove redundant CreateExtensionsClient() (#45135) 2025-01-08 10:36:08 -06:00
dependabot[bot]
da8288106b build(deps): bump github/codeql-action from 3.27.9 to 3.28.0 (#45090)
Bumps [github/codeql-action](https://github.com/github/codeql-action) from 3.27.9 to 3.28.0.
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](df409f7d92...48ab28a6f5)

---
updated-dependencies:
- dependency-name: github/codeql-action
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-01-06 15:11:28 -05:00
dependabot[bot]
679eb3c266 build(deps): bump actions/upload-artifact from 4.4.3 to 4.5.0 (#45089)
Bumps [actions/upload-artifact](https://github.com/actions/upload-artifact) from 4.4.3 to 4.5.0.
- [Release notes](https://github.com/actions/upload-artifact/releases)
- [Commits](b4b15b8c7c...6f51ac03b9)

---
updated-dependencies:
- dependency-name: actions/upload-artifact
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-01-06 15:11:06 -05:00
David Sanders
c2d0a28fa2 ci: enable debugging mode when building electron_dist_zip (#45108) 2025-01-06 14:41:48 -05:00
John Kleinschmidt
2745771a22 test: reenable disabled GHA windows tests (#45062)
* test: renable GHA on Windows disabled tests

* test: close edge after shell.openExternal

* test: close edge sync after shell.openExternal
2024-12-20 14:49:55 -05:00
dependabot[bot]
1ecb2a2998 build(deps): bump actions/checkout from 4.1.6 to 4.2.2 (#45048)
Bumps [actions/checkout](https://github.com/actions/checkout) from 4.1.6 to 4.2.2.
- [Release notes](https://github.com/actions/checkout/releases)
- [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md)
- [Commits](https://github.com/actions/checkout/compare/v4.1.6...11bd71901bbe5b1630ceea73d27597364c9af683)

---
updated-dependencies:
- dependency-name: actions/checkout
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-12-19 17:22:01 -05:00
1451 changed files with 79375 additions and 39810 deletions

1
.claude/.gitignore vendored Normal file
View File

@@ -0,0 +1 @@
settings.local.json

24
.claude/settings.json Normal file
View File

@@ -0,0 +1,24 @@
{
"permissions": {
"allow": [
"Bash(e sync)",
"Bash(e patches --list-targets:*)",
"Bash(git add:*)",
"Bash(git am:*)",
"Bash(git commit:*)",
"Bash(git log:*)",
"Bash(git show:*)",
"Bash(e patches:*)",
"Bash(e sync:*)",
"Skill(electron-chromium-upgrade)",
"Read(*)",
"Bash(echo:*)",
"Bash(e build:*)",
"Bash(tee:*)",
"Bash(git diff:*)",
"Bash(git rev-parse:*)"
],
"deny": [],
"ask": []
}
}

View File

@@ -0,0 +1,199 @@
---
name: electron-chromium-upgrade
description: Guide for performing Chromium version upgrades in the Electron project. Use when working on the roller/chromium/main branch to fix patch conflicts during `e sync --3`. Covers the patch application workflow, conflict resolution, analyzing upstream Chromium changes, and proper commit formatting for patch fixes.
---
# Electron Chromium Upgrade: Phase One
## Summary
Run `e sync --3` repeatedly, fixing patch conflicts as they arise, until it succeeds. Then run `e patches all` and commit changes atomically.
## Success Criteria
Phase One is complete when:
- `e sync --3` exits with code 0 (no patch failures)
- `e patches all` has been run to export all changes
- All changes are committed per the commit guidelines below
Do not stop until these criteria are met.
**CRITICAL** Do not delete or skip patches unless 100% certain the patch is no longer needed. Complicated conflicts or hard to resolve issues should be presented to the user after you have exhausted all other options. Do not delete the patch just because you can't solve it.
## Context
The `roller/chromium/main` branch is created by automation to update Electron's Chromium dependency SHA. No work has been done to handle breaking changes between the old and new versions.
**Key directories:**
- Current directory: Electron repo (always run `e` commands here)
- `..` (parent): Chromium repo (where most patches apply)
- `patches/`: Patch files organized by target
- `docs/development/patches.md`: Patch system documentation
## Workflow
1. Delete the `.git/rr-cache` in both the `electron` and `..` folder to ensure no accidental rerere replays occur from before this upgrade phase attempt started
2. Run `e sync --3` (the `--3` flag enables 3-way merge, always required)
3. If succeeds → skip to step 6
4. If patch fails:
- Identify target repo and patch from error output
- Analyze failure (see references/patch-analysis.md)
- Fix conflict in target repo's working directory
- Run `git am --continue` in affected repo
- Repeat until all patches for that repo apply
- IMPORTANT: Once `git am --continue` succeeds you MUST run `e patches {target}` to export fixes
- Return to step 1
5. When `e sync --3` succeeds, run `e patches all`
6. **Read `references/phase-one-commit-guidelines.md` NOW**, then commit changes following those instructions exactly.
Before committing any Phase One changes, you MUST read `references/phase-one-commit-guidelines.md` and follow its instructions exactly.
## Commands Reference
| Command | Purpose |
|---------|---------|
| `e sync --3` | Clone deps and apply patches with 3-way merge |
| `git am --continue` | Continue after resolving conflict (run in target repo) |
| `e patches {target}` | Export commits from target repo to patch files |
| `e patches all` | Export all patches from all targets |
| `e patches --list-targets` | List targets and config paths |
## Patch System Mental Model
```
patches/{target}/*.patch → [e sync --3] → target repo commits
← [e patches] ←
```
## When to Edit Patches
| Situation | Action |
|-----------|--------|
| During active `git am` conflict | Fix in target repo, then `git am --continue` |
| Modifying patch outside conflict | Edit `.patch` file directly |
| Creating new patch (rare, avoid) | Commit in target repo, then `e patches {target}` |
Fix existing patches 99% of the time rather than creating new ones.
## Patch Fixing Rules
1. **Preserve authorship**: Keep original author in TODO comments (from patch `From:` field)
2. **Never change TODO assignees**: `TODO(name)` must retain original name
3. **Update descriptions**: If upstream changed (e.g., `DCHECK``CHECK_IS_TEST`), update patch commit message to reflect current state
## Final Deliverable
After Phase One, write a summary of every change: what was fixed, why, reasoning, and Chromium CL links.
# Electron Chromium Upgrade: Phase Two
## Summary
Run `e build -k 999` repeatedly, fixing build issues as they arise, until it succeeds. Then run `e start --version` to validate Electron launches and commit changes atomically.
Run Phase Two immediately after Phase One is complete.
## Success Criteria
Phase Two is complete when:
- `e build -k 999` exits with code 0 (no build failures)
- `e start --version` has been run to check Electron launches
- All changes are committed per the commit guidelines below
Do not stop until these criteria are met. Do not delete code or features, never comment out code in order to take short cut. Make all existing code, logic and intention work.
## Context
The `roller/chromium/main` branch is created by automation to update Electron's Chromium dependency SHA. No work has been done to handle breaking changes between the old and new versions. Chromium APIs frequently are renamed or refactored. In every case the code in Electron must be updated to account for the change in Chromium, strongly avoid making changes to the code in chromium to fix Electrons build.
**Key directories:**
- Current directory: Electron repo (always run `e` commands here)
- `..` (parent): Chromium repo (do not touch this code to fix build issues, just read it to obtain context)
## Workflow
1. Run `e build -k 999` (the `-k 999` flag is a flag to ninja to say "do not stop until you find that many errors" it is an attempt to get as much error
context as possible for each time we run build)
2. If succeeds → skip to step 6
3. If build fails:
- Identify underlying file in "electron" from the compilation error message
- Analyze failure
- Fix build issue by adapting Electron's code for the change in Chromium
- Run `e build -t {target_that_failed}.o` to build just the failed target we were specifically fixing
- You can identify the target_that_failed from the failure line in the build log. E.g. `FAILED: 2e506007-8d5d-4f38-bdd1-b5cd77999a77 "./obj/electron/chromium_src/chrome/process_singleton_posix.o" CXX obj/electron/chromium_src/chrome/process_singleton_posix.o` the target name is `obj/electron/chromium_src/chrome/process_singleton_posix.o`
- **Read `references/phase-two-commit-guidelines.md` NOW**, then commit changes following those instructions exactly.
- Return to step 1
4. **CRITICAL**: After ANY commit (especially patch commits), immediately run `git status` in the electron repo
- Look for other modified `.patch` files that only have index/hunk header changes
- These are dependent patches affected by your fix
- Commit them immediately with: `git commit -am "chore: update patch hunk headers"`
- This prevents losing track of necessary updates
5. Return to step 1
6. When `e build` succeeds, run `e start --version`
7. Check if you have any pending changes in the Chromium repo by running `git status`
- If you have changes follow the instructions below in "A. Patch Fixes" to correctly commit those modifications into the appropriate patch file
Before committing any Phase Two changes, you MUST read `references/phase-two-commit-guidelines.md` and follow its instructions exactly.
## Build Error Detection
When monitoring `e build -k 999` output, filter for errors using this regex pattern:
error:|FAILED:|fatal:|subcommand failed|build finished
The build output is extremely verbose. Filtering is essential to catch errors quickly.
## Commands Reference
| Command | Purpose |
|---------|---------|
| `e build -k 999` | Builds Electron and won't stop until either all targets attempted or 999 errors found |
| `e build -t {target}.o` | Build just one specific target to verify a fix |
| `e start --version` | Validate Electron launches after successful build |
## Two Types of Build Fixes
### A. Patch Fixes (for files in chromium_src or patched Chromium files)
When the error is in a file that Electron patches (check with `grep -l "filename" patches/chromium/*.patch`):
1. Edit the file in the Chromium source tree (e.g., `/src/chrome/browser/...`)
2. Create a fixup commit targeting the original patch commit:
```bash
cd .. # to chromium repo
git add <modified-file>
git commit --fixup=<original-patch-commit-hash>
GIT_SEQUENCE_EDITOR=: git rebase --autosquash --autostash -i <commit>^
3. Export the updated patch: e patches chromium
4. Commit the updated patch file in the electron repo following the `references/phase-one-commit-guidelines.md`, then commit changes following those instructions exactly. **READ THESE GUIDELINES BEFORE COMMITTING THESE CHANGES**
To find the original patch commit to fixup: `git log --oneline | grep -i "keyword from patch name"`
The base commit for rebase is the Chromium commit before patches were applied. Find it by checking the `refs/patches/upstream-head` ref.
B. Electron Code Fixes (for files in shell/, electron/, etc.)
When the error is in Electron's own source code:
1. Edit files directly in the electron repo
2. Commit directly (no patch export needed)
Dependent Patch Updates
IMPORTANT: When you modify a patch, other patches that apply to the same file may have their hunk headers invalidated. After committing a patch fix:
1. Run git status in the electron repo
2. Look for other modified .patch files with just index/hunk header changes
3. Commit these with: git commit -m "chore: update patch hunk headers"
# Critical: Read Before Committing
- Before ANY Phase One commits: Read `references/phase-one-commit-guidelines.md`
- Before ANY Phase Two commits: Read `references/phase-two-commit-guidelines.md`
# Skill Directory Structure
This skill has additional reference files in `references/`:
- patch-analysis.md - How to analyze patch failures
- phase-one-commit-guidelines.md - Commit format for Phase One
- phase-two-commit-guidelines.md - Commit format for Phase Two
Read these when referenced in the workflow steps.

View File

@@ -0,0 +1,69 @@
# Analyzing Patch Failures
## Investigation Steps
1. **Read the patch file** at `patches/{target}/{patch_name}.patch`
2. **Examine current state** of the file in Chromium at mentioned line numbers
3. **Check recent upstream changes:**
```bash
cd .. # or relevant target repo
git log --oneline -10 -- {file}
```
4. **Find Chromium CL** in commit messages:
```
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/{CL_NUMBER}
```
## Common Failure Patterns
| Pattern | Cause | Solution |
|---------|-------|----------|
| Context lines don't match | Surrounding code changed | Update context in patch |
| File not found | File renamed/moved | Update patch target path |
| Function not found | Refactored upstream | Find new function name |
| `DCHECK` → `CHECK_IS_TEST` | Macro change | Update to new macro |
| Deleted code | Feature removed | Verify patch still needed |
## Using Git Blame
To find the CL that changed specific lines:
```bash
cd ..
git blame -L {start},{end} -- {file}
git log -1 {commit_sha} # Look for Reviewed-on: line
```
## Verifying Patch Necessity
Before deleting a patch, verify:
1. The patched functionality was intentionally removed upstream
2. Electron doesn't need the patch for other reasons
3. No other code depends on the patched behavior
When in doubt, keep the patch and adapt it.
## Phase Two: Build-Time Patch Issues
Sometimes patches that applied successfully in Phase One cause build errors in Phase Two. This can happen when:
1. **Incomplete types**: A patch disables a header include, but new upstream code uses the type
2. **Missing members**: A patch modifies a class, but upstream added new code referencing the original
### Finding Which Patch Affects a File
```bash
grep -l "filename.cc" patches/chromium/*.patch
```
Matching Existing Patch Patterns
When fixing build errors in patched files, examine the existing patch to understand its style:
- Does it use #if 0 / #endif guards?
- Does it use #if BUILDFLAG(...) conditionals?
- What's the pattern for disabled functionality?
Apply fixes consistent with the existing patch style.

View File

@@ -0,0 +1,52 @@
# Phase One Commit Guidelines
Only follow these instructions if there are uncommitted changes to `patches/` after Phase One succeeds.
Ignore other instructions about making commit messages, our guidelines are CRITICALLY IMPORTANT and must be followed.
## Atomic Commits
For each fix made to a patch, create a separate commit:
```
fix(patch-conflict): {concise title}
{Brief explanation, 1-2 paragraphs max}
Ref: {Chromium CL link}
```
IMPORTANT: Ensure that any changes made to patch content as a result of a change in Chromium is committed individually. Each change should have it's own commit message and it's own REF.
IMPORTANT: Try really hard to find the CL reference per the instructions below. Each change you made should in theory have been in response to a change made in Chromium that you identified or can identify. Try for a while to identify and include the ref in the commit message. Do not give up easily.
## Finding CL References
Use `git log` or `git blame` on Chromium source files. Look for:
```
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/XXXXXXX
```
If no CL found after searching: `Ref: Unable to locate CL`
## Final Cleanup
After all fix commits, stage remaining changes:
```bash
git add patches
git commit -m "chore: update patch hunk headers"
```
## Example Commit
```
fix(patch-conflict): update web_contents_impl.cc context for navigation refactor
The upstream navigation code was refactored to use NavigationRequest directly
instead of going through NavigationController. Updated surrounding context
to match new code structure.
Ref: https://chromium-review.googlesource.com/c/chromium/src/+/1234567
```

View File

@@ -0,0 +1,82 @@
# Phase Two Commit Guidelines
Only follow these instructions if there are uncommitted changes in the Electron repo after any fixes are made during Phase Two that result a target that was failing, successfully building.
Ignore other instructions about making commit messages, our guidelines are CRITICALLY IMPORTANT and must be followed.
## Two Commit Types
### For Electron Source Changes (shell/, electron/, etc.)
```
{CL-Number}: {concise description of API change}
{Brief explanation of what upstream changed and how Electron was adapted}
Ref: {Chromium CL link}
```
IMPORTANT: Ensure that any change made to electron as a result of a change in Chromium is committed individually. Each change should have it's own commit message and it's own REF. Logically grouped into commits that make sense rather than one giant commit.
IMPORTANT: Try really hard to find the CL reference per the instructions below. Each change you made should in theory have been in response to a change made in Chromium that you identified or can identify. Try for a while to identify and include the ref in the commit message. Do not give up easily.
You may include multiple "Ref" links if required.
For a CL link in the format `https://chromium-review.googlesource.com/c/chromium/src/+/2958369` the "CL-Number" is `2958369`
### For Patch Updates (patches/chromium/*.patch)
Use the same fixup workflow as Phase One:
1. Fix in Chromium source tree
2. Fixup commit + rebase
3. Export with `e patches chromium`
4. Commit the patch file:
```
fix(patch-update): {concise description}
{Brief explanation}
Ref: {Chromium CL link}
```
## Dependent Patch Header Updates
After any patch modification, check for other affected patches:
```bash
git status
# If other .patch files show as modified with only hunk header changes:
git add patches/
git commit -m "chore: update patch hunk headers"
```
## Finding CL References
Use git log or git blame on Chromium source files. Look for:
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/XXXXXXX
If no CL found after searching: Ref: Unable to locate CL
## Example Commits
### Electron Source Fix
fix: update GetPlugins to GetPluginsAsync for API change
The upstream Chromium API changed:
- Old: GetPlugins(callback) - took a callback
- New: GetPluginsAsync(callback) - async version takes a callback
Ref: https://chromium-review.googlesource.com/c/chromium/src/+/1234567
### Patch Fix
fix(patch-conflict): update picture-in-picture for gesture handling refactor
Upstream added new gesture handling code that accesses live caption dialog.
The live caption functionality is disabled in Electron's patch, so wrapped
the new code in #if 0 guards to match existing pattern.
Ref: https://chromium-review.googlesource.com/c/chromium/src/+/7654321

View File

@@ -1,4 +1,5 @@
{
"name": "Electron Core Development Environment",
"dockerComposeFile": "docker-compose.yml",
"service": "buildtools",
"onCreateCommand": ".devcontainer/on-create-command.sh",
@@ -33,27 +34,15 @@
"surajbarkale.ninja",
"ms-vscode.cpptools",
"mutantdino.resourcemonitor",
"dsanders11.vscode-electron-build-tools",
"dbaeumer.vscode-eslint",
"shakram02.bash-beautify",
"marshallofsound.gnls-electron",
"marshallofsound.gnls-electron"
],
"settings": {
"editor.tabSize": 2,
"bashBeautify.tabSize": 2,
"typescript.tsdk": "node_modules/typescript/lib",
"[gn]": {
"editor.formatOnSave": true
},
"[javascript]": {
"editor.codeActionsOnSave": {
"source.fixAll.eslint": true
}
},
"[typescript]": {
"editor.codeActionsOnSave": {
"source.fixAll.eslint": true
}
},
"javascript.preferences.quoteStyle": "single",
"typescript.preferences.quoteStyle": "single"
}

View File

@@ -2,7 +2,7 @@ version: '3'
services:
buildtools:
image: ghcr.io/electron/devcontainer:77262e58c37631ab082482f42c33cdf68c6c394b
image: ghcr.io/electron/devcontainer:a82b87d7a4f5ff0cab61405f8151ac4cf4942aeb
volumes:
- ..:/workspaces/gclient/src/electron:cached

View File

@@ -48,7 +48,8 @@ if [ ! -f $buildtools/configs/evm.testing.json ]; then
\"gen\": {
\"args\": [
\"import(\\\"//electron/build/args/testing.gn\\\")\",
\"use_remoteexec = true\"
\"use_remoteexec = true\",
\"use_siso=true\"
],
\"out\": \"Testing\"
},
@@ -58,13 +59,13 @@ if [ ! -f $buildtools/configs/evm.testing.json ]; then
},
\"\$schema\": \"file:///home/builduser/.electron_build_tools/evm-config.schema.json\",
\"configValidationLevel\": \"strict\",
\"reclient\": \"$1\",
\"preserveXcode\": 5
\"remoteBuild\": \"siso\",
\"preserveSDK\": 5
}
" >$buildtools/configs/evm.testing.json
}
write_config remote_exec
write_config
e use testing
else

View File

@@ -1,5 +1,4 @@
# These env vars are only necessary for creating Electron releases.
# See docs/development/releasing.md
APPVEYOR_CLOUD_TOKEN=
ELECTRON_GITHUB_TOKEN=

4
.github/CODEOWNERS vendored
View File

@@ -8,13 +8,9 @@
DEPS @electron/wg-upgrades
# Releases WG
/.github/workflows/update_appveyor_image.yml @electron/wg-releases
/docs/breaking-changes.md @electron/wg-releases
/npm/ @electron/wg-releases
/script/release @electron/wg-releases
appveyor.yml @electron/wg-releases
appveyor-bake.yml @electron/wg-releases
appveyor-woa.yml @electron/wg-releases
# Security WG
/lib/browser/devtools.ts @electron/wg-security

View File

@@ -58,6 +58,16 @@ body:
label: Last Known Working Electron version
description: What is the last version of Electron this worked in, if applicable?
placeholder: 16.0.0
- type: dropdown
attributes:
label: Does the issue also appear in Chromium / Google Chrome?
description: If it does, please report the issue in the [Chromium issue tracker](https://issues.chromium.org/issues), not against Electron. Electron will inherit the fix once Chromium resolves the issue.
options:
- I don't know how to test
- "Yes"
- "No"
validations:
required: true
- type: textarea
attributes:
label: Expected Behavior
@@ -73,7 +83,7 @@ body:
- type: input
attributes:
label: Testcase Gist URL
description: If you can reproduce the issue in a standalone test case, please use [Electron Fiddle](https://github.com/electron/fiddle) to create one and to publish it as a [GitHub gist](https://gist.github.com) and put the gist URL here. This is **the best way** to ensure this issue is triaged quickly.
description: Electron maintainers need a standalone test case to reproduce and fix your issue. Please use [Electron Fiddle](https://github.com/electron/fiddle) to create one and to publish it as a [GitHub gist](https://gist.github.com). Then put the gist URL here. Issues without testcase gists receive less attention and might be closed without a maintainer taking a closer look. To maximize how much attention your issue receives, please include a testcase gist right from the start.
placeholder: https://gist.github.com/...
- type: textarea
attributes:

View File

@@ -1,3 +1,4 @@
blank_issues_enabled: false
contact_links:
- name: Discord Chat
url: https://discord.gg/APGC3k5yaH

View File

@@ -0,0 +1,14 @@
name: Maintainer Issue (not for public use)
description: Only to be created by Electron maintainers
body:
- type: checkboxes
attributes:
label: Confirmation
options:
- label: I am a [maintainer](https://github.com/orgs/electron/people) of the Electron project. (If not, please create a [different issue type](https://github.com/electron/electron/issues/new/).)
required: true
- type: textarea
attributes:
label: Description
validations:
required: true

View File

@@ -10,10 +10,11 @@ Contributors guide: https://github.com/electron/electron/blob/main/CONTRIBUTING.
#### Checklist
<!-- Remove items that do not apply. For completed items, change [ ] to [x]. -->
- [ ] PR description included and stakeholders cc'd
- [ ] PR description included
- [ ] I have built and tested this PR
- [ ] `npm test` passes
- [ ] tests are [changed or added](https://github.com/electron/electron/blob/main/docs/development/testing.md)
- [ ] relevant documentation, tutorials, templates and examples are changed or added
- [ ] relevant API documentation, tutorials, and examples are updated and follow the [documentation style guide](https://github.com/electron/electron/blob/main/docs/development/style-guide.md)
- [ ] [PR release notes](https://github.com/electron/clerk/blob/main/README.md) describe the change in a way relevant to app developers, and are [capitalized, punctuated, and past tense](https://github.com/electron/clerk/blob/main/README.md#examples).
#### Release Notes

View File

@@ -17,9 +17,6 @@ inputs:
is-release:
description: 'Is release build'
required: true
strip-binaries:
description: 'Strip binaries (Linux only)'
required: false
generate-symbols:
description: 'Generate symbols'
required: true
@@ -29,6 +26,9 @@ inputs:
is-asan:
description: 'The ASan Linux build'
required: false
upload-out-gen-artifacts:
description: 'Whether to upload the out/${dir}/gen artifacts'
required: false
runs:
using: "composite"
steps:
@@ -38,7 +38,17 @@ runs:
run: |
GN_APPENDED_ARGS="$GN_EXTRA_ARGS target_cpu=\"x64\" v8_snapshot_toolchain=\"//build/toolchain/mac:clang_x64\""
echo "GN_EXTRA_ARGS=$GN_APPENDED_ARGS" >> $GITHUB_ENV
- name: Set GN_EXTRA_ARGS for Windows
shell: bash
if: ${{inputs.target-arch != 'x64' && inputs.target-platform == 'win' }}
run: |
GN_APPENDED_ARGS="$GN_EXTRA_ARGS target_cpu=\"${{ inputs.target-arch }}\""
echo "GN_EXTRA_ARGS=$GN_APPENDED_ARGS" >> $GITHUB_ENV
- name: Add Clang problem matcher
shell: bash
run: echo "::add-matcher::src/electron/.github/problem-matchers/clang.json"
- name: Build Electron ${{ inputs.step-suffix }}
if: ${{ inputs.target-platform != 'win' }}
shell: bash
run: |
rm -rf "src/out/Default/Electron Framework.framework"
@@ -54,22 +64,51 @@ runs:
sudo launchctl limit maxfiles 65536 200000
fi
NINJA_SUMMARIZE_BUILD=1 e build -j $NUMBER_OF_NINJA_PROCESSES
if [ "${{ inputs.is-release }}" = "true" ]; then
NINJA_SUMMARIZE_BUILD=1 e build --target electron:release_build
else
NINJA_SUMMARIZE_BUILD=1 e build --target electron:testing_build
fi
cp out/Default/.ninja_log out/electron_ninja_log
node electron/script/check-symlinks.js
- name: Strip Electron Binaries ${{ inputs.step-suffix }}
shell: bash
if: ${{ inputs.strip-binaries == 'true' }}
# Upload build stats to Datadog
if ! [ -z $DD_API_KEY ]; then
npx node electron/script/build-stats.mjs out/Default/siso.INFO --upload-stats || true
else
echo "Skipping build-stats.mjs upload because DD_API_KEY is not set"
fi
- name: Build Electron (Windows) ${{ inputs.step-suffix }}
if: ${{ inputs.target-platform == 'win' }}
shell: powershell
run: |
cd src
electron/script/copy-debug-symbols.py --target-cpu="${{ inputs.target-arch }}" --out-dir=out/Default/debug --compress
electron/script/strip-binaries.py --target-cpu="${{ inputs.target-arch }}" --verbose
electron/script/add-debug-link.py --target-cpu="${{ inputs.target-arch }}" --debug-dir=out/Default/debug
- name: Build Electron dist.zip ${{ inputs.step-suffix }}
cd src\electron
git pack-refs
cd ..
$env:NINJA_SUMMARIZE_BUILD = 1
if ("${{ inputs.is-release }}" -eq "true") {
e build --target electron:release_build
} else {
e build --target electron:testing_build
}
Copy-Item out\Default\.ninja_log out\electron_ninja_log
node electron\script\check-symlinks.js
# Upload build stats to Datadog
if ($env:DD_API_KEY) {
try {
npx node electron\script\build-stats.mjs out\Default\siso.exe.INFO --upload-stats
} catch {
Write-Host "Build stats upload failed, continuing..."
}
} else {
Write-Host "Skipping build-stats.mjs upload because DD_API_KEY is not set"
}
- name: Verify dist.zip ${{ inputs.step-suffix }}
shell: bash
run: |
cd src
e build --target electron:electron_dist_zip -j $NUMBER_OF_NINJA_PROCESSES
cd src
if [ "${{ inputs.is-asan }}" != "true" ]; then
target_os=${{ inputs.target-platform == 'macos' && 'mac' || inputs.target-platform }}
if [ "${{ inputs.artifact-platform }}" = "mas" ]; then
@@ -77,11 +116,10 @@ runs:
fi
electron/script/zip_manifests/check-zip-manifest.py out/Default/dist.zip electron/script/zip_manifests/dist_zip.$target_os.${{ inputs.target-arch }}.manifest
fi
- name: Build Mksnapshot ${{ inputs.step-suffix }}
- name: Fixup Mksnapshot ${{ inputs.step-suffix }}
shell: bash
run: |
cd src
e build --target electron:electron_mksnapshot -j $NUMBER_OF_NINJA_PROCESSES
ELECTRON_DEPOT_TOOLS_DISABLE_LOG=1 e d gn desc out/Default v8:run_mksnapshot_default args > out/Default/mksnapshot_args
# Remove unused args from mksnapshot_args
SEDOPTION="-i"
@@ -91,24 +129,12 @@ runs:
sed $SEDOPTION '/.*builtins-pgo/d' out/Default/mksnapshot_args
sed $SEDOPTION '/--turbo-profiling-input/d' out/Default/mksnapshot_args
if [ "${{ inputs.target-platform }}" = "linux" ]; then
if [ "${{ inputs.target-arch }}" = "arm" ]; then
electron/script/strip-binaries.py --file $PWD/out/Default/clang_x86_v8_arm/mksnapshot
electron/script/strip-binaries.py --file $PWD/out/Default/clang_x86_v8_arm/v8_context_snapshot_generator
elif [ "${{ inputs.target-arch }}" = "arm64" ]; then
electron/script/strip-binaries.py --file $PWD/out/Default/clang_x64_v8_arm64/mksnapshot
electron/script/strip-binaries.py --file $PWD/out/Default/clang_x64_v8_arm64/v8_context_snapshot_generator
else
electron/script/strip-binaries.py --file $PWD/out/Default/mksnapshot
electron/script/strip-binaries.py --file $PWD/out/Default/v8_context_snapshot_generator
fi
fi
e build --target electron:electron_mksnapshot_zip -j $NUMBER_OF_NINJA_PROCESSES
if [ "${{ inputs.target-platform }}" = "win" ]; then
cd out/Default
powershell Compress-Archive -update mksnapshot_args mksnapshot.zip
powershell Compress-Archive -update gen/v8/embedded.S mksnapshot.zip
powershell mkdir mktmp\\gen\\v8
powershell Copy-Item gen\\v8\\embedded.S mktmp\\gen\\v8
powershell Compress-Archive -update -Path mktmp\\gen mksnapshot.zip
else
(cd out/Default; zip mksnapshot.zip mksnapshot_args gen/v8/embedded.S)
fi
@@ -136,24 +162,39 @@ runs:
shell: bash
run: |
cd src
e build --target electron:electron_chromedriver -j $NUMBER_OF_NINJA_PROCESSES
e build --target electron:electron_chromedriver_zip
- name: Build Node.js headers ${{ inputs.step-suffix }}
shell: bash
if [ "${{ inputs.is-asan }}" != "true" ]; then
target_os=${{ inputs.target-platform == 'macos' && 'mac' || inputs.target-platform }}
if [ "${{ inputs.artifact-platform }}" = "mas" ]; then
target_os="${target_os}_mas"
fi
electron/script/zip_manifests/check-zip-manifest.py out/Default/chromedriver.zip electron/script/zip_manifests/chromedriver_zip.$target_os.${{ inputs.target-arch }}.manifest
fi
- name: Create installed_software.json ${{ inputs.step-suffix }}
shell: powershell
if: ${{ inputs.is-release == 'true' && inputs.target-platform == 'win' }}
run: |
cd src
e build --target electron:node_headers
- name: Generate & Zip Symbols ${{ inputs.step-suffix }}
Get-CimInstance -Namespace root\cimv2 -Class Win32_product | Select vendor, description, @{l='install_location';e='InstallLocation'}, @{l='install_date';e='InstallDate'}, @{l='install_date_2';e='InstallDate2'}, caption, version, name, @{l='sku_number';e='SKUNumber'} | ConvertTo-Json | Out-File -Encoding utf8 -FilePath .\installed_software.json
- name: Profile Windows Toolchain ${{ inputs.step-suffix }}
shell: bash
if: ${{ inputs.is-release == 'true' && inputs.target-platform == 'win' }}
run: |
cd src
python3 electron/build/profile_toolchain.py --output-json=out/Default/windows_toolchain_profile.json
- name: Add msdia140.dll to Path ${{ inputs.step-suffix }}
shell: bash
if: ${{ inputs.is-release == 'true' && inputs.target-platform == 'win' }}
run: |
# Needed for msdia140.dll on 64-bit windows
cd src
export PATH="$PATH:$(pwd)/third_party/llvm-build/Release+Asserts/bin"
- name: Zip Symbols ${{ inputs.step-suffix }}
shell: bash
run: |
# Generate breakpad symbols on release builds
if [ "${{ inputs.generate-symbols }}" = "true" ]; then
e build --target electron:electron_symbols
fi
cd src
export BUILD_PATH="$(pwd)/out/Default"
e build --target electron:licenses
e build --target electron:electron_version_file
if [ "${{ inputs.is-release }}" = "true" ]; then
DELETE_DSYMS_AFTER_ZIP=1 electron/script/zip-symbols.py -b $BUILD_PATH
else
@@ -164,29 +205,21 @@ runs:
if: ${{ inputs.is-release == 'true' }}
run: |
cd src
gn gen out/ffmpeg --args="import(\"//electron/build/args/ffmpeg.gn\") use_remoteexec=true $GN_EXTRA_ARGS"
e build --target electron:electron_ffmpeg_zip -C ../../out/ffmpeg -j $NUMBER_OF_NINJA_PROCESSES
- name: Generate Hunspell Dictionaries ${{ inputs.step-suffix }}
gn gen out/ffmpeg --args="import(\"//electron/build/args/ffmpeg.gn\") use_remoteexec=true use_siso=true $GN_EXTRA_ARGS"
e build --target electron:electron_ffmpeg_zip -C ../../out/ffmpeg
- name: Remove Clang problem matcher
shell: bash
if: ${{ inputs.is-release == 'true' && inputs.target-platform == 'linux' }}
run: |
e build --target electron:hunspell_dictionaries_zip -j $NUMBER_OF_NINJA_PROCESSES
- name: Generate Libcxx ${{ inputs.step-suffix }}
shell: bash
if: ${{ inputs.is-release == 'true' && inputs.target-platform == 'linux' }}
run: |
e build --target electron:libcxx_headers_zip -j $NUMBER_OF_NINJA_PROCESSES
e build --target electron:libcxxabi_headers_zip -j $NUMBER_OF_NINJA_PROCESSES
e build --target electron:libcxx_objects_zip -j $NUMBER_OF_NINJA_PROCESSES
run: echo "::remove-matcher owner=clang::"
- name: Generate TypeScript Definitions ${{ inputs.step-suffix }}
if: ${{ inputs.is-release == 'true' }}
shell: bash
run: |
cd src/electron
node script/yarn create-typescript-definitions
node script/yarn.js create-typescript-definitions
- name: Publish Electron Dist ${{ inputs.step-suffix }}
if: ${{ inputs.is-release == 'true' }}
shell: bash
id: github-upload
run: |
rm -rf src/out/Default/obj
cd src/electron
@@ -197,7 +230,34 @@ runs:
echo 'Uploading Electron release distribution to GitHub releases'
script/release/uploaders/upload.py --verbose
fi
- name: Generate artifact attestation
if: ${{ inputs.is-release == 'true' }}
uses: actions/attest-build-provenance@96278af6caaf10aea03fd8d33a09a777ca52d62f # v3.2.0
with:
subject-path: ${{ steps.github-upload.outputs.UPLOADED_PATHS }}
- name: Generate siso report
if: ${{ inputs.target-platform != 'win' && !cancelled() }}
shell: bash
run: |
cd src
e d siso report -C out/Default > siso_report.txt
SISO_REPORT_PATH=$(grep -o '/.*siso-report-[^ ]*' siso_report.txt)
echo "SISO_REPORT_PATH=$SISO_REPORT_PATH" >> $GITHUB_ENV
cat siso_report.txt
echo "SISO REPORT AT $SISO_REPORT_PATH"
- name: Generate siso report (Windows)
if: ${{ inputs.target-platform == 'win' && !cancelled() }}
shell: powershell
run: |
cd src
e d siso report -C out\Default > siso_report.txt
$SISO_REPORT_PATH = Get-Content "siso_report.txt" | Select-String "report file:\s*(.+)" | ForEach-Object {
$_.Matches.Groups[1].Value.Trim()
}
echo "SISO_REPORT_PATH=$SISO_REPORT_PATH"
echo "SISO_REPORT_PATH=$SISO_REPORT_PATH" >> $env:GITHUB_ENV
- name: Generate Artifact Key
if: always() && !cancelled()
shell: bash
run: |
if [ "${{ inputs.is-asan }}" = "true" ]; then
@@ -209,9 +269,11 @@ runs:
# The current generated_artifacts_<< artifact.key >> name was taken from CircleCI
# to ensure we don't break anything, but we may be able to improve that.
- name: Move all Generated Artifacts to Upload Folder ${{ inputs.step-suffix }}
if: always() && !cancelled()
shell: bash
run: ./src/electron/script/actions/move-artifacts.sh
- name: Upload Generated Artifacts ${{ inputs.step-suffix }}
if: always() && !cancelled()
uses: actions/upload-artifact@65462800fd760344b1a7b4382951275a0abb4808
with:
name: generated_artifacts_${{ env.ARTIFACT_KEY }}
@@ -221,3 +283,9 @@ runs:
with:
name: src_artifacts_${{ env.ARTIFACT_KEY }}
path: ./src_artifacts_${{ inputs.artifact-platform }}_${{ inputs.target-arch }}
- name: Upload Out Gen Artifacts ${{ inputs.step-suffix }}
if: ${{ inputs.upload-out-gen-artifacts == 'true' }}
uses: actions/upload-artifact@65462800fd760344b1a7b4382951275a0abb4808
with:
name: out_gen_artifacts_${{ env.ARTIFACT_KEY }}
path: ./src/out/Default/gen

View File

@@ -0,0 +1,83 @@
name: 'Build Git Cache'
description: 'Runs a gclient sync to build the git cache for Electron'
inputs:
target-platform:
description: 'Target platform, should be linux, win, macos'
runs:
using: "composite"
steps:
- name: Set GIT_CACHE_PATH to make gclient to use the cache
shell: bash
run: |
echo "GIT_CACHE_PATH=$(pwd)/git-cache" >> $GITHUB_ENV
- name: Set Chromium Git Cookie
uses: ./src/electron/.github/actions/set-chromium-cookie
- name: Install Build Tools
uses: ./src/electron/.github/actions/install-build-tools
- name: Set up cache drive
shell: bash
run: |
if [ "${{ inputs.target-platform }}" = "win" ]; then
echo "CACHE_DRIVE=/mnt/win-cache" >> $GITHUB_ENV
else
echo "CACHE_DRIVE=/mnt/cross-instance-cache" >> $GITHUB_ENV
fi
- name: Check cross instance cache disk space
shell: bash
run: |
# if there is less than 35 GB free space then creating the cache might fail so exit early
freespace=`df -m $CACHE_DRIVE | grep -w $CACHE_DRIVE | awk '{print $4}'`
freespace_human=`df -h $CACHE_DRIVE | grep -w $CACHE_DRIVE | awk '{print $4}'`
if [ $freespace -le 35000 ]; then
echo "The cross mount cache has $freespace_human free space which is not enough - exiting"
exit 1
else
echo "The cross mount cache has $freespace_human free space - continuing"
fi
- name: Restore gitcache
shell: bash
run: |
GIT_CACHE_TAR="$CACHE_DRIVE/gitcache.tar"
if [ ! -f "$GIT_CACHE_TAR" ]; then
echo "Git cache tar file does not exist, skipping restore"
exit 0
fi
echo "Restoring git cache from $GIT_CACHE_TAR to $GIT_CACHE_PATH"
mkdir -p $GIT_CACHE_PATH
tar -xf $GIT_CACHE_TAR -C $GIT_CACHE_PATH
- name: Gclient Sync
shell: bash
run: |
e d gclient config \
--name "src/electron" \
--unmanaged \
${GCLIENT_EXTRA_ARGS} \
"$GITHUB_SERVER_URL/$GITHUB_REPOSITORY"
if [ "$TARGET_OS" != "" ]; then
echo "target_os=['$TARGET_OS']" >> ./.gclient
fi
ELECTRON_USE_THREE_WAY_MERGE_FOR_PATCHES=1 e d gclient sync --with_branch_heads --with_tags --nohooks -vv
- name: Compress Git Cache Directory
shell: bash
run: |
echo "Uncompressed gitcache size: $(du -sh $GIT_CACHE_PATH | cut -f1 -d' ')"
cd $GIT_CACHE_PATH
tar -cf ../gitcache.tar .
cd ..
echo "Compressed gitcache to $(du -sh gitcache.tar | cut -f1 -d' ')"
# remove the old cache file if it exists
if [ -f $CACHE_DRIVE/gitcache.tar ]; then
echo "Removing old gitcache.tar from $CACHE_DRIVE"
rm $CACHE_DRIVE/gitcache.tar
fi
cp ./gitcache.tar $CACHE_DRIVE/
- name: Wait for active SSH sessions
shell: bash
if: always() && !cancelled()
run: |
while [ -f /var/.ssh-lock ]
do
sleep 60
done

View File

@@ -9,6 +9,8 @@ inputs:
description: 'Whether to persist the cache to the shared drive'
required: false
default: 'true'
target-platform:
description: 'Target platform, should be linux, win, macos'
runs:
using: "composite"
steps:
@@ -18,38 +20,34 @@ runs:
echo "GIT_CACHE_PATH=$(pwd)/git-cache" >> $GITHUB_ENV
- name: Install Dependencies
uses: ./src/electron/.github/actions/install-dependencies
- name: Set Chromium Git Cookie
uses: ./src/electron/.github/actions/set-chromium-cookie
- name: Install Build Tools
uses: ./src/electron/.github/actions/install-build-tools
- name: Get Depot Tools
shell: bash
run: |
if [[ ! -d depot_tools ]]; then
git clone --depth=1 https://chromium.googlesource.com/chromium/tools/depot_tools.git
# Ensure depot_tools does not update.
test -d depot_tools && cd depot_tools
touch .disable_auto_update
fi
- name: Add Depot Tools to PATH
shell: bash
run: echo "$(pwd)/depot_tools" >> $GITHUB_PATH
- name: Generate DEPS Hash
shell: bash
run: |
node src/electron/script/generate-deps-hash.js
echo "DEPSHASH=v1-src-cache-$(cat src/electron/.depshash)" >> $GITHUB_ENV
DEPSHASH="v1-src-cache-$(cat src/electron/.depshash)"
echo "DEPSHASH=$DEPSHASH" >> $GITHUB_ENV
echo "CACHE_FILE=$DEPSHASH.tar" >> $GITHUB_ENV
if [ "${{ inputs.target-platform }}" = "win" ]; then
echo "CACHE_DRIVE=/mnt/win-cache" >> $GITHUB_ENV
else
echo "CACHE_DRIVE=/mnt/cross-instance-cache" >> $GITHUB_ENV
fi
- name: Generate SAS Key
if: ${{ inputs.generate-sas-token == 'true' }}
shell: bash
run: |
curl --unix-socket /var/run/sas/sas.sock --fail "http://foo/$DEPSHASH.tar" > sas-token
curl --unix-socket /var/run/sas/sas.sock --fail "http://foo/$CACHE_FILE?platform=${{ inputs.target-platform }}&getAccountName=true" > sas-token
- name: Save SAS Key
if: ${{ inputs.generate-sas-token == 'true' }}
uses: actions/cache/save@v4
uses: actions/cache/save@5a3ec84eff668545956fd18022155c47e93e2684 # v4.2.3
with:
path: |
sas-token
key: sas-key-${{ github.run_number }}-${{ github.run_attempt }}
path: sas-token
key: sas-key-${{ inputs.target-platform }}-${{ github.run_number }}-${{ github.run_attempt }}
enableCrossOsArchive: true
- name: Check If Cache Exists
id: check-cache
shell: bash
@@ -58,7 +56,7 @@ runs:
echo "Not using cache this time..."
echo "cache_exists=false" >> $GITHUB_OUTPUT
else
cache_path=/mnt/cross-instance-cache/$DEPSHASH.tar
cache_path=$CACHE_DRIVE/$CACHE_FILE
echo "Using cache key: $DEPSHASH"
echo "Checking for cache in: $cache_path"
if [ ! -f "$cache_path" ] || [ `du $cache_path | cut -f1` = "0" ]; then
@@ -73,15 +71,30 @@ runs:
if: steps.check-cache.outputs.cache_exists == 'false' && inputs.use-cache == 'true'
shell: bash
run: |
# if there is less than 20 GB free space then creating the cache might fail so exit early
freespace=`df -m /mnt/cross-instance-cache | grep -w /mnt/cross-instance-cache | awk '{print $4}'`
freespace_human=`df -h /mnt/cross-instance-cache | grep -w /mnt/cross-instance-cache | awk '{print $4}'`
if [ $freespace -le 20000 ]; then
# if there is less than 35 GB free space then creating the cache might fail so exit early
freespace=`df -m $CACHE_DRIVE | grep -w $CACHE_DRIVE | awk '{print $4}'`
freespace_human=`df -h $CACHE_DRIVE | grep -w $CACHE_DRIVE | awk '{print $4}'`
if [ $freespace -le 35000 ]; then
echo "The cross mount cache has $freespace_human free space which is not enough - exiting"
exit 1
else
echo "The cross mount cache has $freespace_human free space - continuing"
fi
- name: Add patch conflict problem matcher
shell: bash
run: echo "::add-matcher::src/electron/.github/problem-matchers/patch-conflict.json"
- name: Restore gitcache
if: steps.check-cache.outputs.cache_exists == 'false'
shell: bash
run: |
GIT_CACHE_TAR="$CACHE_DRIVE/gitcache.tar"
if [ ! -f "$GIT_CACHE_TAR" ]; then
echo "Git cache tar file does not exist, skipping restore"
exit 0
fi
echo "Restoring git cache from $GIT_CACHE_TAR to $GIT_CACHE_PATH"
mkdir -p $GIT_CACHE_PATH
tar -xf $GIT_CACHE_TAR -C $GIT_CACHE_PATH
- name: Gclient Sync
if: steps.check-cache.outputs.cache_exists == 'false'
shell: bash
@@ -97,19 +110,14 @@ runs:
fi
ELECTRON_USE_THREE_WAY_MERGE_FOR_PATCHES=1 e d gclient sync --with_branch_heads --with_tags -vv
if [ "${{ inputs.is-release }}" != "true" && -n "${{ env.PATCH_UP_APP_CREDS }}" ]; then
if [[ "${{ inputs.is-release }}" != "true" ]]; then
# Re-export all the patches to check if there were changes.
python3 src/electron/script/export_all_patches.py src/electron/patches/config.json
cd src/electron
git update-index --refresh || true
if ! git diff-index --quiet HEAD --; then
# There are changes to the patches. Make a git commit with the updated patches
git add patches
GIT_COMMITTER_NAME="PatchUp" GIT_COMMITTER_EMAIL="73610968+patchup[bot]@users.noreply.github.com" git commit -m "chore: update patches" --author="PatchUp <73610968+patchup[bot]@users.noreply.github.com>"
# Export it
mkdir -p ../../patches
git format-patch -1 --stdout --keep-subject --no-stat --full-index > ../../patches/update-patches.patch
if node ./script/push-patch.js; then
if node ./script/patch-up.js; then
echo
echo "======================================================================"
echo "Changes to the patches when applying, we have auto-pushed the diff to the current branch"
@@ -117,6 +125,11 @@ runs:
echo "======================================================================"
exit 1
else
git add patches
GIT_COMMITTER_NAME="PatchUp" GIT_COMMITTER_EMAIL="73610968+patchup[bot]@users.noreply.github.com" git commit -m "chore: update patches" --author="PatchUp <73610968+patchup[bot]@users.noreply.github.com>"
# Export it
mkdir -p ../../patches
git format-patch -1 --stdout --keep-subject --no-stat --full-index > ../../patches/update-patches.patch
echo
echo "======================================================================"
echo "There were changes to the patches when applying."
@@ -126,9 +139,21 @@ runs:
cat ../../patches/update-patches.patch
exit 1
fi
else
echo "No changes to patches detected"
fi
fi
- name: Remove patch conflict problem matchers
shell: bash
run: |
echo "::remove-matcher owner=merge-conflict::"
echo "::remove-matcher owner=patch-conflict::"
echo "::remove-matcher owner=patch-needs-update::"
- name: Upload patches stats
if: ${{ inputs.target-platform == 'linux' && github.ref == 'refs/heads/main' }}
shell: bash
run: |
node src/electron/script/patches-stats.mjs --upload-stats || true
# delete all .git directories under src/ except for
# third_party/angle/ and third_party/dawn/ because of build time generation of files
# gen/angle/commit.h depends on third_party/angle/.git/HEAD
@@ -148,7 +173,6 @@ runs:
run: |
rm -rf src/android_webview
rm -rf src/ios/chrome
rm -rf src/third_party/blink/web_tests
rm -rf src/third_party/blink/perf_tests
rm -rf src/chrome/test/data/xr/webvr_info
rm -rf src/third_party/angle/third_party/VK-GL-CTS/src
@@ -163,14 +187,14 @@ runs:
shell: bash
run: |
echo "Uncompressed src size: $(du -sh src | cut -f1 -d' ')"
tar -cf $DEPSHASH.tar src
echo "Compressed src to $(du -sh $DEPSHASH.tar | cut -f1 -d' ')"
cp ./$DEPSHASH.tar /mnt/cross-instance-cache/
tar -cf $CACHE_FILE src
echo "Compressed src to $(du -sh $CACHE_FILE | cut -f1 -d' ')"
cp ./$CACHE_FILE $CACHE_DRIVE/
- name: Persist Src Cache
if: ${{ steps.check-cache.outputs.cache_exists == 'false' && inputs.use-cache == 'true' }}
shell: bash
run: |
final_cache_path=/mnt/cross-instance-cache/$DEPSHASH.tar
final_cache_path=$CACHE_DRIVE/$CACHE_FILE
echo "Using cache key: $DEPSHASH"
echo "Checking path: $final_cache_path"
if [ ! -f "$final_cache_path" ]; then
@@ -179,3 +203,11 @@ runs:
else
echo "Cache key persisted in $final_cache_path"
fi
- name: Wait for active SSH sessions
shell: bash
if: always() && !cancelled()
run: |
while [ -f /var/.ssh-lock ]
do
sleep 60
done

51
.github/actions/cipd-install/action.yml vendored Normal file
View File

@@ -0,0 +1,51 @@
name: 'CIPD install'
description: 'Installs the specified CIPD package'
inputs:
cipd-root-prefix-path:
description: 'Path to prepend to installation directory'
default: ''
dependency:
description: 'Name of dependency to install'
deps-file:
description: 'Location of DEPS file that defines the dependency'
installation-dir:
description: 'Location to install dependency'
target-platform:
description: 'Target platform, should be linux, win, macos'
package:
description: 'Package to install'
dependency-version:
description: 'Version of the dependency to install'
default: ''
runs:
using: "composite"
steps:
- name: Delete wrong ${{ inputs.dependency }}
shell: bash
run : |
rm -rf ${{ inputs.cipd-root-prefix-path }}${{ inputs.installation-dir }}
- name: Create ensure file for ${{ inputs.dependency }}
if: ${{ inputs.dependency-version == '' }}
shell: bash
run: |
echo '${{ inputs.package }}' `e d gclient getdep --deps-file=${{ inputs.deps-file }} -r '${{ inputs.installation-dir }}:${{ inputs.package }}'` > ${{ inputs.dependency }}_ensure_file
cat ${{ inputs.dependency }}_ensure_file
- name: Create ensure file for ${{ inputs.dependency }} from dependency-version
if: ${{ inputs.dependency-version != '' }}
shell: bash
run: |
echo '${{ inputs.package }} ${{ inputs.dependency-version }}' > ${{ inputs.dependency }}_ensure_file
cat ${{ inputs.dependency }}_ensure_file
- name: CIPD installation of ${{ inputs.dependency }} (macOS)
if: ${{ inputs.target-platform != 'win' }}
shell: bash
run: |
echo "ensuring ${{ inputs.dependency }}"
e d cipd ensure --root ${{ inputs.cipd-root-prefix-path }}${{ inputs.installation-dir }} -ensure-file ${{ inputs.dependency }}_ensure_file
- name: CIPD installation of ${{ inputs.dependency }} (Windows)
if: ${{ inputs.target-platform == 'win' }}
shell: powershell
run: |
echo "ensuring ${{ inputs.dependency }} on Windows"
e d cipd ensure --root ${{ inputs.cipd-root-prefix-path }}${{ inputs.installation-dir }} -ensure-file ${{ inputs.dependency }}_ensure_file

View File

@@ -1,61 +0,0 @@
name: 'Fix Sync macOS'
description: 'Checks out Electron and stores it in the AKS Cache'
runs:
using: "composite"
steps:
- name: Fix Sync
shell: bash
# This step is required to correct for differences between "gclient sync"
# on Linux and the expected state on macOS. This requires:
# 1. Fixing Clang Install (wrong binary)
# 2. Fixing esbuild (wrong binary)
# 3. Fixing rustc (wrong binary)
# 4. Fixing gn (wrong binary)
# 5. Fix reclient (wrong binary)
# 6. Fixing dsymutil (wrong binary)
# 7. Ensuring we are using the correct ninja and adding it to PATH
# 8. Fixing angle (wrong remote)
run : |
SEDOPTION="-i ''"
rm -rf src/third_party/llvm-build
python3 src/tools/clang/scripts/update.py
echo 'infra/3pp/tools/esbuild/${platform}' `gclient getdep --deps-file=src/third_party/devtools-frontend/src/DEPS -r 'third_party/esbuild:infra/3pp/tools/esbuild/${platform}'` > esbuild_ensure_file
# Remove extra output from calling gclient getdep which always calls update_depot_tools
sed -i '' "s/Updating depot_tools... //g" esbuild_ensure_file
cipd ensure --root src/third_party/devtools-frontend/src/third_party/esbuild -ensure-file esbuild_ensure_file
rm -rf src/third_party/rust-toolchain
python3 src/tools/rust/update_rust.py
# Prevent calling gclient getdep which always calls update_depot_tools
echo 'gn/gn/mac-${arch}' `gclient getdep --deps-file=src/DEPS -r 'src/buildtools/mac:gn/gn/mac-${arch}'` > gn_ensure_file
sed -i '' "s/Updating depot_tools... //g" gn_ensure_file
cipd ensure --root src/buildtools/mac -ensure-file gn_ensure_file
# Prevent calling gclient getdep which always calls update_depot_tools
echo 'infra/rbe/client/${platform}' `gclient getdep --deps-file=src/DEPS -r 'src/buildtools/reclient:infra/rbe/client/${platform}'` > gn_ensure_file
sed -i '' "s/Updating depot_tools... //g" gn_ensure_file
cipd ensure --root src/buildtools/reclient -ensure-file gn_ensure_file
python3 src/buildtools/reclient_cfgs/configure_reclient_cfgs.py --rbe_instance "projects/rbe-chrome-untrusted/instances/default_instance" --reproxy_cfg_template reproxy.cfg.template --rewrapper_cfg_project "" --skip_remoteexec_cfg_fetch
if [ "${{ env.TARGET_ARCH }}" == "arm64" ]; then
DSYM_SHA_FILE=src/tools/clang/dsymutil/bin/dsymutil.arm64.sha1
else
DSYM_SHA_FILE=src/tools/clang/dsymutil/bin/dsymutil.x64.sha1
fi
python3 src/third_party/depot_tools/download_from_google_storage.py --no_resume --no_auth --bucket chromium-browser-clang -s $DSYM_SHA_FILE -o src/tools/clang/dsymutil/bin/dsymutil
echo 'infra/3pp/tools/ninja/${platform}' `gclient getdep --deps-file=src/DEPS -r 'src/third_party/ninja:infra/3pp/tools/ninja/${platform}'` > ninja_ensure_file
sed $SEDOPTION "s/Updating depot_tools... //g" ninja_ensure_file
cipd ensure --root src/third_party/ninja -ensure-file ninja_ensure_file
echo "$(pwd)/src/third_party/ninja" >> $GITHUB_PATH
cd src/third_party/angle
rm -f .git/objects/info/alternates
git remote set-url origin https://chromium.googlesource.com/angle/angle.git
cp .git/config .git/config.backup
git remote remove origin
mv .git/config.backup .git/config
git fetch

154
.github/actions/fix-sync/action.yml vendored Normal file
View File

@@ -0,0 +1,154 @@
name: 'Fix Sync'
description: 'Ensures proper binaries are in place'
# This action is required to correct for differences between "gclient sync"
# on Linux and the expected state on macOS/windows. This requires:
# 1. Fixing Clang Install (wrong binary)
# 2. Fixing esbuild (wrong binary)
# 3. Fixing rustc (wrong binary)
# 4. Fixing gn (wrong binary)
# 5. Fix reclient (wrong binary)
# 6. Fixing dsymutil (wrong binary)
# 7. Ensuring we are using the correct ninja and adding it to PATH
# 8. Fixing angle (wrong remote)
# 9. Install windows toolchain on Windows
# 10. Fix node binary on Windows
# 11. Fix rc binary on Windows
inputs:
target-platform:
description: 'Target platform, should be linux, win, macos'
runs:
using: "composite"
steps:
- name: Fix llvm toolchain
if: ${{ inputs.target-platform != 'linux' }}
shell: bash
run : |
rm -rf src/third_party/llvm-build
python3 src/tools/clang/scripts/update.py
# Refs https://chromium-review.googlesource.com/c/chromium/src/+/6667681
python3 src/tools/clang/scripts/update.py --package objdump
- name: Fix esbuild
if: ${{ inputs.target-platform != 'linux' }}
uses: ./src/electron/.github/actions/cipd-install
with:
cipd-root-prefix-path: src/third_party/devtools-frontend/src/
dependency: esbuild
deps-file: src/third_party/devtools-frontend/src/DEPS
installation-dir: third_party/esbuild
target-platform: ${{ inputs.target-platform }}
package: infra/3pp/tools/esbuild/${platform}
- name: Fix rollup
if: ${{ inputs.target-platform != 'linux' }}
uses: ./src/electron/.github/actions/cipd-install
with:
cipd-root-prefix-path: src/third_party/devtools-frontend/src/
dependency: rollup_libs
deps-file: src/third_party/devtools-frontend/src/DEPS
installation-dir: third_party/rollup_libs
target-platform: ${{ inputs.target-platform }}
package: infra/3pp/tools/rollup_libs/${platform}
- name: Sync native rollup libs
if: ${{ inputs.target-platform != 'linux' }}
shell: bash
run : |
cd src/third_party/devtools-frontend/src
python3 scripts/deps/sync_rollup_libs.py
- name: Fix rustc
if: ${{ inputs.target-platform != 'linux' }}
shell: bash
run : |
rm -rf src/third_party/rust-toolchain
python3 src/tools/rust/update_rust.py
- name: Fix gn (macOS)
if: ${{ inputs.target-platform == 'macos' }}
uses: ./src/electron/.github/actions/cipd-install
with:
dependency: gn
deps-file: src/DEPS
installation-dir: src/buildtools/mac
target-platform: ${{ inputs.target-platform }}
package: gn/gn/mac-${arch}
- name: Fix gn (Windows)
if: ${{ inputs.target-platform == 'win' }}
uses: ./src/electron/.github/actions/cipd-install
with:
dependency: gn
deps-file: src/DEPS
installation-dir: src/buildtools/win
target-platform: ${{ inputs.target-platform }}
package: gn/gn/windows-amd64
- name: Fix reclient
if: ${{ inputs.target-platform != 'linux' }}
uses: ./src/electron/.github/actions/cipd-install
with:
dependency: reclient
deps-file: src/DEPS
installation-dir: src/buildtools/reclient
target-platform: ${{ inputs.target-platform }}
package: infra/rbe/client/${platform}
- name: Configure reclient configs
if: ${{ inputs.target-platform != 'linux' }}
shell: bash
run : |
python3 src/buildtools/reclient_cfgs/configure_reclient_cfgs.py --rbe_instance "projects/rbe-chrome-untrusted/instances/default_instance" --reproxy_cfg_template reproxy.cfg.template --rewrapper_cfg_project "" --skip_remoteexec_cfg_fetch
- name: Fix dsymutil (macOS)
if: ${{ inputs.target-platform == 'macos' }}
shell: bash
run : |
# Fix dsymutil
if [ "${{ inputs.target-platform }}" = "macos" ]; then
if [ "${{ env.TARGET_ARCH }}" == "arm64" ]; then
DSYM_SHA_FILE=src/tools/clang/dsymutil/bin/dsymutil.arm64.sha1
else
DSYM_SHA_FILE=src/tools/clang/dsymutil/bin/dsymutil.x64.sha1
fi
python3 src/third_party/depot_tools/download_from_google_storage.py --no_resume --no_auth --bucket chromium-browser-clang -s $DSYM_SHA_FILE -o src/tools/clang/dsymutil/bin/dsymutil
fi
- name: Fix ninja
if: ${{ inputs.target-platform != 'linux' }}
uses: ./src/electron/.github/actions/cipd-install
with:
dependency: ninja
deps-file: src/DEPS
installation-dir: src/third_party/ninja
target-platform: ${{ inputs.target-platform }}
package: infra/3pp/tools/ninja/${platform}
- name: Set ninja in path
if: ${{ inputs.target-platform != 'linux' }}
shell: bash
run : |
echo "$(pwd)/src/third_party/ninja" >> $GITHUB_PATH
- name: Fix siso
uses: ./src/electron/.github/actions/cipd-install
with:
dependency: siso
deps-file: src/DEPS
installation-dir: src/third_party/siso/cipd
target-platform: ${{ inputs.target-platform }}
package: build/siso/${platform}
- name: Fixup angle git
if: ${{ inputs.target-platform != 'linux' }}
shell: bash
run : |
cd src/third_party/angle
rm -f .git/objects/info/alternates
git remote set-url origin https://chromium.googlesource.com/angle/angle.git
cp .git/config .git/config.backup
git remote remove origin
mv .git/config.backup .git/config
git fetch
- name: Get Windows toolchain
if: ${{ inputs.target-platform == 'win' }}
shell: powershell
run: e d vpython3 src\build\vs_toolchain.py update --force
- name: Download nodejs
if: ${{ inputs.target-platform == 'win' }}
shell: powershell
run: |
$nodedeps = e d gclient getdep --deps-file=src/DEPS -r src/third_party/node/win | ConvertFrom-JSON
python3 src\third_party\depot_tools\download_from_google_storage.py --no_resume --no_auth --bucket chromium-nodejs -o src\third_party\node\win\node.exe $nodedeps.object_name
- name: Install rc
if: ${{ inputs.target-platform == 'win' }}
shell: bash
run: |
python3 src/third_party/depot_tools/download_from_google_storage.py --no_resume --no_auth --bucket chromium-browser-clang/rc -s src/build/toolchain/win/rc/win/rc.exe.sha1

View File

@@ -6,6 +6,8 @@ runs:
- name: Free Space on MacOS
shell: bash
run: |
echo "Disk usage before cleanup:"
df -h
sudo mkdir -p $TMPDIR/del-target
tmpify() {
@@ -15,28 +17,30 @@ runs:
}
strip_universal_deep() {
opwd=$(pwd)
cd $1
f=$(find . -perm +111 -type f)
for fp in $f
do
if [[ $(file "$fp") == *"universal binary"* ]]; then
if [ "`arch`" == "arm64" ]; then
if [[ $(file "$fp") == *"x86_64"* ]]; then
sudo lipo -remove x86_64 "$fp" -o "$fp" || true
fi
else
if [[ $(file "$fp") == *"arm64e)"* ]]; then
sudo lipo -remove arm64e "$fp" -o "$fp" || true
fi
if [[ $(file "$fp") == *"arm64)"* ]]; then
sudo lipo -remove arm64 "$fp" -o "$fp" || true
if [ -d "$1" ]; then
opwd=$(pwd)
cd $1
f=$(find . -perm +111 -type f)
for fp in $f
do
if [[ $(file "$fp") == *"universal binary"* ]]; then
if [ "`arch`" == "arm64" ]; then
if [[ $(file "$fp") == *"x86_64"* ]]; then
sudo lipo -remove x86_64 "$fp" -o "$fp" || true
fi
else
if [[ $(file "$fp") == *"arm64e)"* ]]; then
sudo lipo -remove arm64e "$fp" -o "$fp" || true
fi
if [[ $(file "$fp") == *"arm64)"* ]]; then
sudo lipo -remove arm64 "$fp" -o "$fp" || true
fi
fi
fi
fi
done
done
cd $opwd
cd $opwd
fi
}
tmpify /Library/Developer/CoreSimulator
@@ -57,9 +61,31 @@ runs:
sudo rm -rf $TMPDIR/del-target
sudo rm -rf /Applications/Safari.app
sudo rm -rf /Applications/Xcode_16.1.app
sudo rm -rf /Applications/Xcode_16.2.app
sudo rm -rf /Applications/Xcode_16.3.app
sudo rm -rf /Applications/Xcode_26*
sudo rm -rf /Applications/Google Chrome.app
sudo rm -rf /Applications/Google Chrome for Testing.app
sudo rm -rf /Applications/Firefox.app
sudo rm -rf /Applications/Microsoft Edge.app
sudo rm -rf ~/project/src/third_party/catapult/tracing/test_data
sudo rm -rf ~/project/src/third_party/angle/third_party/VK-GL-CTS
sudo rm -rf /Users/runner/Library/Android
sudo rm -rf $JAVA_HOME_11_arm64
sudo rm -rf $JAVA_HOME_17_arm64
sudo rm -rf $JAVA_HOME_21_arm64
sudo rm -rf $JAVA_HOME_25_arm64
sudo rm -rf /Users/runner/.dotnet/
sudo rm -rf /Users/runner/.rustup
# remove homebrew packages we don't need
if command -v brew &> /dev/null; then
brew uninstall -f --zap aws-sam-cli session-manager-plugin gcc gcc@13 gcc@14 llvm@18 gradle maven ant azure-cli
brew autoremove
fi
# lipo off some huge binaries arm64 versions to save space
strip_universal_deep $(xcode-select -p)/../SharedFrameworks
# strip_arm_deep /System/Volumes/Data/Library/Developer/CommandLineTools/usr
# strip_arm_deep /System/Volumes/Data/Library/Developer/CommandLineTools/usr
sudo mdutil -a -i off

View File

@@ -13,12 +13,16 @@ runs:
- name: Generating Types for SHA in ${{ inputs.sha-file }}
shell: bash
run: |
git checkout $(cat ${{ inputs.sha-file }})
rm -rf node_modules
yarn install --frozen-lockfile --ignore-scripts
export ELECTRON_DIR=$(pwd)
if [ "${{ inputs.sha-file }}" == ".dig-old" ]; then
cd /tmp
git clone https://github.com/electron/electron.git
cd electron
fi
git checkout $(cat $ELECTRON_DIR/${{ inputs.sha-file }})
node script/yarn.js install --immutable
echo "#!/usr/bin/env node\nglobal.x=1" > node_modules/typescript/bin/tsc
node node_modules/.bin/electron-docs-parser --dir=./ --outDir=./ --moduleVersion=0.0.0-development
node node_modules/.bin/electron-typescript-definitions --api=electron-api.json --outDir=artifacts
mv artifacts/electron.d.ts artifacts/${{ inputs.filename }}
git checkout .
mv artifacts/electron.d.ts $ELECTRON_DIR/artifacts/${{ inputs.filename }}
working-directory: ./electron

View File

@@ -10,11 +10,23 @@ runs:
git config --global core.filemode false
git config --global core.autocrlf false
git config --global branch.autosetuprebase always
git config --global core.fscache true
git config --global core.longpaths true
git config --global core.preloadindex true
git config --global core.longpaths true
fi
export BUILD_TOOLS_SHA=8246e57791b0af4ae5975eb96f09855f9269b1cd
export BUILD_TOOLS_SHA=4430e4a505e0f4fa2a41b707a10a36f780bbdd26
npm i -g @electron/build-tools
# Update depot_tools to ensure python
e d update_depot_tools
e auto-update disable
# Disable further updates of depot_tools
e d auto-update disable
if [ "$(expr substr $(uname -s) 1 10)" == "MSYS_NT-10" ]; then
e d cipd.bat --version
cp "C:\Python37\python.exe" "C:\Python37\python3.exe"
fi
cp "C:\Python311\python.exe" "C:\Python311\python3.exe"
echo "C:\Users\ContainerAdministrator\.electron_build_tools\third_party\depot_tools" >> $GITHUB_PATH
else
echo "$HOME/.electron_build_tools/third_party/depot_tools" >> $GITHUB_PATH
echo "$HOME/.electron_build_tools/third_party/depot_tools/python-bin" >> $GITHUB_PATH
fi

View File

@@ -6,8 +6,8 @@ runs:
- name: Get yarn cache directory path
shell: bash
id: yarn-cache-dir-path
run: echo "dir=$(node src/electron/script/yarn cache dir)" >> $GITHUB_OUTPUT
- uses: actions/cache@0c45773b623bea8c8e75f6c82b208c3cf94ea4f9
run: echo "dir=$(node src/electron/script/yarn.js config get cacheFolder)" >> $GITHUB_OUTPUT
- uses: actions/cache@5a3ec84eff668545956fd18022155c47e93e2684 # v4.2.3
id: yarn-cache
with:
path: ${{ steps.yarn-cache-dir-path.outputs.dir }}
@@ -18,4 +18,14 @@ runs:
shell: bash
run: |
cd src/electron
node script/yarn install --frozen-lockfile --prefer-offline
if [ "$TARGET_ARCH" = "x86" ]; then
export npm_config_arch="ia32"
fi
# if running on linux arm skip yarn Builds
ARCH=$(uname -m)
if [ "$ARCH" = "armv7l" ]; then
echo "Skipping yarn build on linux arm"
node script/yarn.js install --immutable --mode=skip-build
else
node script/yarn.js install --immutable
fi

View File

@@ -1,12 +1,20 @@
name: 'Restore Cache AKS'
description: 'Restores Electron src cache via AKS'
inputs:
target-platform:
description: 'Target platform, should be linux, win, macos'
runs:
using: "composite"
steps:
- name: Restore and Ensure Src Cache
shell: bash
run: |
cache_path=/mnt/cross-instance-cache/$DEPSHASH.tar
if [ "${{ inputs.target-platform }}" = "win" ]; then
cache_path=/mnt/win-cache/$DEPSHASH.tar
else
cache_path=/mnt/cross-instance-cache/$DEPSHASH.tar
fi
echo "Using cache key: $DEPSHASH"
echo "Checking for cache in: $cache_path"
if [ ! -f "$cache_path" ]; then

View File

@@ -1,22 +1,25 @@
name: 'Restore Cache AZCopy'
description: 'Restores Electron src cache via AZCopy'
inputs:
target-platform:
description: 'Target platform, should be linux, win, macos'
runs:
using: "composite"
steps:
- name: Obtain SAS Key
continue-on-error: true
uses: actions/cache/restore@0c45773b623bea8c8e75f6c82b208c3cf94ea4f9
uses: actions/cache/restore@5a3ec84eff668545956fd18022155c47e93e2684 # v4.2.3
with:
path: |
sas-token
key: sas-key-${{ github.run_number }}-1
path: sas-token
key: sas-key-${{ inputs.target-platform }}-${{ github.run_number }}-1
enableCrossOsArchive: true
- name: Obtain SAS Key
continue-on-error: true
uses: actions/cache/restore@0c45773b623bea8c8e75f6c82b208c3cf94ea4f9
uses: actions/cache/restore@5a3ec84eff668545956fd18022155c47e93e2684 # v4.2.3
with:
path: |
sas-token
key: sas-key-${{ github.run_number }}-${{ github.run_attempt }}
path: sas-token
key: sas-key-${{ inputs.target-platform }}-${{ github.run_number }}-${{ github.run_attempt }}
enableCrossOsArchive: true
- name: Download Src Cache from AKS
# The cache will always exist here as a result of the checkout job
# Either it was uploaded to Azure in the checkout job for this commit
@@ -26,21 +29,31 @@ runs:
timeout_minutes: 30
max_attempts: 3
retry_on: error
shell: bash
command: |
sas_token=$(cat sas-token)
if [ -z $sas-token ]; then
if [ -z "$sas_token" ]; then
echo "SAS Token not found; exiting src cache download early..."
exit 1
else
sas_token=$(jq -r '.sasToken' sas-token)
account_name=$(jq -r '.accountName' sas-token)
if [ "${{ inputs.target-platform }}" = "win" ]; then
azcopy copy --log-level=ERROR \
"https://$account_name.file.core.windows.net/${{ env.AZURE_AKS_WIN_CACHE_SHARE_NAME }}/${{ env.CACHE_PATH }}?$sas_token" $DEPSHASH.tar
else
azcopy copy --log-level=ERROR \
"https://$account_name.file.core.windows.net/${{ env.AZURE_AKS_CACHE_SHARE_NAME }}/${{ env.CACHE_PATH }}?$sas_token" $DEPSHASH.tar
fi
fi
azcopy copy --log-level=ERROR \
"https://${{ env.AZURE_AKS_CACHE_STORAGE_ACCOUNT }}.file.core.windows.net/${{ env.AZURE_AKS_CACHE_SHARE_NAME }}/${{ env.CACHE_PATH }}?$sas_token" $DEPSHASH.tar
env:
AZURE_AKS_CACHE_STORAGE_ACCOUNT: f723719aa87a34622b5f7f3
AZURE_AKS_CACHE_SHARE_NAME: pvc-f6a4089f-b082-4bee-a3f9-c3e1c0c02d8f
AZURE_AKS_CACHE_SHARE_NAME: linux-cache
AZURE_AKS_WIN_CACHE_SHARE_NAME: windows-cache
- name: Clean SAS Key
shell: bash
run: rm -f sas-token
- name: Unzip and Ensure Src Cache
if: ${{ inputs.target-platform == 'macos' }}
shell: bash
run: |
echo "Downloaded cache is $(du -sh $DEPSHASH.tar | cut -f1)"
@@ -68,4 +81,45 @@ runs:
fi
echo "Wiping Electron Directory"
rm -rf src/electron
rm -rf src/electron
- name: Unzip and Ensure Src Cache (Windows)
if: ${{ inputs.target-platform == 'win' }}
shell: powershell
run: |
$src_cache = "$env:DEPSHASH.tar"
$cache_size = $(Get-Item $src_cache).length
Write-Host "Downloaded cache is $cache_size"
if ($cache_size -eq 0) {
Write-Host "Cache is empty - exiting"
exit 1
}
$TEMP_DIR=New-Item -ItemType Directory -Path temp-cache
$TEMP_DIR_PATH = $TEMP_DIR.FullName
C:\ProgramData\Chocolatey\bin\7z.exe -y -snld20 x $src_cache -o"$TEMP_DIR_PATH"
- name: Move Src Cache (Windows)
if: ${{ inputs.target-platform == 'win' }}
uses: nick-fields/retry@7152eba30c6575329ac0576536151aca5a72780e # v3.0.0
with:
timeout_minutes: 30
max_attempts: 3
retry_on: error
shell: powershell
command: |
if (Test-Path "temp-cache\src") {
Write-Host "Relocating Cache"
Remove-Item -Recurse -Force src
Move-Item temp-cache\src src
Write-Host "Deleting zip file"
Remove-Item -Force $src_cache
}
if (-Not (Test-Path "src\third_party\blink")) {
Write-Host "Cache was not correctly restored - exiting"
exit 1
}
Write-Host "Wiping Electron Directory"
Remove-Item -Recurse -Force src\electron

View File

@@ -0,0 +1,58 @@
name: 'Set Chromium Git Cookie'
description: 'Sets an authenticated cookie from Chromium to allow for a higher request limit'
runs:
using: "composite"
steps:
- name: Set the git cookie from chromium.googlesource.com (Unix)
if: ${{ runner.os != 'Windows' }}
shell: bash
run: |
if [[ -z "${{ env.CHROMIUM_GIT_COOKIE }}" ]]; then
echo "CHROMIUM_GIT_COOKIE is not set - cannot authenticate."
exit 0
fi
eval 'set +o history' 2>/dev/null || setopt HIST_IGNORE_SPACE 2>/dev/null
touch ~/.gitcookies
chmod 0600 ~/.gitcookies
git config --global http.cookiefile ~/.gitcookies
tr , \\t <<\__END__ >>~/.gitcookies
${{ env.CHROMIUM_GIT_COOKIE }}
__END__
eval 'set -o history' 2>/dev/null || unsetopt HIST_IGNORE_SPACE 2>/dev/null
RESPONSE=$(curl -s -b ~/.gitcookies https://chromium-review.googlesource.com/a/accounts/self)
if [[ $RESPONSE == ")]}'"* ]]; then
# Extract account email for verification
EMAIL=$(echo "$RESPONSE" | tail -c +5 | jq -r '.email // "No email found"')
echo "Cookie authentication successful - authenticated as: $EMAIL"
else
echo "Cookie authentication failed - ensure CHROMIUM_GIT_COOKIE is set correctly"
echo $RESPONSE
fi
- name: Set the git cookie from chromium.googlesource.com (Windows)
if: ${{ runner.os == 'Windows' }}
shell: cmd
run: |
if "%CHROMIUM_GIT_COOKIE_WINDOWS_STRING%"=="" (
echo CHROMIUM_GIT_COOKIE_WINDOWS_STRING is not set - cannot authenticate.
exit /b 0
)
git config --global http.cookiefile "%USERPROFILE%\.gitcookies"
powershell -noprofile -nologo -command Write-Output "${{ env.CHROMIUM_GIT_COOKIE_WINDOWS_STRING }}" >>"%USERPROFILE%\.gitcookies"
curl -s -b "%USERPROFILE%\.gitcookies" https://chromium-review.googlesource.com/a/accounts/self > response.txt
findstr /B /C:")]}'" response.txt > nul
if %ERRORLEVEL% EQU 0 (
echo Cookie authentication successful
powershell -NoProfile -Command "& {$content = Get-Content -Raw response.txt; $content = $content.Substring(4); try { $json = ConvertFrom-Json $content; if($json.email) { Write-Host 'Authenticated as:' $json.email } else { Write-Host 'No email found in response' } } catch { Write-Host 'Error parsing JSON:' $_ }}"
) else (
echo Cookie authentication failed - ensure CHROMIUM_GIT_COOKIE_WINDOWS_STRING is set correctly
type response.txt
)
del response.txt

20
.github/actions/ssh-debug/action.yml vendored Normal file
View File

@@ -0,0 +1,20 @@
name: Debug via SSH
description: Setup a SSH server with a tunnel to access it to debug via SSH.
inputs:
tunnel:
description: 'Enable SSH tunneling via cloudflared'
required: true
default: 'false'
timeout:
description: 'SSH session timeout in seconds'
required: false
type: number
default: 3600
runs:
using: composite
steps:
- run: $GITHUB_ACTION_PATH/setup-ssh.sh
shell: bash
env:
TUNNEL: ${{ inputs.tunnel }}
TIMEOUT: ${{ inputs.timeout }}

4
.github/actions/ssh-debug/bashrc vendored Normal file
View File

@@ -0,0 +1,4 @@
# If we're in an interactive SSH session and we're not already in tmux and there's no explicit SSH command, auto attach tmux
if [ -n "$SSH_TTY" ] && [ -z "$TMUX" ] && [ -z "$SSH_ORIGINAL_COMMAND" ]; then
exec tmux attach || exec tmux
fi

146
.github/actions/ssh-debug/setup-ssh.sh vendored Executable file
View File

@@ -0,0 +1,146 @@
#!/bin/bash -e
if [ "${TUNNEL}" != "true" ]; then
echo "SSH tunneling is disabled. Set enable-tunnel: true to enable remote access."
echo "Local SSH server would be available on localhost:2222 if this were a local environment."
exit 0
fi
echo ::group::Configuring Tunnel
echo "SSH tunneling enabled. Setting up remote access..."
EXTERNAL_DEPS="curl jq ssh-keygen"
for dep in $EXTERNAL_DEPS; do
if ! command -v "${dep}" > /dev/null 2>&1; then
echo "Command ${dep} not installed on the system!" >&2
exit 1
fi
done
cd "$GITHUB_ACTION_PATH"
bashrc_path=$(pwd)/bashrc
# Source `bashrc` to auto start tmux on SSH login.
if ! grep -q "${bashrc_path}" ~/.bash_profile; then
echo >> ~/.bash_profile # On macOS runner there's no newline at the end of the file
echo "source \"${bashrc_path}\"" >> ~/.bash_profile
fi
OS=$(uname -s | tr '[:upper:]' '[:lower:]')
ARCH=$(uname -m)
if [ "${ARCH}" = "x86_64" ]; then
ARCH="amd64"
elif [ "${ARCH}" = "aarch64" ]; then
ARCH="arm64"
fi
if [ "${OS}" = "darwin" ] && ! command -v tmux > /dev/null 2>&1; then
echo "Installing tmux..."
brew install tmux
fi
if [ "$OS" = "darwin" ]; then
cloudflared_url="https://github.com/cloudflare/cloudflared/releases/latest/download/cloudflared-${OS}-${ARCH}.tgz"
echo "Downloading \`cloudflared\` from <$cloudflared_url>..."
curl --location --silent --output cloudflared.tgz "${cloudflared_url}"
tar xf cloudflared.tgz
rm cloudflared.tgz
fi
chmod +x cloudflared
echo 'Creating SSH server key...'
ssh-keygen -q -f ssh_host_rsa_key -N ''
echo 'Creating SSH server config...'
sed "s,\$PWD,${PWD},;s,\$USER,${USER}," sshd_config.template > sshd_config
echo 'Starting SSH server...'
sudo /usr/sbin/sshd -f sshd_config -D &
sshd_pid=$!
echo "SSH server started successfully (PID: ${sshd_pid})"
echo 'Starting tmux session...'
(cd "${GITHUB_WORKSPACE}" && tmux new-session -d -s debug)
mkdir ~/.cloudflared
CLEAN_TUNNEL_CERT=$(printf '%s\n' "${CLOUDFLARE_TUNNEL_CERT}" | tr -d '\r' | sed '/^[[:space:]]*$/d')
echo "${CLEAN_TUNNEL_CERT}" > ~/.cloudflared/cert.pem
CLEAN_USER_CA_CERT=$(printf '%s\n' "${CLOUDFLARE_USER_CA_CERT}" | tr -d '\r' | sed '/^[[:space:]]*$/d')
echo "${CLEAN_USER_CA_CERT}" | sudo tee /etc/ssh/ca.pub > /dev/null
sudo chmod 644 /etc/ssh/ca.pub
random_suffix=$(openssl rand -hex 5 | cut -c1-10)
tunnel_name="${GITHUB_SHA}-${GITHUB_RUN_ID}-${random_suffix}"
tunnel_url="${tunnel_name}.${CLOUDFLARE_TUNNEL_HOSTNAME}"
if ./cloudflared tunnel list | grep -q "${tunnel_name}"; then
echo "Deleting existing tunnel: ${tunnel_name}"
./cloudflared tunnel delete ${tunnel_name}
fi
echo "Creating new cloudflare tunnel: ${tunnel_name}"
./cloudflared tunnel create ${tunnel_name}
credentials_file=$(find ~/.cloudflared -name "*.json" | head -n 1)
if [ -z "${credentials_file}" ]; then
echo "Error: Could not find tunnel credentials file"
exit 1
fi
echo "Found credentials file: ${credentials_file}"
echo 'Creating tunnel configuration...'
cat > tunnel_config.yml << EOF
tunnel: ${tunnel_name}
credentials-file: ${credentials_file}
ingress:
- hostname: ${tunnel_url}
service: ssh://localhost:2222
- service: http_status:404
EOF
echo 'Setting up DNS routing for tunnel...'
./cloudflared tunnel route dns ${tunnel_name} ${tunnel_url}
echo 'Running cloudflare tunnel...'
./cloudflared tunnel --no-autoupdate --config tunnel_config.yml run 2>&1 | tee cloudflared.log | sed -u 's/^/cloudflared: /' &
cloudflared_pid=$!
echo ::endgroup::
echo ::notice title=SSH Debug Session Ready::ssh ${tunnel_url}
(
echo ' '
echo ' '
echo '🔗 SSH Debug Session Ready!'
echo '━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━'
echo ' '
echo '📋 Infra WG can copy and run this command to connect:'
echo ' '
echo "ssh ${tunnel_url}"
echo ' '
echo "⏰ Session expires automatically in ${TIMEOUT} seconds"
echo '━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━'
echo ' '
echo ' '
) | cat
echo ::group::Starting Background Session
echo 'Starting SSH session in background...'
./ssh-session.sh "${sshd_pid}" "${cloudflared_pid}" "${TIMEOUT}" "${tunnel_name}" &
echo 'SSH session is running in background. GitHub Action will continue.'
echo 'Session will auto-cleanup after timeout or when processes end.'
echo ::endgroup::

52
.github/actions/ssh-debug/ssh-session.sh vendored Executable file
View File

@@ -0,0 +1,52 @@
#!/bin/bash
SSHD_PID=$1
CLOUDFLARED_PID=$2
SESSION_TIMEOUT=${3:-10000}
TUNNEL_NAME=$4
cleanup() {
# Kill processes.
for pid in "$SLEEP_PID" "$SSHD_PID" "$CLOUDFLARED_PID"; do
if [ -n "$pid" ] && kill -0 "$pid" 2>/dev/null; then
kill "$pid" 2>/dev/null || true
fi
done
# Clean up tunnel.
if [ -n "$TUNNEL_NAME" ]; then
cd "$GITHUB_ACTION_PATH"
./cloudflared tunnel delete "$TUNNEL_NAME" 2>/dev/null || {
echo "Failed to delete tunnel"
}
fi
echo "Session ended at $(date)"
exit 0
}
# Trap signals to ensure cleanup.
trap cleanup SIGTERM SIGINT SIGQUIT SIGHUP EXIT
# Wait for timeout or until processes die.
sleep "$SESSION_TIMEOUT" &
SLEEP_PID=$!
# Monitor processes
while kill -0 "$SLEEP_PID" 2>/dev/null; do
# Check SSH daemon.
if ! kill -0 "$SSHD_PID" 2>/dev/null; then
echo "SSH daemon died at $(date)"
break
fi
# Check cloudflared,
if ! kill -0 "$CLOUDFLARED_PID" 2>/dev/null; then
echo "Cloudflared died at $(date)"
break
fi
sleep 10
done
cleanup

View File

@@ -0,0 +1,25 @@
Port 2222
HostKey $PWD/ssh_host_rsa_key
PidFile $PWD/sshd.pid
# Connection settings
ClientAliveInterval 30
ClientAliveCountMax 10
MaxStartups 10
LoginGraceTime 120
# Allow TCP forwarding for tunneling
AllowTcpForwarding yes
# Try to prevent timeouts
TCPKeepAlive yes
# Security
TrustedUserCAKeys /etc/ssh/ca.pub
PubkeyAuthentication yes
PasswordAuthentication no
AuthorizedPrincipalsCommand /bin/bash -c "echo '%t %k' | ssh-keygen -L -f - | grep -A1 Principals"
AuthorizedPrincipalsCommandUser nobody
PubkeyAcceptedKeyTypes ssh-rsa,ssh-ed25519,ecdsa-sha2-nistp256,ecdsa-sha2-nistp384,ecdsa-sha2-nistp521,ssh-ed25519-cert-v01@openssh.com,ecdsa-sha2-nistp256-cert-v01@openssh.com,ecdsa-sha2-nistp384-cert-v01@openssh.com,ecdsa-sha2-nistp521-cert-v01@openssh.com,rsa-sha2-256-cert-v01@openssh.com,rsa-sha2-512-cert-v01@openssh.com

18
.github/problem-matchers/clang.json vendored Normal file
View File

@@ -0,0 +1,18 @@
{
"problemMatcher": [
{
"owner": "clang",
"fromPath": "src/out/Default/args.gn",
"pattern": [
{
"regexp": "^(.+)[(:](\\d+)[:,](\\d+)\\)?:\\s+(warning|error):\\s+(.*)$",
"file": 1,
"line": 2,
"column": 3,
"severity": 4,
"message": 5
}
]
}
]
}

View File

@@ -0,0 +1,22 @@
{
"problemMatcher": [
{
"owner": "eslint-stylish",
"pattern": [
{
"regexp": "^\\s*([^\\s].*)$",
"file": 1
},
{
"regexp": "^\\s+(\\d+):(\\d+)\\s+(error|warning|info)\\s+(.*)\\s\\s+(.*)$",
"line": 1,
"column": 2,
"severity": 3,
"message": 4,
"code": 5,
"loop": true
}
]
}
]
}

View File

@@ -0,0 +1,16 @@
{
"problemMatcher": [
{
"owner": "markdownlint",
"pattern": [
{
"regexp": "^(.+):(\\d+):(\\d+)\\s+(.*)$",
"file": 1,
"line": 2,
"column": 3,
"message": 4
}
]
}
]
}

View File

@@ -0,0 +1,34 @@
{
"problemMatcher": [
{
"owner": "merge-conflict",
"pattern": [
{
"regexp": "^CONFLICT\\s\\(\\S+\\): (Merge conflict in \\S+)$",
"message": 1
}
]
},
{
"owner": "patch-conflict",
"pattern": [
{
"regexp": "^error: (patch failed: (\\S+):(\\d+))$",
"message": 1,
"file": 2,
"line": 3
}
]
},
{
"owner": "patch-needs-update",
"pattern": [
{
"regexp": "^((patches\/.*): needs update)$",
"message": 1,
"file": 2
}
]
}
]
}

73
.github/workflows/apply-patches.yml vendored Normal file
View File

@@ -0,0 +1,73 @@
name: Apply Patches
on:
pull_request:
permissions: {}
concurrency:
group: apply-patches-${{ github.ref }}
cancel-in-progress: true
jobs:
setup:
if: github.repository == 'electron/electron'
runs-on: ubuntu-slim
permissions:
contents: read
pull-requests: read
outputs:
has-patches: ${{ steps.filter.outputs.patches }}
steps:
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd
with:
persist-credentials: false
ref: ${{ github.event.pull_request.head.sha }}
# Use dorny/paths-filter instead of the path filter under the on: pull_request: block
# so that the output can be used to conditionally run the apply-patches job, which lets
# the job be marked as a required status check (conditional skip counts as a success).
- uses: dorny/paths-filter@de90cc6fb38fc0963ad72b210f1f284cd68cea36 # v3.0.2
id: filter
with:
filters: |
patches:
- DEPS
- 'patches/**'
apply-patches:
needs: setup
if: ${{ needs.setup.outputs.has-patches == 'true' }}
runs-on: electron-arc-centralus-linux-amd64-32core
permissions:
contents: read
container:
image: ghcr.io/electron/build:a82b87d7a4f5ff0cab61405f8151ac4cf4942aeb
options: --user root
volumes:
- /mnt/cross-instance-cache:/mnt/cross-instance-cache
- /var/run/sas:/var/run/sas
env:
CHROMIUM_GIT_COOKIE: ${{ secrets.CHROMIUM_GIT_COOKIE }}
GCLIENT_EXTRA_ARGS: '--custom-var=checkout_arm=True --custom-var=checkout_arm64=True'
steps:
- name: Checkout Electron
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd
with:
path: src/electron
fetch-depth: 0
persist-credentials: false
ref: ${{ github.event.pull_request.base.ref }}
- name: Merge PR HEAD
working-directory: src/electron
env:
PR_NUMBER: ${{ github.event.pull_request.number }}
run: |
git config user.email "electron@github.com"
git config user.name "Electron Bot"
git fetch origin refs/pull/${PR_NUMBER}/head
git merge --squash FETCH_HEAD
git commit -n -m "Squashed commits"
- name: Checkout & Sync & Save
uses: ./src/electron/.github/actions/checkout
with:
target-platform: linux

View File

@@ -3,19 +3,23 @@ name: Archaeologist
on:
pull_request:
permissions: {}
jobs:
archaeologist-dig:
name: Archaeologist Dig
runs-on: ubuntu-latest
permissions:
contents: read
steps:
- name: Checkout Electron
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 #v4.0.2
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd
with:
fetch-depth: 0
- name: Setup Node.js/npm
uses: actions/setup-node@39370e3970a6d050c480ffad4ff0ed4d3fdee5af
uses: actions/setup-node@6044e13b5dc448c55e2357c09f80417699197238
with:
node-version: 20.11.x
node-version: 24.12.x
- name: Setting Up Dig Site
run: |
echo "remote: ${{ github.event.pull_request.head.repo.clone_url }}"
@@ -41,7 +45,7 @@ jobs:
sha-file: .dig-old
filename: electron.old.d.ts
- name: Upload artifacts
uses: actions/upload-artifact@b4b15b8c7c6ac21ea08fcf65892d2ee8f75cf882 #v4.4.3
uses: actions/upload-artifact@b7c566a772e6b6bfb58ed0dc250532a479d7789f #v6.0.0
with:
name: artifacts
path: electron/artifacts

162
.github/workflows/audit-branch-ci.yml vendored Normal file
View File

@@ -0,0 +1,162 @@
name: Audit CI on Branches
on:
workflow_dispatch:
schedule:
# Run every 2 hours
- cron: '0 */2 * * *'
permissions: {}
jobs:
audit_branch_ci:
name: Audit CI on Branches
if: github.repository == 'electron/electron'
runs-on: ubuntu-latest
permissions:
contents: read
steps:
- name: Setup Node.js
uses: actions/setup-node@6044e13b5dc448c55e2357c09f80417699197238 # v6.2.0
with:
node-version: 22.17.x
- name: Sparse checkout repository
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
with:
sparse-checkout: |
.
.github
.yarn
- run: yarn workspaces focus @electron/gha-workflows
- uses: actions/github-script@ed597411d8f924073f98dfc5c65a23a2325f34cd # v8.0.0
id: audit-errors
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
script: |
const { chdir } = require('node:process');
chdir('${{ github.workspace }}/.github/workflows');
const cache = require('@actions/cache');
const { ElectronVersions } = require('@electron/fiddle-core');
const runsWithErrors = [];
// Only want the most recent workflow run that wasn't skipped or cancelled
const isValidWorkflowRun = (run) => !['skipped', 'cancelled'].includes(run.conclusion);
const versions = await ElectronVersions.create({ ignoreCache: true });
const branches = versions.supportedMajors.map((branch) => `${branch}-x-y`);
for (const branch of ["main", ...branches]) {
const latestCheckRuns = new Map();
const allCheckRuns = await github.paginate(github.rest.checks.listForRef, {
owner: "electron",
repo: "electron",
ref: branch,
status: 'completed',
});
// Sort the check runs by completed_at so that multiple check runs on the
// same ref (like a scheduled workflow) only looks at the most recent one
for (const checkRun of allCheckRuns.filter(
(run) => !['skipped', 'cancelled'].includes(run.conclusion),
).sort((a, b) => new Date(b.completed_at) - new Date(a.completed_at))) {
if (!latestCheckRuns.has(checkRun.name)) {
latestCheckRuns.set(checkRun.name, checkRun);
}
}
// Check for runs which had error annotations
for (const checkRun of Array.from(latestCheckRuns.values())) {
if (checkRun.name === "Audit CI on Branches") {
continue; // Skip the audit workflow itself
}
const annotations = (await github.rest.checks.listAnnotations({
owner: "electron",
repo: "electron",
check_run_id: checkRun.id,
})).data ?? [];
if (
annotations.find(
({ annotation_level, message }) =>
annotation_level === "failure" &&
!message.startsWith("Process completed with exit code") &&
!message.startsWith("Response status code does not indicate success") &&
!message.startsWith("The hosted runner lost communication with the server") &&
!message.startsWith("Dependabot encountered an error performing the update") &&
!/Unable to make request/.test(message) &&
!/The requested URL returned error/.test(message),
)
) {
checkRun.hasErrorAnnotations = true;
} else {
continue;
}
// Check if this is a known failure from a previous audit run
const cacheKey = `check-run-error-annotations-${checkRun.id}`;
const cacheHit =
(await cache.restoreCache(['/dev/null'], cacheKey, undefined, {
lookupOnly: true,
})) !== undefined;
if (cacheHit) {
checkRun.isStale = true;
}
checkRun.branch = branch;
runsWithErrors.push(checkRun);
// Create a cache entry (only the name matters) to keep track of
// failures we've seen from previous runs to mark them as stale
if (!cacheHit) {
await cache.saveCache(['/dev/null'], cacheKey);
}
}
}
if (runsWithErrors.length > 0) {
core.summary.addHeading('⚠️ Runs with Errors');
core.summary.addTable([
[
{ data: 'Branch', header: true },
{ data: 'Workflow Run', header: true },
{ data: 'Status', header: true },
],
...runsWithErrors
.sort(
(a, b) =>
a.branch.localeCompare(b.branch) ||
a.name.localeCompare(b.name),
)
.map((run) => [
run.branch,
`<a href="${run.html_url}">${run.name}</a>`,
run.isStale
? '📅 Stale'
: run.hasErrorAnnotations
? '⚠️ Errors'
: '✅ Succeeded',
]),
]);
// Set this as failed so it's easy to scan runs to find failures
if (runsWithErrors.find((run) => !run.isStale)) {
core.setOutput('errorsFound', true);
process.exitCode = 1;
}
} else {
core.summary.addRaw('🎉 No runs with errors');
}
await core.summary.write();
- name: Send Slack message if errors
if: ${{ always() && steps.audit-errors.outputs.errorsFound && github.ref == 'refs/heads/main' }}
uses: slackapi/slack-github-action@91efab103c0de0a537f72a35f6b8cda0ee76bf0a # v2.1.1
with:
payload: |
link: "https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}"
webhook: ${{ secrets.CI_ERRORS_SLACK_WEBHOOK_URL }}
webhook-type: webhook-trigger

View File

@@ -14,7 +14,7 @@ permissions: {}
jobs:
release-branch-created:
name: Release Branch Created
if: ${{ github.event_name == 'workflow_dispatch' || (github.event.ref_type == 'branch' && endsWith(github.event.ref, '-x-y') && !startsWith(github.event.ref, 'roller')) }}
if: ${{ github.repository == 'electron/electron' && (github.event_name == 'workflow_dispatch' || (github.event.ref_type == 'branch' && endsWith(github.event.ref, '-x-y') && !startsWith(github.event.ref, 'roller'))) }}
permissions:
contents: read
pull-requests: write
@@ -68,14 +68,14 @@ jobs:
done
- name: Generate GitHub App token
if: ${{ steps.check-major-version.outputs.MAJOR }}
uses: electron/github-app-auth-action@384fd19694fe7b6dcc9a684746c6976ad78228ae # v1.1.1
uses: electron/github-app-auth-action@e14e47722ed120360649d0789e25b9baece12725 # v2.0.0
id: generate-token
with:
creds: ${{ secrets.RELEASE_BOARD_GH_APP_CREDS }}
org: electron
- name: Generate Release Project Board Metadata
if: ${{ steps.check-major-version.outputs.MAJOR }}
uses: actions/github-script@60a0d83039c74a4aee543508d2ffcb1c3799cdea # v7.0.1
uses: actions/github-script@ed597411d8f924073f98dfc5c65a23a2325f34cd # v8.0.0
id: generate-project-metadata
with:
script: |
@@ -94,7 +94,7 @@ jobs:
}))
- name: Create Release Project Board
if: ${{ steps.check-major-version.outputs.MAJOR }}
uses: dsanders11/project-actions/copy-project@438b25e007c2f4efec324497fadc6402e7cc61a6 # v1.4.0
uses: dsanders11/project-actions/copy-project@2134fe7cc71c58b7ae259c82a8e63c6058255678 # v1.7.0
id: create-release-board
with:
drafts: true
@@ -114,14 +114,15 @@ jobs:
GITHUB_TOKEN: ${{ steps.generate-token.outputs.token }}
- name: Find Previous Release Project Board
if: ${{ steps.check-major-version.outputs.MAJOR }}
uses: dsanders11/project-actions/find-project@438b25e007c2f4efec324497fadc6402e7cc61a6 # v1.4.0
uses: dsanders11/project-actions/find-project@2134fe7cc71c58b7ae259c82a8e63c6058255678 # v1.7.0
id: find-prev-release-board
with:
fail-if-project-not-found: false
title: ${{ steps.generate-project-metadata.outputs.prev-prev-major }}-x-y
token: ${{ steps.generate-token.outputs.token }}
- name: Close Previous Release Project Board
if: ${{ steps.check-major-version.outputs.MAJOR }}
uses: dsanders11/project-actions/close-project@438b25e007c2f4efec324497fadc6402e7cc61a6 # v1.4.0
if: ${{ steps.find-prev-release-board.outputs.number }}
uses: dsanders11/project-actions/close-project@2134fe7cc71c58b7ae259c82a8e63c6058255678 # v1.7.0
with:
project-number: ${{ steps.find-prev-release-board.outputs.number }}
token: ${{ steps.generate-token.outputs.token }}

85
.github/workflows/build-git-cache.yml vendored Normal file
View File

@@ -0,0 +1,85 @@
name: Build Git Cache
# This workflow updates git cache on the cross-instance cache volumes
# It runs daily at midnight.
on:
schedule:
- cron: "0 0 * * *"
permissions: {}
jobs:
build-git-cache-linux:
if: github.repository == 'electron/electron'
runs-on: electron-arc-centralus-linux-amd64-32core
permissions:
contents: read
container:
image: ghcr.io/electron/build:a82b87d7a4f5ff0cab61405f8151ac4cf4942aeb
options: --user root
volumes:
- /mnt/cross-instance-cache:/mnt/cross-instance-cache
env:
CHROMIUM_GIT_COOKIE: ${{ secrets.CHROMIUM_GIT_COOKIE }}
GCLIENT_EXTRA_ARGS: '--custom-var=checkout_arm=True --custom-var=checkout_arm64=True'
steps:
- name: Checkout Electron
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd
with:
path: src/electron
fetch-depth: 0
- name: Build Git Cache
uses: ./src/electron/.github/actions/build-git-cache
with:
target-platform: linux
build-git-cache-windows:
if: github.repository == 'electron/electron'
runs-on: electron-arc-centralus-linux-amd64-32core
permissions:
contents: read
container:
image: ghcr.io/electron/build:a82b87d7a4f5ff0cab61405f8151ac4cf4942aeb
options: --user root --device /dev/fuse --cap-add SYS_ADMIN
volumes:
- /mnt/win-cache:/mnt/win-cache
env:
CHROMIUM_GIT_COOKIE: ${{ secrets.CHROMIUM_GIT_COOKIE }}
GCLIENT_EXTRA_ARGS: '--custom-var=checkout_win=True'
TARGET_OS: 'win'
steps:
- name: Checkout Electron
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd
with:
path: src/electron
fetch-depth: 0
- name: Build Git Cache
uses: ./src/electron/.github/actions/build-git-cache
with:
target-platform: win
build-git-cache-macos:
if: github.repository == 'electron/electron'
runs-on: electron-arc-centralus-linux-amd64-32core
permissions:
contents: read
# This job updates the same git cache as linux, so it needs to run after the linux one.
needs: build-git-cache-linux
container:
image: ghcr.io/electron/build:a82b87d7a4f5ff0cab61405f8151ac4cf4942aeb
options: --user root
volumes:
- /mnt/cross-instance-cache:/mnt/cross-instance-cache
env:
CHROMIUM_GIT_COOKIE: ${{ secrets.CHROMIUM_GIT_COOKIE }}
GCLIENT_EXTRA_ARGS: '--custom-var=checkout_mac=True --custom-var=host_os=mac'
steps:
- name: Checkout Electron
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd
with:
path: src/electron
fetch-depth: 0
- name: Build Git Cache
uses: ./src/electron/.github/actions/build-git-cache
with:
target-platform: macos

View File

@@ -6,7 +6,7 @@ on:
build-image-sha:
type: string
description: 'SHA for electron/build image'
default: 'bc2f48b2415a670de18d13605b1cf0eb5fdbaae1'
default: 'a82b87d7a4f5ff0cab61405f8151ac4cf4942aeb'
required: true
skip-macos:
type: boolean
@@ -28,6 +28,11 @@ on:
description: 'Skip lint check'
default: false
required: false
enable-ssh:
description: 'Enable SSH debugging'
required: false
type: boolean
default: false
push:
branches:
- main
@@ -38,10 +43,14 @@ defaults:
run:
shell: bash
permissions: {}
jobs:
setup:
if: github.repository == 'electron/electron'
runs-on: ubuntu-latest
permissions:
contents: read
pull-requests: read
outputs:
docs: ${{ steps.filter.outputs.docs }}
@@ -49,7 +58,7 @@ jobs:
build-image-sha: ${{ steps.set-output.outputs.build-image-sha }}
docs-only: ${{ steps.set-output.outputs.docs-only }}
steps:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 #v4.0.2
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd
with:
ref: ${{ github.event.pull_request.head.sha }}
- uses: dorny/paths-filter@de90cc6fb38fc0963ad72b210f1f284cd68cea36 # v3.0.2
@@ -58,13 +67,17 @@ jobs:
filters: |
docs:
- 'docs/**'
- README.md
- SECURITY.md
- CONTRIBUTING.md
- CODE_OF_CONDUCT.md
src:
- '!docs/**'
- name: Set Outputs for Build Image SHA & Docs Only
id: set-output
run: |
if [ -z "${{ inputs.build-image-sha }}" ]; then
echo "build-image-sha=bc2f48b2415a670de18d13605b1cf0eb5fdbaae1" >> "$GITHUB_OUTPUT"
echo "build-image-sha=a82b87d7a4f5ff0cab61405f8151ac4cf4942aeb" >> "$GITHUB_OUTPUT"
else
echo "build-image-sha=${{ inputs.build-image-sha }}" >> "$GITHUB_OUTPUT"
fi
@@ -75,24 +88,30 @@ jobs:
needs: setup
if: ${{ !inputs.skip-lint }}
uses: ./.github/workflows/pipeline-electron-lint.yml
permissions:
contents: read
with:
container: '{"image":"ghcr.io/electron/build:${{ needs.setup.outputs.build-image-sha }}","options":"--user root"}'
secrets: inherit
# Docs Only Jobs
docs-only:
needs: setup
needs: [setup, checkout-linux]
if: ${{ needs.setup.outputs.docs-only == 'true' }}
uses: ./.github/workflows/pipeline-electron-docs-only.yml
permissions:
contents: read
with:
container: '{"image":"ghcr.io/electron/build:${{ needs.setup.outputs.build-image-sha }}","options":"--user root"}'
container: '{"image":"ghcr.io/electron/build:${{ needs.checkout-linux.outputs.build-image-sha }}","options":"--user root","volumes":["/mnt/cross-instance-cache:/mnt/cross-instance-cache"]}'
secrets: inherit
# Checkout Jobs
checkout-macos:
needs: setup
if: ${{ needs.setup.outputs.src == 'true' && !inputs.skip-macos}}
runs-on: electron-arc-linux-amd64-32core
runs-on: electron-arc-centralus-linux-amd64-32core
permissions:
contents: read
container:
image: ghcr.io/electron/build:${{ needs.setup.outputs.build-image-sha }}
options: --user root
@@ -100,12 +119,13 @@ jobs:
- /mnt/cross-instance-cache:/mnt/cross-instance-cache
- /var/run/sas:/var/run/sas
env:
CHROMIUM_GIT_COOKIE: ${{ secrets.CHROMIUM_GIT_COOKIE }}
GCLIENT_EXTRA_ARGS: '--custom-var=checkout_mac=True --custom-var=host_os=mac'
outputs:
build-image-sha: ${{ needs.setup.outputs.build-image-sha }}
steps:
- name: Checkout Electron
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd
with:
path: src/electron
fetch-depth: 0
@@ -114,11 +134,14 @@ jobs:
uses: ./src/electron/.github/actions/checkout
with:
generate-sas-token: 'true'
target-platform: macos
checkout-linux:
needs: setup
if: ${{ needs.setup.outputs.src == 'true' && !inputs.skip-linux}}
runs-on: electron-arc-linux-amd64-32core
if: ${{ !inputs.skip-linux}}
runs-on: electron-arc-centralus-linux-amd64-32core
permissions:
contents: read
container:
image: ghcr.io/electron/build:${{ needs.setup.outputs.build-image-sha }}
options: --user root
@@ -126,30 +149,39 @@ jobs:
- /mnt/cross-instance-cache:/mnt/cross-instance-cache
- /var/run/sas:/var/run/sas
env:
CHROMIUM_GIT_COOKIE: ${{ secrets.CHROMIUM_GIT_COOKIE }}
DD_API_KEY: ${{ secrets.DD_API_KEY }}
GCLIENT_EXTRA_ARGS: '--custom-var=checkout_arm=True --custom-var=checkout_arm64=True'
PATCH_UP_APP_CREDS: ${{ secrets.PATCH_UP_APP_CREDS }}
outputs:
build-image-sha: ${{ needs.setup.outputs.build-image-sha}}
steps:
- name: Checkout Electron
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd
with:
path: src/electron
fetch-depth: 0
ref: ${{ github.event.pull_request.head.sha }}
- name: Checkout & Sync & Save
uses: ./src/electron/.github/actions/checkout
with:
target-platform: linux
checkout-windows:
needs: setup
if: ${{ needs.setup.outputs.src == 'true' && !inputs.skip-windows }}
runs-on: electron-arc-linux-amd64-32core
runs-on: electron-arc-centralus-linux-amd64-32core
permissions:
contents: read
container:
image: ghcr.io/electron/build:${{ needs.setup.outputs.build-image-sha }}
options: --user root --device /dev/fuse --cap-add SYS_ADMIN
volumes:
- /mnt/cross-instance-cache:/mnt/cross-instance-cache
- /mnt/win-cache:/mnt/win-cache
- /var/run/sas:/var/run/sas
env:
CHROMIUM_GIT_COOKIE: ${{ secrets.CHROMIUM_GIT_COOKIE }}
CHROMIUM_GIT_COOKIE_WINDOWS_STRING: ${{ secrets.CHROMIUM_GIT_COOKIE_WINDOWS_STRING }}
GCLIENT_EXTRA_ARGS: '--custom-var=checkout_win=True'
TARGET_OS: 'win'
ELECTRON_DEPOT_TOOLS_WIN_TOOLCHAIN: '1'
@@ -157,44 +189,54 @@ jobs:
build-image-sha: ${{ needs.setup.outputs.build-image-sha}}
steps:
- name: Checkout Electron
uses: actions/checkout@a5ac7e51b41094c92402da3b24376905380afc29
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd
with:
path: src/electron
fetch-depth: 0
ref: ${{ github.event.pull_request.head.sha }}
- name: Checkout & Sync & Save
uses: ./src/electron/.github/actions/checkout
with:
generate-sas-token: 'true'
target-platform: win
# GN Check Jobs
macos-gn-check:
uses: ./.github/workflows/pipeline-segment-electron-gn-check.yml
permissions:
contents: read
needs: checkout-macos
with:
target-platform: macos
target-archs: x64 arm64
check-runs-on: macos-14
check-runs-on: macos-15
gn-build-type: testing
secrets: inherit
linux-gn-check:
uses: ./.github/workflows/pipeline-segment-electron-gn-check.yml
permissions:
contents: read
needs: checkout-linux
if: ${{ needs.setup.outputs.src == 'true' }}
with:
target-platform: linux
target-archs: x64 arm arm64
check-runs-on: electron-arc-linux-amd64-8core
check-runs-on: electron-arc-centralus-linux-amd64-8core
check-container: '{"image":"ghcr.io/electron/build:${{ needs.checkout-linux.outputs.build-image-sha }}","options":"--user root","volumes":["/mnt/cross-instance-cache:/mnt/cross-instance-cache"]}'
gn-build-type: testing
secrets: inherit
windows-gn-check:
uses: ./.github/workflows/pipeline-segment-electron-gn-check.yml
permissions:
contents: read
needs: checkout-windows
with:
target-platform: win
target-archs: x64 x86 arm64
check-runs-on: electron-arc-linux-amd64-8core
check-container: '{"image":"ghcr.io/electron/build:${{ needs.checkout-windows.outputs.build-image-sha }}","options":"--user root --device /dev/fuse --cap-add SYS_ADMIN","volumes":["/mnt/cross-instance-cache:/mnt/cross-instance-cache"]}'
check-runs-on: electron-arc-centralus-linux-amd64-8core
check-container: '{"image":"ghcr.io/electron/build:${{ needs.checkout-windows.outputs.build-image-sha }}","options":"--user root --device /dev/fuse --cap-add SYS_ADMIN","volumes":["/mnt/win-cache:/mnt/win-cache"]}'
gn-build-type: testing
secrets: inherit
@@ -207,14 +249,15 @@ jobs:
uses: ./.github/workflows/pipeline-electron-build-and-test.yml
needs: checkout-macos
with:
build-runs-on: macos-14-xlarge
test-runs-on: macos-13
build-runs-on: macos-15-xlarge
test-runs-on: macos-15-large
target-platform: macos
target-arch: x64
is-release: false
gn-build-type: testing
generate-symbols: false
upload-to-storage: '0'
enable-ssh: ${{ inputs.enable-ssh || false }}
secrets: inherit
macos-arm64:
@@ -225,14 +268,15 @@ jobs:
uses: ./.github/workflows/pipeline-electron-build-and-test.yml
needs: checkout-macos
with:
build-runs-on: macos-14-xlarge
test-runs-on: macos-14
build-runs-on: macos-15-xlarge
test-runs-on: macos-15
target-platform: macos
target-arch: arm64
is-release: false
gn-build-type: testing
generate-symbols: false
upload-to-storage: '0'
enable-ssh: ${{ inputs.enable-ssh || false }}
secrets: inherit
linux-x64:
@@ -240,12 +284,15 @@ jobs:
contents: read
issues: read
pull-requests: read
uses: ./.github/workflows/pipeline-electron-build-and-test-and-nan.yml
uses: ./.github/workflows/pipeline-electron-build-and-tidy-and-test-and-nan.yml
needs: checkout-linux
if: ${{ needs.setup.outputs.src == 'true' }}
with:
build-runs-on: electron-arc-linux-amd64-32core
test-runs-on: electron-arc-linux-amd64-4core
build-runs-on: electron-arc-centralus-linux-amd64-32core
clang-tidy-runs-on: electron-arc-centralus-linux-amd64-8core
test-runs-on: electron-arc-centralus-linux-amd64-4core
build-container: '{"image":"ghcr.io/electron/build:${{ needs.checkout-linux.outputs.build-image-sha }}","options":"--user root","volumes":["/mnt/cross-instance-cache:/mnt/cross-instance-cache"]}'
clang-tidy-container: '{"image":"ghcr.io/electron/build:${{ needs.checkout-linux.outputs.build-image-sha }}","options":"--user root","volumes":["/mnt/cross-instance-cache:/mnt/cross-instance-cache"]}'
test-container: '{"image":"ghcr.io/electron/build:${{ needs.checkout-linux.outputs.build-image-sha }}","options":"--user root --privileged --init"}'
target-platform: linux
target-arch: x64
@@ -262,9 +309,10 @@ jobs:
pull-requests: read
uses: ./.github/workflows/pipeline-electron-build-and-test.yml
needs: checkout-linux
if: ${{ needs.setup.outputs.src == 'true' }}
with:
build-runs-on: electron-arc-linux-amd64-32core
test-runs-on: electron-arc-linux-amd64-4core
build-runs-on: electron-arc-centralus-linux-amd64-32core
test-runs-on: electron-arc-centralus-linux-amd64-4core
build-container: '{"image":"ghcr.io/electron/build:${{ needs.checkout-linux.outputs.build-image-sha }}","options":"--user root","volumes":["/mnt/cross-instance-cache:/mnt/cross-instance-cache"]}'
test-container: '{"image":"ghcr.io/electron/build:${{ needs.checkout-linux.outputs.build-image-sha }}","options":"--user root --privileged --init"}'
target-platform: linux
@@ -283,11 +331,12 @@ jobs:
pull-requests: read
uses: ./.github/workflows/pipeline-electron-build-and-test.yml
needs: checkout-linux
if: ${{ needs.setup.outputs.src == 'true' }}
with:
build-runs-on: electron-arc-linux-amd64-32core
test-runs-on: electron-arc-linux-arm64-4core
build-runs-on: electron-arc-centralus-linux-amd64-32core
test-runs-on: electron-arc-centralus-linux-arm64-4core
build-container: '{"image":"ghcr.io/electron/build:${{ needs.checkout-linux.outputs.build-image-sha }}","options":"--user root","volumes":["/mnt/cross-instance-cache:/mnt/cross-instance-cache"]}'
test-container: '{"image":"ghcr.io/electron/test:arm32v7-${{ needs.checkout-linux.outputs.build-image-sha }}","options":"--user root --privileged --init","volumes":["/home/runner/externals:/mnt/runner-externals"]}'
test-container: '{"image":"ghcr.io/electron/test:arm32v7-${{ needs.checkout-linux.outputs.build-image-sha }}","options":"--user root --privileged --init --memory=12g","volumes":["/home/runner/externals:/mnt/runner-externals"]}'
target-platform: linux
target-arch: arm
is-release: false
@@ -303,9 +352,10 @@ jobs:
pull-requests: read
uses: ./.github/workflows/pipeline-electron-build-and-test.yml
needs: checkout-linux
if: ${{ needs.setup.outputs.src == 'true' }}
with:
build-runs-on: electron-arc-linux-amd64-32core
test-runs-on: electron-arc-linux-arm64-4core
build-runs-on: electron-arc-centralus-linux-amd64-32core
test-runs-on: ubuntu-22.04-arm
build-container: '{"image":"ghcr.io/electron/build:${{ needs.checkout-linux.outputs.build-image-sha }}","options":"--user root","volumes":["/mnt/cross-instance-cache:/mnt/cross-instance-cache"]}'
test-container: '{"image":"ghcr.io/electron/test:arm64v8-${{ needs.checkout-linux.outputs.build-image-sha }}","options":"--user root --privileged --init"}'
target-platform: linux
@@ -322,10 +372,10 @@ jobs:
issues: read
pull-requests: read
uses: ./.github/workflows/pipeline-electron-build-and-test.yml
needs: setup
needs: checkout-windows
if: ${{ needs.setup.outputs.src == 'true' && !inputs.skip-windows }}
with:
build-runs-on: electron-arc-windows-amd64-16core
build-runs-on: electron-arc-centralus-windows-amd64-16core
test-runs-on: windows-latest
target-platform: win
target-arch: x64
@@ -341,10 +391,10 @@ jobs:
issues: read
pull-requests: read
uses: ./.github/workflows/pipeline-electron-build-and-test.yml
needs: setup
needs: checkout-windows
if: ${{ needs.setup.outputs.src == 'true' && !inputs.skip-windows }}
with:
build-runs-on: electron-arc-windows-amd64-16core
build-runs-on: electron-arc-centralus-windows-amd64-16core
test-runs-on: windows-latest
target-platform: win
target-arch: x86
@@ -360,11 +410,11 @@ jobs:
issues: read
pull-requests: read
uses: ./.github/workflows/pipeline-electron-build-and-test.yml
needs: setup
needs: checkout-windows
if: ${{ needs.setup.outputs.src == 'true' && !inputs.skip-windows }}
with:
build-runs-on: electron-arc-windows-amd64-16core
test-runs-on: electron-hosted-windows-arm64-4core
build-runs-on: electron-arc-centralus-windows-amd64-16core
test-runs-on: windows-11-arm
target-platform: win
target-arch: arm64
is-release: false
@@ -376,8 +426,10 @@ jobs:
gha-done:
name: GitHub Actions Completed
runs-on: ubuntu-latest
permissions:
contents: read
needs: [docs-only, macos-x64, macos-arm64, linux-x64, linux-x64-asan, linux-arm, linux-arm64, windows-x64, windows-x86, windows-arm64]
if: always() && !contains(needs.*.result, 'failure')
if: always() && github.repository == 'electron/electron' && !contains(needs.*.result, 'failure')
steps:
- name: GitHub Actions Jobs Done
run: |

View File

@@ -1,21 +1,34 @@
name: Clean Source Cache
# Description:
# This workflow cleans up the source cache on the cross-instance cache volume
# to free up space. It runs daily at midnight and clears files older than 15 days.
on:
schedule:
- cron: "0 0 * * SUN" # Run at midnight every Sunday
- cron: "0 0 * * *"
permissions: {}
jobs:
clean-src-cache:
runs-on: electron-arc-linux-amd64-32core
if: github.repository == 'electron/electron'
runs-on: electron-arc-centralus-linux-amd64-32core
permissions:
contents: read
container:
image: ghcr.io/electron/build:bc2f48b2415a670de18d13605b1cf0eb5fdbaae1
options: --user root
volumes:
- /mnt/cross-instance-cache:/mnt/cross-instance-cache
- /mnt/win-cache:/mnt/win-cache
steps:
- name: Cleanup Source Cache
shell: bash
run: |
df -h /mnt/cross-instance-cache
find /mnt/cross-instance-cache -type f -mtime +30 -delete
find /mnt/cross-instance-cache -type f -mtime +15 -delete
df -h /mnt/cross-instance-cache
df -h /mnt/win-cache
find /mnt/win-cache -type f -mtime +15 -delete
df -h /mnt/win-cache

View File

@@ -10,15 +10,24 @@ permissions: {}
jobs:
issue-commented:
name: Remove blocked/{need-info,need-repro} on comment
if: ${{ (contains(github.event.issue.labels.*.name, 'blocked/need-repro') || contains(github.event.issue.labels.*.name, 'blocked/need-info ❌')) && !contains(fromJSON('["MEMBER", "OWNER"]'), github.event.comment.author_association) && github.event.comment.user.type != 'Bot' }}
if: ${{ (contains(github.event.issue.labels.*.name, 'blocked/need-repro') || contains(github.event.issue.labels.*.name, 'blocked/need-info ❌')) && github.event.comment.user.type != 'Bot' }}
runs-on: ubuntu-latest
steps:
- name: Get author association
id: get-author-association
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
AUTHOR_ASSOCIATION=$(gh api /repos/electron/electron/issues/comments/${{ github.event.comment.id }} --jq '.author_association')
echo "author_association=$AUTHOR_ASSOCIATION" >> "$GITHUB_OUTPUT"
- name: Generate GitHub App token
uses: electron/github-app-auth-action@384fd19694fe7b6dcc9a684746c6976ad78228ae # v1.1.1
uses: electron/github-app-auth-action@e14e47722ed120360649d0789e25b9baece12725 # v2.0.0
if: ${{ !contains(fromJSON('["MEMBER", "OWNER", "COLLABORATOR"]'), steps.get-author-association.outputs.author_association) }}
id: generate-token
with:
creds: ${{ secrets.ISSUE_TRIAGE_GH_APP_CREDS }}
- name: Remove label
if: ${{ !contains(fromJSON('["MEMBER", "OWNER", "COLLABORATOR"]'), steps.get-author-association.outputs.author_association) }}
env:
GITHUB_TOKEN: ${{ steps.generate-token.outputs.token }}
ISSUE_URL: ${{ github.event.issue.html_url }}

View File

@@ -4,46 +4,51 @@ on:
issues:
types: [labeled]
permissions: # added using https://github.com/step-security/secure-workflows
contents: read
permissions: {}
jobs:
issue-labeled-with-status:
name: status/{confirmed,reviewed} label added
if: github.event.label.name == 'status/confirmed' || github.event.label.name == 'status/reviewed'
runs-on: ubuntu-latest
permissions:
contents: read
steps:
- name: Generate GitHub App token
uses: electron/github-app-auth-action@384fd19694fe7b6dcc9a684746c6976ad78228ae # v1.1.1
uses: electron/github-app-auth-action@e14e47722ed120360649d0789e25b9baece12725 # v2.0.0
id: generate-token
with:
creds: ${{ secrets.ISSUE_TRIAGE_GH_APP_CREDS }}
org: electron
- name: Set status
uses: dsanders11/project-actions/edit-item@438b25e007c2f4efec324497fadc6402e7cc61a6 # v1.4.0
uses: dsanders11/project-actions/edit-item@2134fe7cc71c58b7ae259c82a8e63c6058255678 # v1.7.0
with:
token: ${{ steps.generate-token.outputs.token }}
project-number: 90
field: Status
field-value: ✅ Triaged
fail-if-item-not-found: false
issue-labeled-blocked:
name: blocked/* label added
if: startsWith(github.event.label.name, 'blocked/')
runs-on: ubuntu-latest
permissions:
contents: read
steps:
- name: Generate GitHub App token
uses: electron/github-app-auth-action@384fd19694fe7b6dcc9a684746c6976ad78228ae # v1.1.1
uses: electron/github-app-auth-action@e14e47722ed120360649d0789e25b9baece12725 # v2.0.0
id: generate-token
with:
creds: ${{ secrets.ISSUE_TRIAGE_GH_APP_CREDS }}
org: electron
- name: Set status
uses: dsanders11/project-actions/edit-item@438b25e007c2f4efec324497fadc6402e7cc61a6 # v1.4.0
uses: dsanders11/project-actions/edit-item@2134fe7cc71c58b7ae259c82a8e63c6058255678 # v1.7.0
with:
token: ${{ steps.generate-token.outputs.token }}
project-number: 90
field: Status
field-value: 🛑 Blocked
fail-if-item-not-found: false
issue-labeled-blocked-need-repro:
name: blocked/need-repro label added
if: github.event.label.name == 'blocked/need-repro'
@@ -64,13 +69,13 @@ jobs:
fi
- name: Generate GitHub App token
if: ${{ steps.check-for-comment.outputs.SHOULD_COMMENT }}
uses: electron/github-app-auth-action@384fd19694fe7b6dcc9a684746c6976ad78228ae # v1.1.1
uses: electron/github-app-auth-action@e14e47722ed120360649d0789e25b9baece12725 # v2.0.0
id: generate-token
with:
creds: ${{ secrets.ISSUE_TRIAGE_GH_APP_CREDS }}
- name: Create comment
if: ${{ steps.check-for-comment.outputs.SHOULD_COMMENT }}
uses: actions-cool/issues-helper@a610082f8ac0cf03e357eb8dd0d5e2ba075e017e # v3.6.0
uses: actions-cool/issues-helper@e2ff99831a4f13625d35064e2b3dfe65c07a0396 # v3.7.5
with:
actions: 'create-comment'
token: ${{ steps.generate-token.outputs.token }}

View File

@@ -11,15 +11,16 @@ jobs:
add-to-issue-triage:
if: ${{ contains(github.event.issue.labels.*.name, 'bug :beetle:') }}
runs-on: ubuntu-latest
permissions: {}
steps:
- name: Generate GitHub App token
uses: electron/github-app-auth-action@384fd19694fe7b6dcc9a684746c6976ad78228ae # v1.1.1
uses: electron/github-app-auth-action@e14e47722ed120360649d0789e25b9baece12725 # v2.0.0
id: generate-token
with:
creds: ${{ secrets.ISSUE_TRIAGE_GH_APP_CREDS }}
org: electron
- name: Add to Issue Triage
uses: dsanders11/project-actions/add-item@438b25e007c2f4efec324497fadc6402e7cc61a6 # v1.4.0
uses: dsanders11/project-actions/add-item@2134fe7cc71c58b7ae259c82a8e63c6058255678 # v1.7.0
with:
field: Reporter
field-value: ${{ github.event.issue.user.login }}
@@ -28,25 +29,37 @@ jobs:
set-labels:
if: ${{ contains(github.event.issue.labels.*.name, 'bug :beetle:') }}
runs-on: ubuntu-latest
permissions: {}
steps:
- name: Generate GitHub App token
uses: electron/github-app-auth-action@384fd19694fe7b6dcc9a684746c6976ad78228ae # v1.1.1
uses: electron/github-app-auth-action@e14e47722ed120360649d0789e25b9baece12725 # v2.0.0
id: generate-token
with:
creds: ${{ secrets.ISSUE_TRIAGE_GH_APP_CREDS }}
org: electron
- run: npm install @electron/fiddle-core@1.3.3 mdast-util-from-markdown@2.0.0 unist-util-select@5.1.0 semver@7.6.0
- name: Sparse checkout repository
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
with:
sparse-checkout: |
.
.github
.yarn
- run: yarn workspaces focus @electron/gha-workflows
- name: Add labels
uses: actions/github-script@60a0d83039c74a4aee543508d2ffcb1c3799cdea # v7.0.1
uses: actions/github-script@ed597411d8f924073f98dfc5c65a23a2325f34cd # v8.0.0
id: add-labels
env:
ISSUE_BODY: ${{ github.event.issue.body }}
with:
github-token: ${{ steps.generate-token.outputs.token }}
script: |
const { fromMarkdown } = await import('${{ github.workspace }}/node_modules/mdast-util-from-markdown/index.js');
const { select } = await import('${{ github.workspace }}/node_modules/unist-util-select/index.js');
const semver = await import('${{ github.workspace }}/node_modules/semver/index.js');
const { chdir } = require('node:process');
chdir('${{ github.workspace }}/.github/workflows');
const { ElectronVersions } = require('@electron/fiddle-core');
const { fromMarkdown } = require('mdast-util-from-markdown');
const { select } = require('unist-util-select');
const semver = require('semver');
const [ owner, repo ] = '${{ github.repository }}'.split('/');
const issue_number = ${{ github.event.issue.number }};
@@ -60,6 +73,8 @@ jobs:
// It's possible for multiple versions to be listed -
// for now check for comma or space separated version.
const versions = electronVersion.split(/, | /);
let hasSupportedVersion = false;
for (const version of versions) {
const major = semver.coerce(version, { loose: true })?.major;
if (major) {
@@ -75,19 +90,19 @@ jobs:
labelExists = true;
} catch {}
if (labelExists) {
// Check if it's an unsupported major
const { ElectronVersions } = await import('${{ github.workspace }}/node_modules/@electron/fiddle-core/dist/index.js');
const versions = await ElectronVersions.create(undefined, { ignoreCache: true });
const electronVersions = await ElectronVersions.create(undefined, { ignoreCache: true });
const validVersions = [...electronVersions.supportedMajors, ...electronVersions.prereleaseMajors];
const validVersions = [...versions.supportedMajors, ...versions.prereleaseMajors];
if (validVersions.includes(major)) {
if (validVersions.includes(major)) {
hasSupportedVersion = true;
if (labelExists) {
labels.push(versionLabel);
}
}
}
}
if (labels.length === 0) {
if (!hasSupportedVersion) {
core.setOutput('unsupportedMajor', true);
labels.push('blocked/need-info ❌');
}
@@ -131,7 +146,7 @@ jobs:
}
- name: Create unsupported major comment
if: ${{ steps.add-labels.outputs.unsupportedMajor }}
uses: actions-cool/issues-helper@a610082f8ac0cf03e357eb8dd0d5e2ba075e017e # v3.6.0
uses: actions-cool/issues-helper@e2ff99831a4f13625d35064e2b3dfe65c07a0396 # v3.7.5
with:
actions: 'create-comment'
token: ${{ steps.generate-token.outputs.token }}

View File

@@ -10,15 +10,19 @@ jobs:
issue-transferred:
name: Issue Transferred
runs-on: ubuntu-latest
permissions: {}
if: ${{ !github.event.changes.new_repository.private }}
steps:
- name: Generate GitHub App token
uses: electron/github-app-auth-action@384fd19694fe7b6dcc9a684746c6976ad78228ae # v1.1.1
uses: electron/github-app-auth-action@e14e47722ed120360649d0789e25b9baece12725 # v2.0.0
id: generate-token
with:
creds: ${{ secrets.ISSUE_TRIAGE_GH_APP_CREDS }}
org: electron
- name: Remove from issue triage
uses: dsanders11/project-actions/delete-item@438b25e007c2f4efec324497fadc6402e7cc61a6 # v1.4.0
uses: dsanders11/project-actions/delete-item@2134fe7cc71c58b7ae259c82a8e63c6058255678 # v1.7.0
with:
token: ${{ steps.generate-token.outputs.token }}
project-number: 90
item: ${{ github.event.changes.new_issue.html_url }}
fail-if-item-not-found: false

View File

@@ -4,14 +4,15 @@ on:
issues:
types: [unlabeled]
permissions:
contents: read
permissions: {}
jobs:
issue-unlabeled-blocked:
name: All blocked/* labels removed
if: startsWith(github.event.label.name, 'blocked/') && github.event.issue.state == 'open'
runs-on: ubuntu-latest
permissions:
contents: read
steps:
- name: Check for any blocked labels
id: check-for-blocked-labels
@@ -23,16 +24,17 @@ jobs:
fi
- name: Generate GitHub App token
if: ${{ steps.check-for-blocked-labels.outputs.NOT_BLOCKED }}
uses: electron/github-app-auth-action@384fd19694fe7b6dcc9a684746c6976ad78228ae # v1.1.1
uses: electron/github-app-auth-action@e14e47722ed120360649d0789e25b9baece12725 # v2.0.0
id: generate-token
with:
creds: ${{ secrets.ISSUE_TRIAGE_GH_APP_CREDS }}
org: electron
- name: Set status
if: ${{ steps.check-for-blocked-labels.outputs.NOT_BLOCKED }}
uses: dsanders11/project-actions/edit-item@438b25e007c2f4efec324497fadc6402e7cc61a6 # v1.4.0
uses: dsanders11/project-actions/edit-item@2134fe7cc71c58b7ae259c82a8e63c6058255678 # v1.7.0
with:
token: ${{ steps.generate-token.outputs.token }}
project-number: 90
field: Status
field-value: 📥 Was Blocked
fail-if-item-not-found: false

View File

@@ -6,7 +6,7 @@ on:
build-image-sha:
type: string
description: 'SHA for electron/build image'
default: 'bc2f48b2415a670de18d13605b1cf0eb5fdbaae1'
default: 'a82b87d7a4f5ff0cab61405f8151ac4cf4942aeb'
upload-to-storage:
description: 'Uploads to Azure storage'
required: false
@@ -17,9 +17,14 @@ on:
type: boolean
default: false
permissions: {}
jobs:
checkout-linux:
runs-on: electron-arc-linux-amd64-32core
if: github.repository == 'electron/electron'
runs-on: electron-arc-centralus-linux-amd64-32core
permissions:
contents: read
container:
image: ghcr.io/electron/build:${{ inputs.build-image-sha }}
options: --user root
@@ -27,10 +32,11 @@ jobs:
- /mnt/cross-instance-cache:/mnt/cross-instance-cache
- /var/run/sas:/var/run/sas
env:
CHROMIUM_GIT_COOKIE: ${{ secrets.CHROMIUM_GIT_COOKIE }}
GCLIENT_EXTRA_ARGS: '--custom-var=checkout_arm=True --custom-var=checkout_arm64=True'
steps:
- name: Checkout Electron
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd
with:
path: src/electron
fetch-depth: 0
@@ -38,49 +44,61 @@ jobs:
uses: ./src/electron/.github/actions/checkout
publish-x64:
uses: ./.github/workflows/pipeline-segment-electron-build.yml
uses: ./.github/workflows/pipeline-segment-electron-publish.yml
permissions:
artifact-metadata: write
attestations: write
contents: read
id-token: write
needs: checkout-linux
with:
environment: production-release
build-runs-on: electron-arc-linux-amd64-32core
build-runs-on: electron-arc-centralus-linux-amd64-32core
build-container: '{"image":"ghcr.io/electron/build:${{ inputs.build-image-sha }}","options":"--user root","volumes":["/mnt/cross-instance-cache:/mnt/cross-instance-cache"]}'
target-platform: linux
target-arch: x64
is-release: true
gn-build-type: release
generate-symbols: true
strip-binaries: true
upload-to-storage: ${{ inputs.upload-to-storage }}
secrets: inherit
publish-arm:
uses: ./.github/workflows/pipeline-segment-electron-build.yml
uses: ./.github/workflows/pipeline-segment-electron-publish.yml
permissions:
artifact-metadata: write
attestations: write
contents: read
id-token: write
needs: checkout-linux
with:
environment: production-release
build-runs-on: electron-arc-linux-amd64-32core
build-runs-on: electron-arc-centralus-linux-amd64-32core
build-container: '{"image":"ghcr.io/electron/build:${{ inputs.build-image-sha }}","options":"--user root","volumes":["/mnt/cross-instance-cache:/mnt/cross-instance-cache"]}'
target-platform: linux
target-arch: arm
is-release: true
gn-build-type: release
generate-symbols: true
strip-binaries: true
upload-to-storage: ${{ inputs.upload-to-storage }}
secrets: inherit
publish-arm64:
uses: ./.github/workflows/pipeline-segment-electron-build.yml
uses: ./.github/workflows/pipeline-segment-electron-publish.yml
permissions:
artifact-metadata: write
attestations: write
contents: read
id-token: write
needs: checkout-linux
with:
environment: production-release
build-runs-on: electron-arc-linux-amd64-32core
build-runs-on: electron-arc-centralus-linux-amd64-32core
build-container: '{"image":"ghcr.io/electron/build:${{ inputs.build-image-sha }}","options":"--user root","volumes":["/mnt/cross-instance-cache:/mnt/cross-instance-cache"]}'
target-platform: linux
target-arch: arm64
is-release: true
gn-build-type: release
generate-symbols: true
strip-binaries: true
upload-to-storage: ${{ inputs.upload-to-storage }}
secrets: inherit

105
.github/workflows/macos-disk-cleanup.yml vendored Normal file
View File

@@ -0,0 +1,105 @@
name: macOS Disk Space Cleanup
# Description:
# This workflow runs the disk space reclaimer on macOS runners every night
# and logs disk space metrics to Datadog for monitoring.
on:
schedule:
- cron: "0 0 * * *"
workflow_dispatch:
permissions: {}
jobs:
macos-disk-cleanup:
if: github.repository == 'electron/electron'
strategy:
fail-fast: false
matrix:
runner:
- macos-15
- macos-15-large
- macos-15-xlarge
runs-on: ${{ matrix.runner }}
permissions:
contents: read
steps:
- name: Checkout
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
with:
sparse-checkout: |
.github/actions/free-space-macos
sparse-checkout-cone-mode: false
- name: Get Disk Space Before Cleanup
id: disk-before
shell: bash
run: |
echo "Disk space before cleanup:"
df -h /
FREE_SPACE_BEFORE=$(df -k / | tail -1 | awk '{print $4}')
echo "free_kb=$FREE_SPACE_BEFORE" >> $GITHUB_OUTPUT
- name: Free Space on macOS
uses: ./.github/actions/free-space-macos
- name: Get Disk Space After Cleanup
id: disk-after
shell: bash
run: |
echo "Disk space after cleanup:"
df -h /
FREE_SPACE_AFTER=$(df -k / | tail -1 | awk '{print $4}')
echo "free_kb=$FREE_SPACE_AFTER" >> $GITHUB_OUTPUT
- name: Log Disk Space to Datadog
if: ${{ env.DD_API_KEY != '' }}
shell: bash
env:
DD_API_KEY: ${{ secrets.DD_API_KEY }}
FREE_BEFORE: ${{ steps.disk-before.outputs.free_kb }}
FREE_AFTER: ${{ steps.disk-after.outputs.free_kb }}
MATRIX_RUNNER: ${{ matrix.runner }}
run: |
TIMESTAMP=$(date +%s)
FREE_BEFORE_GB=$(echo "scale=2; $FREE_BEFORE / 1024 / 1024" | bc)
FREE_AFTER_GB=$(echo "scale=2; $FREE_AFTER / 1024 / 1024" | bc)
SPACE_FREED_GB=$(echo "scale=2; ($FREE_AFTER - $FREE_BEFORE) / 1024 / 1024" | bc)
echo "Free space before: ${FREE_BEFORE_GB}GB"
echo "Free space after: ${FREE_AFTER_GB}GB"
echo "Space freed: ${SPACE_FREED_GB}GB"
curl -s -X POST "https://api.datadoghq.com/api/v2/series" \
-H "Content-Type: application/json" \
-H "DD-API-KEY: ${DD_API_KEY}" \
-d @- << EOF
{
"series": [
{
"metric": "electron.macos.disk.free_space_before_cleanup_gb",
"points": [{"timestamp": ${TIMESTAMP}, "value": ${FREE_BEFORE_GB}}],
"type": 3,
"unit": "gigabyte",
"tags": ["runner:${MATRIX_RUNNER}", "platform:macos"]
},
{
"metric": "electron.macos.disk.free_space_after_cleanup_gb",
"points": [{"timestamp": ${TIMESTAMP}, "value": ${FREE_AFTER_GB}}],
"type": 3,
"unit": "gigabyte",
"tags": ["runner:${MATRIX_RUNNER}", "platform:macos"]
},
{
"metric": "electron.macos.disk.space_freed_gb",
"points": [{"timestamp": ${TIMESTAMP}, "value": ${SPACE_FREED_GB}}],
"type": 3,
"unit": "gigabyte",
"tags": ["runner:${MATRIX_RUNNER}", "platform:macos"]
}
]
}
EOF
echo "Disk space metrics logged to Datadog"

View File

@@ -6,7 +6,7 @@ on:
build-image-sha:
type: string
description: 'SHA for electron/build image'
default: 'bc2f48b2415a670de18d13605b1cf0eb5fdbaae1'
default: 'a82b87d7a4f5ff0cab61405f8151ac4cf4942aeb'
required: true
upload-to-storage:
description: 'Uploads to Azure storage'
@@ -18,9 +18,14 @@ on:
type: boolean
default: false
permissions: {}
jobs:
checkout-macos:
runs-on: electron-arc-linux-amd64-32core
if: github.repository == 'electron/electron'
runs-on: electron-arc-centralus-linux-amd64-32core
permissions:
contents: read
container:
image: ghcr.io/electron/build:${{ inputs.build-image-sha }}
options: --user root
@@ -28,10 +33,11 @@ jobs:
- /mnt/cross-instance-cache:/mnt/cross-instance-cache
- /var/run/sas:/var/run/sas
env:
CHROMIUM_GIT_COOKIE: ${{ secrets.CHROMIUM_GIT_COOKIE }}
GCLIENT_EXTRA_ARGS: '--custom-var=checkout_mac=True --custom-var=host_os=mac'
steps:
- name: Checkout Electron
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd
with:
path: src/electron
fetch-depth: 0
@@ -39,13 +45,19 @@ jobs:
uses: ./src/electron/.github/actions/checkout
with:
generate-sas-token: 'true'
target-platform: macos
publish-x64-darwin:
uses: ./.github/workflows/pipeline-segment-electron-build.yml
uses: ./.github/workflows/pipeline-segment-electron-publish.yml
permissions:
artifact-metadata: write
attestations: write
contents: read
id-token: write
needs: checkout-macos
with:
environment: production-release
build-runs-on: macos-14-xlarge
build-runs-on: macos-15-xlarge
target-platform: macos
target-arch: x64
target-variant: darwin
@@ -56,11 +68,16 @@ jobs:
secrets: inherit
publish-x64-mas:
uses: ./.github/workflows/pipeline-segment-electron-build.yml
uses: ./.github/workflows/pipeline-segment-electron-publish.yml
permissions:
artifact-metadata: write
attestations: write
contents: read
id-token: write
needs: checkout-macos
with:
environment: production-release
build-runs-on: macos-14-xlarge
build-runs-on: macos-15-xlarge
target-platform: macos
target-arch: x64
target-variant: mas
@@ -71,11 +88,16 @@ jobs:
secrets: inherit
publish-arm64-darwin:
uses: ./.github/workflows/pipeline-segment-electron-build.yml
uses: ./.github/workflows/pipeline-segment-electron-publish.yml
permissions:
artifact-metadata: write
attestations: write
contents: read
id-token: write
needs: checkout-macos
with:
environment: production-release
build-runs-on: macos-14-xlarge
build-runs-on: macos-15-xlarge
target-platform: macos
target-arch: arm64
target-variant: darwin
@@ -86,11 +108,16 @@ jobs:
secrets: inherit
publish-arm64-mas:
uses: ./.github/workflows/pipeline-segment-electron-build.yml
uses: ./.github/workflows/pipeline-segment-electron-publish.yml
permissions:
artifact-metadata: write
attestations: write
contents: read
id-token: write
needs: checkout-macos
with:
environment: production-release
build-runs-on: macos-14-xlarge
build-runs-on: macos-15-xlarge
target-platform: macos
target-arch: arm64
target-variant: mas

View File

@@ -1,30 +1,42 @@
name: Check for Non-Maintainer Dependency Change
name: Check for Disallowed Non-Maintainer Change
on:
pull_request_target:
paths:
- 'yarn.lock'
- 'spec/yarn.lock'
- '.github/workflows/**'
- '.github/actions/**'
- '.yarn/**'
- '.yarnrc.yml'
permissions: {}
jobs:
check-for-non-maintainer-dependency-change:
name: Check for non-maintainer dependency change
if: ${{ !contains(fromJSON('["MEMBER", "OWNER"]'), github.event.pull_request.author_association) && github.event.pull_request.user.type != 'Bot' && !github.event.pull_request.draft }}
name: Check for disallowed non-maintainer change
if: ${{ github.event.pull_request.user.type != 'Bot' && !github.event.pull_request.draft }}
permissions:
contents: read
pull-requests: write
runs-on: ubuntu-latest
steps:
- name: Get author association
id: get-author-association
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
AUTHOR_ASSOCIATION=$(gh api /repos/electron/electron/pulls/${{ github.event.pull_request.number }} --jq '.author_association')
echo "author_association=$AUTHOR_ASSOCIATION" >> "$GITHUB_OUTPUT"
- name: Check for existing review
id: check-for-review
if: ${{ !contains(fromJSON('["MEMBER", "OWNER"]'), steps.get-author-association.outputs.author_association) }}
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
PR_URL: ${{ github.event.pull_request.html_url }}
run: |
set -eo pipefail
REVIEW_COUNT=$(gh pr view $PR_URL --json reviews | jq '[ .reviews[] | select(.author.login == "github-actions") | select(.body | startswith("<!-- no-dependency-change -->")) ] | length')
REVIEW_COUNT=$(gh pr view $PR_URL --json reviews | jq '[ .reviews[] | select(.author.login == "github-actions") | select(.body | startswith("<!-- disallowed-non-maintainer-change -->")) ] | length')
if [[ $REVIEW_COUNT -eq 0 ]]; then
echo "SHOULD_REVIEW=1" >> "$GITHUB_OUTPUT"
fi
@@ -34,4 +46,4 @@ jobs:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
PR_URL: ${{ github.event.pull_request.html_url }}
run: |
printf "<!-- no-dependency-change -->\n\nHello @${{ github.event.pull_request.user.login }}! It looks like this pull request touches one of our dependency files, and per [our contribution policy](https://github.com/electron/electron/blob/main/CONTRIBUTING.md#dependencies-upgrades-policy) we do not accept these types of changes in PRs." | gh pr review $PR_URL -r --body-file=-
printf "<!-- disallowed-non-maintainer-change -->\n\nHello @${{ github.event.pull_request.user.login }}! It looks like this pull request touches one of our dependency or CI files, and per [our contribution policy](https://github.com/electron/electron/blob/main/CONTRIBUTING.md#dependencies-upgrades-policy) we do not accept these types of changes in PRs." | gh pr review $PR_URL -r --body-file=-

13
.github/workflows/package.json vendored Normal file
View File

@@ -0,0 +1,13 @@
{
"name": "@electron/gha-workflows",
"version": "0.0.0-development",
"private": true,
"type": "module",
"dependencies": {
"@actions/cache": "^4.0.3",
"@electron/fiddle-core": "^2.0.1",
"mdast-util-from-markdown": "^2.0.0",
"semver": "^7.7.2",
"unist-util-select": "^5.1.0"
}
}

View File

@@ -55,13 +55,17 @@ on:
type: boolean
default: false
permissions: {}
concurrency:
group: electron-build-and-test-and-nan-${{ inputs.target-platform }}-${{ inputs.target-arch }}-${{ github.ref }}
cancel-in-progress: ${{ github.ref != 'refs/heads/main' && !endsWith(github.ref, '-x-y') }}
group: electron-build-and-test-and-nan-${{ inputs.target-platform }}-${{ inputs.target-arch }}-${{ github.ref_protected == true && github.run_id || github.ref }}
cancel-in-progress: ${{ github.ref_protected != true }}
jobs:
build:
uses: ./.github/workflows/pipeline-segment-electron-build.yml
permissions:
contents: read
with:
build-runs-on: ${{ inputs.build-runs-on }}
build-container: ${{ inputs.build-container }}
@@ -74,6 +78,10 @@ jobs:
secrets: inherit
test:
uses: ./.github/workflows/pipeline-segment-electron-test.yml
permissions:
contents: read
issues: read
pull-requests: read
needs: build
with:
target-arch: ${{ inputs.target-arch }}
@@ -83,6 +91,8 @@ jobs:
secrets: inherit
nn-test:
uses: ./.github/workflows/pipeline-segment-node-nan-test.yml
permissions:
contents: read
needs: build
with:
target-arch: ${{ inputs.target-arch }}

View File

@@ -54,19 +54,23 @@ on:
required: false
type: boolean
default: false
enable-ssh:
description: 'Enable SSH debugging'
required: false
type: boolean
default: false
concurrency:
group: electron-build-and-test-${{ inputs.target-platform }}-${{ inputs.target-arch }}-${{ github.ref }}
cancel-in-progress: ${{ github.ref != 'refs/heads/main' && !endsWith(github.ref, '-x-y') }}
group: electron-build-and-test-${{ inputs.target-platform }}-${{ inputs.target-arch }}-${{ github.ref_protected == true && github.run_id || github.ref }}
cancel-in-progress: ${{ github.ref_protected != true }}
permissions:
contents: read
issues: read
pull-requests: read
permissions: {}
jobs:
build:
uses: ./.github/workflows/pipeline-segment-electron-build.yml
permissions:
contents: read
with:
build-runs-on: ${{ inputs.build-runs-on }}
build-container: ${{ inputs.build-container }}
@@ -76,15 +80,21 @@ jobs:
gn-build-type: ${{ inputs.gn-build-type }}
generate-symbols: ${{ inputs.generate-symbols }}
upload-to-storage: ${{ inputs.upload-to-storage }}
is-asan: ${{ inputs.is-asan}}
is-asan: ${{ inputs.is-asan }}
enable-ssh: ${{ inputs.enable-ssh }}
secrets: inherit
test:
uses: ./.github/workflows/pipeline-segment-electron-test.yml
permissions:
contents: read
issues: read
pull-requests: read
needs: build
with:
target-arch: ${{ inputs.target-arch }}
target-platform: ${{ inputs.target-platform }}
test-runs-on: ${{ inputs.test-runs-on }}
test-container: ${{ inputs.test-container }}
is-asan: ${{ inputs.is-asan}}
is-asan: ${{ inputs.is-asan }}
enable-ssh: ${{ inputs.enable-ssh }}
secrets: inherit

View File

@@ -0,0 +1,124 @@
name: Electron Build & Clang Tidy & Test (+ Node + NaN) Pipeline
on:
workflow_call:
inputs:
target-platform:
type: string
description: 'Platform to run on, can be macos, win or linux.'
required: true
target-arch:
type: string
description: 'Arch to build for, can be x64, arm64 or arm'
required: true
build-runs-on:
type: string
description: 'What host to run the build'
required: true
clang-tidy-runs-on:
type: string
description: 'What host to run clang-tidy on'
required: true
test-runs-on:
type: string
description: 'What host to run the tests on'
required: true
build-container:
type: string
description: 'JSON container information for aks runs-on'
required: false
default: '{"image":null}'
clang-tidy-container:
type: string
description: 'JSON container information to run clang-tidy on'
required: false
default: '{"image":null}'
test-container:
type: string
description: 'JSON container information for testing'
required: false
default: '{"image":null}'
is-release:
description: 'Whether this build job is a release job'
required: true
type: boolean
default: false
gn-build-type:
description: 'The gn build type - testing or release'
required: true
type: string
default: testing
generate-symbols:
description: 'Whether or not to generate symbols'
required: true
type: boolean
default: false
upload-to-storage:
description: 'Whether or not to upload build artifacts to external storage'
required: true
type: string
default: '0'
is-asan:
description: 'Building the Address Sanitizer (ASan) Linux build'
required: false
type: boolean
default: false
permissions: {}
concurrency:
group: electron-build-and-test-and-nan-${{ inputs.target-platform }}-${{ inputs.target-arch }}-${{ github.ref_protected == true && github.run_id || github.ref }}
cancel-in-progress: ${{ github.ref_protected != true }}
jobs:
build:
uses: ./.github/workflows/pipeline-segment-electron-build.yml
permissions:
contents: read
with:
build-runs-on: ${{ inputs.build-runs-on }}
build-container: ${{ inputs.build-container }}
target-platform: ${{ inputs.target-platform }}
target-arch: ${{ inputs.target-arch }}
is-release: ${{ inputs.is-release }}
gn-build-type: ${{ inputs.gn-build-type }}
generate-symbols: ${{ inputs.generate-symbols }}
upload-to-storage: ${{ inputs.upload-to-storage }}
upload-out-gen-artifacts: true
secrets: inherit
clang-tidy:
uses: ./.github/workflows/pipeline-segment-electron-clang-tidy.yml
permissions:
contents: read
needs: build
with:
clang-tidy-runs-on: ${{ inputs.clang-tidy-runs-on }}
clang-tidy-container: ${{ inputs.clang-tidy-container }}
target-platform: ${{ inputs.target-platform }}
target-arch: ${{ inputs.target-arch }}
secrets: inherit
test:
uses: ./.github/workflows/pipeline-segment-electron-test.yml
permissions:
contents: read
issues: read
pull-requests: read
needs: build
with:
target-arch: ${{ inputs.target-arch }}
target-platform: ${{ inputs.target-platform }}
test-runs-on: ${{ inputs.test-runs-on }}
test-container: ${{ inputs.test-container }}
secrets: inherit
nn-test:
uses: ./.github/workflows/pipeline-segment-node-nan-test.yml
permissions:
contents: read
needs: build
with:
target-arch: ${{ inputs.target-arch }}
target-platform: ${{ inputs.target-platform }}
test-runs-on: ${{ inputs.test-runs-on }}
test-container: ${{ inputs.test-container }}
gn-build-type: ${{ inputs.gn-build-type }}
secrets: inherit

View File

@@ -0,0 +1,121 @@
name: Electron Build & Clang Tidy & Test Pipeline
on:
workflow_call:
inputs:
target-platform:
type: string
description: 'Platform to run on, can be macos, win or linux'
required: true
target-arch:
type: string
description: 'Arch to build for, can be x64, arm64 or arm'
required: true
build-runs-on:
type: string
description: 'What host to run the build'
required: true
clang-tidy-runs-on:
type: string
description: 'What host to run clang-tidy on'
required: true
test-runs-on:
type: string
description: 'What host to run the tests on'
required: true
build-container:
type: string
description: 'JSON container information for aks runs-on'
required: false
default: '{"image":null}'
clang-tidy-container:
type: string
description: 'JSON container information to run clang-tidy on'
required: false
default: '{"image":null}'
test-container:
type: string
description: 'JSON container information for testing'
required: false
default: '{"image":null}'
is-release:
description: 'Whether this build job is a release job'
required: true
type: boolean
default: false
gn-build-type:
description: 'The gn build type - testing or release'
required: true
type: string
default: testing
generate-symbols:
description: 'Whether or not to generate symbols'
required: true
type: boolean
default: false
upload-to-storage:
description: 'Whether or not to upload build artifacts to external storage'
required: true
type: string
default: '0'
is-asan:
description: 'Building the Address Sanitizer (ASan) Linux build'
required: false
type: boolean
default: false
enable-ssh:
description: 'Enable SSH debugging'
required: false
type: boolean
default: false
concurrency:
group: electron-build-and-tidy-and-test-${{ inputs.target-platform }}-${{ inputs.target-arch }}-${{ github.ref_protected == true && github.run_id || github.ref }}
cancel-in-progress: ${{ github.ref_protected != true }}
permissions: {}
jobs:
build:
uses: ./.github/workflows/pipeline-segment-electron-build.yml
permissions:
contents: read
with:
build-runs-on: ${{ inputs.build-runs-on }}
build-container: ${{ inputs.build-container }}
target-platform: ${{ inputs.target-platform }}
target-arch: ${{ inputs.target-arch }}
is-release: ${{ inputs.is-release }}
gn-build-type: ${{ inputs.gn-build-type }}
generate-symbols: ${{ inputs.generate-symbols }}
upload-to-storage: ${{ inputs.upload-to-storage }}
is-asan: ${{ inputs.is-asan }}
enable-ssh: ${{ inputs.enable-ssh }}
upload-out-gen-artifacts: true
secrets: inherit
clang-tidy:
uses: ./.github/workflows/pipeline-segment-electron-clang-tidy.yml
permissions:
contents: read
needs: build
with:
clang-tidy-runs-on: ${{ inputs.clang-tidy-runs-on }}
clang-tidy-container: ${{ inputs.clang-tidy-container }}
target-platform: ${{ inputs.target-platform }}
target-arch: ${{ inputs.target-arch }}
secrets: inherit
test:
uses: ./.github/workflows/pipeline-segment-electron-test.yml
permissions:
contents: read
issues: read
pull-requests: read
needs: build
with:
target-arch: ${{ inputs.target-arch }}
target-platform: ${{ inputs.target-platform }}
test-runs-on: ${{ inputs.test-runs-on }}
test-container: ${{ inputs.test-container }}
is-asan: ${{ inputs.is-asan }}
enable-ssh: ${{ inputs.enable-ssh }}
secrets: inherit

View File

@@ -8,19 +8,42 @@ on:
description: 'Container to run the docs-only ts compile in'
type: string
permissions: {}
concurrency:
group: electron-docs-only-${{ github.ref }}
cancel-in-progress: true
env:
GCLIENT_EXTRA_ARGS: --custom-var=checkout_arm=True --custom-var=checkout_arm64=True
jobs:
docs-only:
name: Docs Only Compile
runs-on: electron-arc-linux-amd64-4core
runs-on: electron-arc-centralus-linux-amd64-4core
permissions:
contents: read
timeout-minutes: 20
container: ${{ fromJSON(inputs.container) }}
steps:
- name: Checkout Electron
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd
with:
path: src/electron
fetch-depth: 0
ref: ${{ github.event.pull_request.head.sha }}
- name: Generate DEPS Hash
run: |
node src/electron/script/generate-deps-hash.js
DEPSHASH=v1-src-cache-$(cat src/electron/.depshash)
echo "DEPSHASH=$DEPSHASH" >> $GITHUB_ENV
echo "CACHE_PATH=$DEPSHASH.tar" >> $GITHUB_ENV
- name: Restore src cache via AKS
uses: ./src/electron/.github/actions/restore-cache-aks
with:
target-platform: linux
- name: Checkout Electron
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd
with:
path: src/electron
fetch-depth: 0
@@ -31,12 +54,12 @@ jobs:
shell: bash
run: |
cd src/electron
node script/yarn create-typescript-definitions
node script/yarn tsc -p tsconfig.default_app.json --noEmit
node script/yarn.js create-typescript-definitions
node script/yarn.js tsc -p tsconfig.default_app.json --noEmit
for f in build/webpack/*.js
do
out="${f:29}"
if [ "$out" != "base.js" ]; then
node script/yarn webpack --config $f --output-filename=$out --output-path=./.tmp --env mode=development
node script/yarn.js webpack --config $f --output-filename=$out --output-path=./.tmp --env mode=development
fi
done

View File

@@ -8,25 +8,34 @@ on:
description: 'Container to run lint in'
type: string
permissions: {}
concurrency:
group: electron-lint-${{ github.ref }}
cancel-in-progress: ${{ github.ref != 'refs/heads/main' && !endsWith(github.ref, '-x-y') }}
group: electron-lint-${{ github.ref_protected == true && github.run_id || github.ref }}
cancel-in-progress: ${{ github.ref_protected != true }}
env:
CHROMIUM_GIT_COOKIE: ${{ secrets.CHROMIUM_GIT_COOKIE }}
jobs:
lint:
name: Lint
runs-on: electron-arc-linux-amd64-4core
runs-on: electron-arc-centralus-linux-amd64-4core
permissions:
contents: read
timeout-minutes: 20
container: ${{ fromJSON(inputs.container) }}
steps:
- name: Checkout Electron
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd
with:
path: src/electron
fetch-depth: 0
ref: ${{ github.event.pull_request.head.sha }}
- name: Install Dependencies
uses: ./src/electron/.github/actions/install-dependencies
- name: Set Chromium Git Cookie
uses: ./src/electron/.github/actions/set-chromium-cookie
- name: Setup third_party Depot Tools
shell: bash
run: |
@@ -56,6 +65,11 @@ jobs:
curl -sL "https://chromium.googlesource.com/chromium/src/+/${chromium_revision}/buildtools/DEPS?format=TEXT" | base64 -d > src/buildtools/DEPS
gclient sync --spec="solutions=[{'name':'src/buildtools','url':None,'deps_file':'DEPS','custom_vars':{'process_deps':True},'managed':False}]"
- name: Add problem matchers
shell: bash
run: |
echo "::add-matcher::src/electron/.github/problem-matchers/eslint-stylish.json"
echo "::add-matcher::src/electron/.github/problem-matchers/markdownlint.json"
- name: Run Lint
shell: bash
run: |
@@ -66,11 +80,15 @@ jobs:
# but then we would lint its contents (at least gn format), and it doesn't pass it.
cd src/electron
node script/yarn install --frozen-lockfile
node script/yarn lint
node script/yarn.js install --immutable
node script/yarn.js lint
- name: Run Script Typechecker
shell: bash
run: |
cd src/electron
node script/yarn tsc -p tsconfig.script.json
node script/yarn.js tsc -p tsconfig.script.json
- name: Check GHA Workflows
shell: bash
run: |
cd src/electron
node script/copy-pipeline-segment-publish.js --check

View File

@@ -13,7 +13,7 @@ on:
required: true
target-arch:
type: string
description: 'Arch to build for, can be x64, arm64 or arm'
description: 'Arch to build for, can be x64, arm64, ia32 or arm'
required: true
target-variant:
type: string
@@ -48,29 +48,39 @@ on:
required: true
type: string
default: '0'
strip-binaries:
description: 'Strip the binaries before release (Linux only)'
required: false
type: boolean
default: false
is-asan:
description: 'Building the Address Sanitizer (ASan) Linux build'
required: false
type: boolean
default: false
upload-out-gen-artifacts:
description: 'Whether to upload the src/gen artifacts'
required: false
type: boolean
default: false
enable-ssh:
description: 'Enable SSH debugging'
required: false
type: boolean
default: false
permissions: {}
concurrency:
group: electron-build-${{ inputs.target-platform }}-${{ inputs.target-arch }}-${{ inputs.target-variant }}-${{ inputs.is-asan }}-${{ github.ref }}
cancel-in-progress: ${{ github.ref != 'refs/heads/main' && !endsWith(github.ref, '-x-y') }}
group: electron-build-${{ inputs.target-platform }}-${{ inputs.target-arch }}-${{ inputs.target-variant }}-${{ inputs.is-asan }}-${{ github.ref_protected == true && github.run_id || github.ref }}
cancel-in-progress: ${{ github.ref_protected != true }}
env:
CHROMIUM_GIT_COOKIE: ${{ secrets.CHROMIUM_GIT_COOKIE }}
CHROMIUM_GIT_COOKIE_WINDOWS_STRING: ${{ secrets.CHROMIUM_GIT_COOKIE_WINDOWS_STRING }}
DD_API_KEY: ${{ secrets.DD_API_KEY }}
ELECTRON_ARTIFACTS_BLOB_STORAGE: ${{ secrets.ELECTRON_ARTIFACTS_BLOB_STORAGE }}
ELECTRON_RBE_JWT: ${{ secrets.ELECTRON_RBE_JWT }}
SUDOWOODO_EXCHANGE_URL: ${{ secrets.SUDOWOODO_EXCHANGE_URL }}
SUDOWOODO_EXCHANGE_TOKEN: ${{ secrets.SUDOWOODO_EXCHANGE_TOKEN }}
GCLIENT_EXTRA_ARGS: ${{ inputs.target-platform == 'macos' && '--custom-var=checkout_mac=True --custom-var=host_os=mac' || inputs.target-platform == 'win' && '--custom-var=checkout_win=True' || '--custom-var=checkout_arm=True --custom-var=checkout_arm64=True' }}
ELECTRON_OUT_DIR: Default
ACTIONS_STEP_DEBUG: ${{ secrets.ACTIONS_STEP_DEBUG }}
jobs:
build:
@@ -78,20 +88,34 @@ jobs:
run:
shell: bash
runs-on: ${{ inputs.build-runs-on }}
permissions:
contents: read
container: ${{ fromJSON(inputs.build-container) }}
environment: ${{ inputs.environment }}
env:
TARGET_ARCH: ${{ inputs.target-arch }}
TARGET_PLATFORM: ${{ inputs.target-platform }}
steps:
- name: Create src dir
run: |
mkdir src
- name: Checkout Electron
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd
with:
path: src/electron
fetch-depth: 0
ref: ${{ github.event.pull_request.head.sha }}
- name: Setup SSH Debugging
if: ${{ inputs.target-platform == 'macos' && (inputs.enable-ssh || env.ACTIONS_STEP_DEBUG == 'true') }}
uses: ./src/electron/.github/actions/ssh-debug
with:
tunnel: 'true'
env:
CLOUDFLARE_TUNNEL_CERT: ${{ secrets.CLOUDFLARE_TUNNEL_CERT }}
CLOUDFLARE_TUNNEL_HOSTNAME: ${{ vars.CLOUDFLARE_TUNNEL_HOSTNAME }}
CLOUDFLARE_USER_CA_CERT: ${{ secrets.CLOUDFLARE_USER_CA_CERT }}
AUTHORIZED_USERS: ${{ secrets.SSH_DEBUG_AUTHORIZED_USERS }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Free up space (macOS)
if: ${{ inputs.target-platform == 'macos' }}
uses: ./src/electron/.github/actions/free-space-macos
@@ -100,9 +124,9 @@ jobs:
run: df -h
- name: Setup Node.js/npm
if: ${{ inputs.target-platform == 'macos' }}
uses: actions/setup-node@39370e3970a6d050c480ffad4ff0ed4d3fdee5af
uses: actions/setup-node@6044e13b5dc448c55e2357c09f80417699197238
with:
node-version: 20.11.x
node-version: 22.21.x
cache: yarn
cache-dependency-path: src/electron/yarn.lock
- name: Install Dependencies
@@ -125,24 +149,10 @@ jobs:
GN_EXTRA_ARGS='is_asan=true'
fi
echo "GN_EXTRA_ARGS=$GN_EXTRA_ARGS" >> $GITHUB_ENV
- name: Get Depot Tools
timeout-minutes: 5
run: |
git clone --filter=tree:0 https://chromium.googlesource.com/chromium/tools/depot_tools.git
SEDOPTION="-i"
if [ "`uname`" = "Darwin" ]; then
SEDOPTION="-i ''"
fi
# remove ninjalog_uploader_wrapper.py from autoninja since we don't use it and it causes problems
sed $SEDOPTION '/ninjalog_uploader_wrapper.py/d' ./depot_tools/autoninja
# Ensure depot_tools does not update.
test -d depot_tools && cd depot_tools
touch .disable_auto_update
- name: Add Depot Tools to PATH
run: echo "$(pwd)/depot_tools" >> $GITHUB_PATH
- name: Set Chromium Git Cookie
uses: ./src/electron/.github/actions/set-chromium-cookie
- name: Install Build Tools
uses: ./src/electron/.github/actions/install-build-tools
- name: Generate DEPS Hash
run: |
node src/electron/script/generate-deps-hash.js
@@ -150,27 +160,29 @@ jobs:
echo "DEPSHASH=$DEPSHASH" >> $GITHUB_ENV
echo "CACHE_PATH=$DEPSHASH.tar" >> $GITHUB_ENV
- name: Restore src cache via AZCopy
if: ${{ inputs.target-platform == 'macos' }}
if: ${{ inputs.target-platform != 'linux' }}
uses: ./src/electron/.github/actions/restore-cache-azcopy
with:
target-platform: ${{ inputs.target-platform }}
- name: Restore src cache via AKS
if: ${{ inputs.target-platform == 'linux' }}
uses: ./src/electron/.github/actions/restore-cache-aks
- name: Checkout src via gclient sync
if: ${{ inputs.target-platform == 'win' }}
uses: ./src/electron/.github/actions/checkout
with:
use-cache: 'false'
- name: Checkout Electron
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd
with:
path: src/electron
fetch-depth: 0
ref: ${{ github.event.pull_request.head.sha }}
- name: Install Build Tools
uses: ./src/electron/.github/actions/install-build-tools
- name: Fix Sync
if: ${{ inputs.target-platform != 'linux' }}
uses: ./src/electron/.github/actions/fix-sync
with:
target-platform: ${{ inputs.target-platform }}
env:
ELECTRON_DEPOT_TOOLS_DISABLE_LOG: true
- name: Init Build Tools
run: |
e init -f --root=$(pwd) --out=Default ${{ inputs.gn-build-type }} --import ${{ inputs.gn-build-type }} --target-cpu ${{ inputs.target-arch }}
e init -f --root=$(pwd) --out=Default ${{ inputs.gn-build-type }} --import ${{ inputs.gn-build-type }} --target-cpu ${{ inputs.target-arch }} --remote-build siso
- name: Run Electron Only Hooks
run: |
e d gclient runhooks --spec="solutions=[{'name':'src/electron','url':None,'deps_file':'DEPS','custom_vars':{'process_deps':False},'managed':False}]"
@@ -180,12 +192,6 @@ jobs:
echo "DEPSHASH=$(cat src/electron/.depshash)" >> $GITHUB_ENV
- name: Add CHROMIUM_BUILDTOOLS_PATH to env
run: echo "CHROMIUM_BUILDTOOLS_PATH=$(pwd)/src/buildtools" >> $GITHUB_ENV
- name: Fix Sync (macOS)
if: ${{ inputs.target-platform == 'macos' }}
uses: ./src/electron/.github/actions/fix-sync-macos
- name: Setup Number of Ninja Processes
run: |
echo "NUMBER_OF_NINJA_PROCESSES=${{ inputs.target-platform != 'macos' && '300' || '200' }}" >> $GITHUB_ENV
- name: Free up space (macOS)
if: ${{ inputs.target-platform == 'macos' }}
uses: ./src/electron/.github/actions/free-space-macos
@@ -198,9 +204,9 @@ jobs:
artifact-platform: ${{ inputs.target-platform == 'macos' && 'darwin' || inputs.target-platform }}
is-release: '${{ inputs.is-release }}'
generate-symbols: '${{ inputs.generate-symbols }}'
strip-binaries: '${{ inputs.strip-binaries }}'
upload-to-storage: '${{ inputs.upload-to-storage }}'
is-asan: '${{ inputs.is-asan }}'
upload-out-gen-artifacts: '${{ inputs.upload-out-gen-artifacts }}'
- name: Set GN_EXTRA_ARGS for MAS Build
if: ${{ inputs.target-platform == 'macos' && (inputs.target-variant == 'all' || inputs.target-variant == 'mas') }}
run: |

View File

@@ -0,0 +1,159 @@
name: Pipeline Segment - Electron Clang-Tidy
on:
workflow_call:
inputs:
target-platform:
type: string
description: 'Platform to run on, can be macos, win or linux'
required: true
target-arch:
type: string
description: 'Arch to build for, can be x64, arm64 or arm'
required: true
clang-tidy-runs-on:
type: string
description: 'What host to run clang-tidy on'
required: true
clang-tidy-container:
type: string
description: 'JSON container information for aks runs-on'
required: false
default: '{"image":null}'
permissions: {}
concurrency:
group: electron-clang-tidy-${{ inputs.target-platform }}-${{ inputs.target-arch }}-${{ github.ref }}
cancel-in-progress: true
env:
GCLIENT_EXTRA_ARGS: ${{ inputs.target-platform == 'macos' && '--custom-var=checkout_mac=True --custom-var=host_os=mac' || (inputs.target-platform == 'linux' && '--custom-var=checkout_arm=True --custom-var=checkout_arm64=True' || '--custom-var=checkout_win=True') }}
ELECTRON_OUT_DIR: Default
jobs:
clang-tidy:
defaults:
run:
shell: bash
runs-on: ${{ inputs.clang-tidy-runs-on }}
permissions:
contents: read
container: ${{ fromJSON(inputs.clang-tidy-container) }}
env:
BUILD_TYPE: ${{ inputs.target-platform == 'macos' && 'darwin' || inputs.target-platform }}
TARGET_ARCH: ${{ inputs.target-arch }}
TARGET_PLATFORM: ${{ inputs.target-platform }}
ARTIFACT_KEY: ${{ inputs.target-platform == 'macos' && 'darwin' || inputs.target-platform }}_${{ inputs.target-arch }}
steps:
- name: Checkout Electron
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd
with:
path: src/electron
fetch-depth: 0
ref: ${{ github.event.pull_request.head.sha }}
- name: Cleanup disk space on macOS
if: ${{ inputs.target-platform == 'macos' }}
shell: bash
run: |
sudo mkdir -p $TMPDIR/del-target
tmpify() {
if [ -d "$1" ]; then
sudo mv "$1" $TMPDIR/del-target/$(echo $1|shasum -a 256|head -n1|cut -d " " -f1)
fi
}
tmpify /Library/Developer/CoreSimulator
tmpify ~/Library/Developer/CoreSimulator
sudo rm -rf $TMPDIR/del-target
- name: Check disk space after freeing up space
if: ${{ inputs.target-platform == 'macos' }}
run: df -h
- name: Set Chromium Git Cookie
uses: ./src/electron/.github/actions/set-chromium-cookie
- name: Install Build Tools
uses: ./src/electron/.github/actions/install-build-tools
- name: Enable windows toolchain
if: ${{ inputs.target-platform == 'win' }}
run: |
echo "ELECTRON_DEPOT_TOOLS_WIN_TOOLCHAIN=1" >> $GITHUB_ENV
- name: Generate DEPS Hash
run: |
node src/electron/script/generate-deps-hash.js
DEPSHASH=v1-src-cache-$(cat src/electron/.depshash)
echo "DEPSHASH=$DEPSHASH" >> $GITHUB_ENV
echo "CACHE_PATH=$DEPSHASH.tar" >> $GITHUB_ENV
- name: Restore src cache via AZCopy
if: ${{ inputs.target-platform == 'macos' }}
uses: ./src/electron/.github/actions/restore-cache-azcopy
with:
target-platform: ${{ inputs.target-platform }}
- name: Restore src cache via AKS
if: ${{ inputs.target-platform == 'linux' || inputs.target-platform == 'win' }}
uses: ./src/electron/.github/actions/restore-cache-aks
with:
target-platform: ${{ inputs.target-platform }}
- name: Run Electron Only Hooks
run: |
echo "solutions=[{'name':'src/electron','url':None,'deps_file':'DEPS','custom_vars':{'process_deps':False},'managed':False}]" > tmpgclient
if [ "${{ inputs.target-platform }}" = "win" ]; then
echo "solutions=[{'name':'src/electron','url':None,'deps_file':'DEPS','custom_vars':{'process_deps':False,'install_sysroot':False,'checkout_win':True},'managed':False}]" > tmpgclient
echo "target_os=['win']" >> tmpgclient
fi
e d gclient runhooks --gclientfile=tmpgclient
# Fix VS Toolchain
if [ "${{ inputs.target-platform }}" = "win" ]; then
rm -rf src/third_party/depot_tools/win_toolchain/vs_files
e d python3 src/build/vs_toolchain.py update --force
fi
- name: Regenerate DEPS Hash
run: |
(cd src/electron && git checkout .) && node src/electron/script/generate-deps-hash.js
echo "DEPSHASH=$(cat src/electron/.depshash)" >> $GITHUB_ENV
- name: Add CHROMIUM_BUILDTOOLS_PATH to env
run: echo "CHROMIUM_BUILDTOOLS_PATH=$(pwd)/src/buildtools" >> $GITHUB_ENV
- name: Checkout Electron
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd
with:
path: src/electron
fetch-depth: 0
ref: ${{ github.event.pull_request.head.sha }}
- name: Install Dependencies
uses: ./src/electron/.github/actions/install-dependencies
- name: Default GN gen
run: |
cd src/electron
git pack-refs
- name: Download Out Gen Artifacts
uses: actions/download-artifact@37930b1c2abaa49bbe596cd826c3c89aef350131
with:
name: out_gen_artifacts_${{ env.ARTIFACT_KEY }}
path: ./src/out/${{ env.ELECTRON_OUT_DIR }}/gen
- name: Add Clang problem matcher
shell: bash
run: echo "::add-matcher::src/electron/.github/problem-matchers/clang.json"
- name: Run Clang-Tidy
run: |
e init -f --root=$(pwd) --out=${ELECTRON_OUT_DIR} testing --target-cpu ${TARGET_ARCH}
export GN_EXTRA_ARGS="target_cpu=\"${TARGET_ARCH}\""
if [ "${{ inputs.target-platform }}" = "win" ]; then
export GN_EXTRA_ARGS="$GN_EXTRA_ARGS use_v8_context_snapshot=true target_os=\"win\""
fi
e build --only-gen
cd src/electron
node script/yarn.js lint:clang-tidy --jobs 8 --out-dir ../out/${ELECTRON_OUT_DIR}
- name: Remove Clang problem matcher
shell: bash
run: echo "::remove-matcher owner=clang::"
- name: Wait for active SSH sessions
if: always() && !cancelled()
shell: bash
run: |
while [ -f /var/.ssh-lock ]
do
sleep 60
done

View File

@@ -26,6 +26,8 @@ on:
type: string
default: testing
permissions: {}
concurrency:
group: electron-gn-check-${{ inputs.target-platform }}-${{ github.ref }}
cancel-in-progress: true
@@ -41,10 +43,12 @@ jobs:
run:
shell: bash
runs-on: ${{ inputs.check-runs-on }}
permissions:
contents: read
container: ${{ fromJSON(inputs.check-container) }}
steps:
- name: Checkout Electron
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd
with:
path: src/electron
fetch-depth: 0
@@ -65,7 +69,9 @@ jobs:
sudo rm -rf $TMPDIR/del-target
- name: Check disk space after freeing up space
if: ${{ inputs.target-platform == 'macos' }}
run: df -h
run: df -h
- name: Set Chromium Git Cookie
uses: ./src/electron/.github/actions/set-chromium-cookie
- name: Install Build Tools
uses: ./src/electron/.github/actions/install-build-tools
- name: Enable windows toolchain
@@ -81,9 +87,13 @@ jobs:
- name: Restore src cache via AZCopy
if: ${{ inputs.target-platform == 'macos' }}
uses: ./src/electron/.github/actions/restore-cache-azcopy
with:
target-platform: ${{ inputs.target-platform }}
- name: Restore src cache via AKS
if: ${{ inputs.target-platform == 'linux' || inputs.target-platform == 'win' }}
uses: ./src/electron/.github/actions/restore-cache-aks
with:
target-platform: ${{ inputs.target-platform }}
- name: Run Electron Only Hooks
run: |
echo "solutions=[{'name':'src/electron','url':None,'deps_file':'DEPS','custom_vars':{'process_deps':False},'managed':False}]" > tmpgclient
@@ -105,7 +115,7 @@ jobs:
- name: Add CHROMIUM_BUILDTOOLS_PATH to env
run: echo "CHROMIUM_BUILDTOOLS_PATH=$(pwd)/src/buildtools" >> $GITHUB_ENV
- name: Checkout Electron
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd
with:
path: src/electron
fetch-depth: 0

View File

@@ -0,0 +1,243 @@
# AUTOGENERATED FILE - DO NOT EDIT MANUALLY
# ONLY EDIT .github/workflows/pipeline-segment-electron-build.yml
name: Pipeline Segment - Electron Build
on:
workflow_call:
inputs:
environment:
description: using the production or testing environment
required: false
type: string
target-platform:
type: string
description: Platform to run on, can be macos, win or linux
required: true
target-arch:
type: string
description: Arch to build for, can be x64, arm64, ia32 or arm
required: true
target-variant:
type: string
description: Variant to build for, no effect on non-macOS target platforms. Can
be darwin, mas or all.
default: all
build-runs-on:
type: string
description: What host to run the build
required: true
build-container:
type: string
description: JSON container information for aks runs-on
required: false
default: '{"image":null}'
is-release:
description: Whether this build job is a release job
required: true
type: boolean
default: false
gn-build-type:
description: The gn build type - testing or release
required: true
type: string
default: testing
generate-symbols:
description: Whether or not to generate symbols
required: true
type: boolean
default: false
upload-to-storage:
description: Whether or not to upload build artifacts to external storage
required: true
type: string
default: "0"
is-asan:
description: Building the Address Sanitizer (ASan) Linux build
required: false
type: boolean
default: false
upload-out-gen-artifacts:
description: Whether to upload the src/gen artifacts
required: false
type: boolean
default: false
enable-ssh:
description: Enable SSH debugging
required: false
type: boolean
default: false
permissions: {}
concurrency:
group: electron-build-${{ inputs.target-platform }}-${{ inputs.target-arch
}}-${{ inputs.target-variant }}-${{ inputs.is-asan }}-${{
github.ref_protected == true && github.run_id || github.ref }}
cancel-in-progress: ${{ github.ref_protected != true }}
env:
CHROMIUM_GIT_COOKIE: ${{ secrets.CHROMIUM_GIT_COOKIE }}
CHROMIUM_GIT_COOKIE_WINDOWS_STRING: ${{ secrets.CHROMIUM_GIT_COOKIE_WINDOWS_STRING }}
DD_API_KEY: ${{ secrets.DD_API_KEY }}
ELECTRON_ARTIFACTS_BLOB_STORAGE: ${{ secrets.ELECTRON_ARTIFACTS_BLOB_STORAGE }}
ELECTRON_RBE_JWT: ${{ secrets.ELECTRON_RBE_JWT }}
SUDOWOODO_EXCHANGE_URL: ${{ secrets.SUDOWOODO_EXCHANGE_URL }}
SUDOWOODO_EXCHANGE_TOKEN: ${{ secrets.SUDOWOODO_EXCHANGE_TOKEN }}
GCLIENT_EXTRA_ARGS: ${{ inputs.target-platform == 'macos' &&
'--custom-var=checkout_mac=True --custom-var=host_os=mac' ||
inputs.target-platform == 'win' && '--custom-var=checkout_win=True' ||
'--custom-var=checkout_arm=True --custom-var=checkout_arm64=True' }}
ELECTRON_OUT_DIR: Default
ACTIONS_STEP_DEBUG: ${{ secrets.ACTIONS_STEP_DEBUG }}
jobs:
build:
defaults:
run:
shell: bash
runs-on: ${{ inputs.build-runs-on }}
permissions:
artifact-metadata: write
attestations: write
contents: read
id-token: write
container: ${{ fromJSON(inputs.build-container) }}
environment: ${{ inputs.environment }}
env:
TARGET_ARCH: ${{ inputs.target-arch }}
TARGET_PLATFORM: ${{ inputs.target-platform }}
steps:
- name: Create src dir
run: |
mkdir src
- name: Checkout Electron
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd
with:
path: src/electron
fetch-depth: 0
ref: ${{ github.event.pull_request.head.sha }}
- name: Setup SSH Debugging
if: ${{ inputs.target-platform == 'macos' && (inputs.enable-ssh ||
env.ACTIONS_STEP_DEBUG == 'true') }}
uses: ./src/electron/.github/actions/ssh-debug
with:
tunnel: "true"
env:
CLOUDFLARE_TUNNEL_CERT: ${{ secrets.CLOUDFLARE_TUNNEL_CERT }}
CLOUDFLARE_TUNNEL_HOSTNAME: ${{ vars.CLOUDFLARE_TUNNEL_HOSTNAME }}
CLOUDFLARE_USER_CA_CERT: ${{ secrets.CLOUDFLARE_USER_CA_CERT }}
AUTHORIZED_USERS: ${{ secrets.SSH_DEBUG_AUTHORIZED_USERS }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Free up space (macOS)
if: ${{ inputs.target-platform == 'macos' }}
uses: ./src/electron/.github/actions/free-space-macos
- name: Check disk space after freeing up space
if: ${{ inputs.target-platform == 'macos' }}
run: df -h
- name: Setup Node.js/npm
if: ${{ inputs.target-platform == 'macos' }}
uses: actions/setup-node@6044e13b5dc448c55e2357c09f80417699197238
with:
node-version: 22.21.x
cache: yarn
cache-dependency-path: src/electron/yarn.lock
- name: Install Dependencies
uses: ./src/electron/.github/actions/install-dependencies
- name: Install AZCopy
if: ${{ inputs.target-platform == 'macos' }}
run: brew install azcopy
- name: Set GN_EXTRA_ARGS for Linux
if: ${{ inputs.target-platform == 'linux' }}
run: >
if [ "${{ inputs.target-arch }}" = "arm" ]; then
if [ "${{ inputs.is-release }}" = true ]; then
GN_EXTRA_ARGS='target_cpu="arm" build_tflite_with_xnnpack=false symbol_level=1'
else
GN_EXTRA_ARGS='target_cpu="arm" build_tflite_with_xnnpack=false'
fi
elif [ "${{ inputs.target-arch }}" = "arm64" ]; then
GN_EXTRA_ARGS='target_cpu="arm64" fatal_linker_warnings=false enable_linux_installer=false'
elif [ "${{ inputs.is-asan }}" = true ]; then
GN_EXTRA_ARGS='is_asan=true'
fi
echo "GN_EXTRA_ARGS=$GN_EXTRA_ARGS" >> $GITHUB_ENV
- name: Set Chromium Git Cookie
uses: ./src/electron/.github/actions/set-chromium-cookie
- name: Install Build Tools
uses: ./src/electron/.github/actions/install-build-tools
- name: Generate DEPS Hash
run: |
node src/electron/script/generate-deps-hash.js
DEPSHASH=v1-src-cache-$(cat src/electron/.depshash)
echo "DEPSHASH=$DEPSHASH" >> $GITHUB_ENV
echo "CACHE_PATH=$DEPSHASH.tar" >> $GITHUB_ENV
- name: Restore src cache via AZCopy
if: ${{ inputs.target-platform != 'linux' }}
uses: ./src/electron/.github/actions/restore-cache-azcopy
with:
target-platform: ${{ inputs.target-platform }}
- name: Restore src cache via AKS
if: ${{ inputs.target-platform == 'linux' }}
uses: ./src/electron/.github/actions/restore-cache-aks
- name: Checkout Electron
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd
with:
path: src/electron
fetch-depth: 0
ref: ${{ github.event.pull_request.head.sha }}
- name: Fix Sync
if: ${{ inputs.target-platform != 'linux' }}
uses: ./src/electron/.github/actions/fix-sync
with:
target-platform: ${{ inputs.target-platform }}
env:
ELECTRON_DEPOT_TOOLS_DISABLE_LOG: true
- name: Init Build Tools
run: >
e init -f --root=$(pwd) --out=Default ${{ inputs.gn-build-type }}
--import ${{ inputs.gn-build-type }} --target-cpu ${{
inputs.target-arch }} --remote-build siso
- name: Run Electron Only Hooks
run: |
e d gclient runhooks --spec="solutions=[{'name':'src/electron','url':None,'deps_file':'DEPS','custom_vars':{'process_deps':False},'managed':False}]"
- name: Regenerate DEPS Hash
run: >
(cd src/electron && git checkout .) && node
src/electron/script/generate-deps-hash.js
echo "DEPSHASH=$(cat src/electron/.depshash)" >> $GITHUB_ENV
- name: Add CHROMIUM_BUILDTOOLS_PATH to env
run: echo "CHROMIUM_BUILDTOOLS_PATH=$(pwd)/src/buildtools" >> $GITHUB_ENV
- name: Free up space (macOS)
if: ${{ inputs.target-platform == 'macos' }}
uses: ./src/electron/.github/actions/free-space-macos
- name: Build Electron
if: ${{ inputs.target-platform != 'macos' || (inputs.target-variant == 'all' ||
inputs.target-variant == 'darwin') }}
uses: ./src/electron/.github/actions/build-electron
with:
target-arch: ${{ inputs.target-arch }}
target-platform: ${{ inputs.target-platform }}
artifact-platform: ${{ inputs.target-platform == 'macos' && 'darwin' ||
inputs.target-platform }}
is-release: ${{ inputs.is-release }}
generate-symbols: ${{ inputs.generate-symbols }}
upload-to-storage: ${{ inputs.upload-to-storage }}
is-asan: ${{ inputs.is-asan }}
upload-out-gen-artifacts: ${{ inputs.upload-out-gen-artifacts }}
- name: Set GN_EXTRA_ARGS for MAS Build
if: ${{ inputs.target-platform == 'macos' && (inputs.target-variant == 'all' ||
inputs.target-variant == 'mas') }}
run: |
echo "MAS_BUILD=true" >> $GITHUB_ENV
GN_EXTRA_ARGS='is_mas_build=true'
echo "GN_EXTRA_ARGS=$GN_EXTRA_ARGS" >> $GITHUB_ENV
- name: Build Electron (MAS)
if: ${{ inputs.target-platform == 'macos' && (inputs.target-variant == 'all' ||
inputs.target-variant == 'mas') }}
uses: ./src/electron/.github/actions/build-electron
with:
target-arch: ${{ inputs.target-arch }}
target-platform: ${{ inputs.target-platform }}
artifact-platform: mas
is-release: ${{ inputs.is-release }}
generate-symbols: ${{ inputs.generate-symbols }}
upload-to-storage: ${{ inputs.upload-to-storage }}
step-suffix: (mas)

View File

@@ -25,19 +25,24 @@ on:
required: false
type: boolean
default: false
enable-ssh:
description: 'Enable SSH debugging'
required: false
type: boolean
default: false
concurrency:
group: electron-test-${{ inputs.target-platform }}-${{ inputs.target-arch }}-${{ inputs.is-asan }}-${{ github.ref }}
cancel-in-progress: ${{ github.ref != 'refs/heads/main' && !endsWith(github.ref, '-x-y') }}
group: electron-test-${{ inputs.target-platform }}-${{ inputs.target-arch }}-${{ inputs.is-asan }}-${{ github.ref_protected == true && github.run_id || github.ref }}
cancel-in-progress: ${{ github.ref_protected != true }}
permissions:
contents: read
issues: read
pull-requests: read
permissions: {}
env:
CHROMIUM_GIT_COOKIE: ${{ secrets.CHROMIUM_GIT_COOKIE }}
CHROMIUM_GIT_COOKIE_WINDOWS_STRING: ${{ secrets.CHROMIUM_GIT_COOKIE_WINDOWS_STRING }}
ELECTRON_OUT_DIR: Default
ELECTRON_RBE_JWT: ${{ secrets.ELECTRON_RBE_JWT }}
ACTIONS_STEP_DEBUG: ${{ secrets.ACTIONS_STEP_DEBUG }}
jobs:
test:
@@ -45,6 +50,10 @@ jobs:
run:
shell: bash
runs-on: ${{ inputs.test-runs-on }}
permissions:
contents: read
issues: read
pull-requests: read
container: ${{ fromJSON(inputs.test-container) }}
strategy:
fail-fast: false
@@ -60,28 +69,16 @@ jobs:
if: ${{ inputs.target-arch == 'arm' && inputs.target-platform == 'linux' }}
run: |
cp $(which node) /mnt/runner-externals/node20/bin/
- name: Install Git on Windows arm64 runners
if: ${{ inputs.target-arch == 'arm64' && inputs.target-platform == 'win' }}
shell: powershell
run: |
Set-ExecutionPolicy Bypass -Scope Process -Force
[System.Net.ServicePointManager]::SecurityProtocol = [System.Net.ServicePointManager]::SecurityProtocol -bor 3072
iex ((New-Object System.Net.WebClient).DownloadString('https://community.chocolatey.org/install.ps1'))
choco install -y --no-progress git.install --params "'/GitAndUnixToolsOnPath'"
choco install -y --no-progress git
choco install -y --no-progress python --version 3.11.9
choco install -y --no-progress visualstudio2022-workload-vctools --package-parameters "--add Microsoft.VisualStudio.Component.VC.Tools.ARM64"
echo "C:\Program Files\Git\cmd" | Out-File -FilePath $env:GITHUB_PATH -Encoding utf8 -Append
echo "C:\Program Files\Git\bin" | Out-File -FilePath $env:GITHUB_PATH -Encoding utf8 -Append
echo "C:\Python311" | Out-File -FilePath $env:GITHUB_PATH -Encoding utf8 -Append
cp $(which node) /mnt/runner-externals/node24/bin/
- name: Setup Node.js/npm
if: ${{ inputs.target-platform == 'win' }}
uses: actions/setup-node@0a44ba7841725637a19e28fa30b79a866c81b0a6
uses: actions/setup-node@6044e13b5dc448c55e2357c09f80417699197238
with:
node-version: 20.11.x
node-version: 22.21.x
- name: Add TCC permissions on macOS
if: ${{ inputs.target-platform == 'macos' }}
run: |
epochdate=$(($(date +'%s * 1000 + %-N / 1000000')))
configure_user_tccdb () {
local values=$1
local dbPath="$HOME/Library/Application Support/com.apple.TCC/TCC.db"
@@ -97,14 +94,17 @@ jobs:
}
userValuesArray=(
"'kTCCServiceMicrophone','/usr/local/opt/runner/provisioner/provisioner',1,2,4,1,NULL,NULL,0,'UNUSED',NULL,0,1687786159"
"'kTCCServiceCamera','/usr/local/opt/runner/provisioner/provisioner',1,2,4,1,NULL,NULL,0,'UNUSED',NULL,0,1687786159"
"'kTCCServiceBluetoothAlways','/usr/local/opt/runner/provisioner/provisioner',1,2,4,1,NULL,NULL,0,'UNUSED',NULL,0,1687786159"
"'kTCCServiceAppleEvents','/usr/local/opt/runner/provisioner/provisioner',1,2,4,1,NULL,NULL,0,'UNUSED',NULL,0,1687786159"
"'kTCCServiceCamera','/opt/hca/hosted-compute-agent',1,2,4,1,NULL,NULL,0,'UNUSED',NULL,0,1687786159"
"'kTCCServiceBluetoothAlways','/opt/hca/hosted-compute-agent',1,2,4,1,NULL,NULL,0,'UNUSED',NULL,0,1687786159"
"'kTCCServiceScreenCapture','/bin/bash',1,2,3,1,NULL,NULL,NULL,'UNUSED',NULL,0,$epochdate"
)
for values in "${userValuesArray[@]}"; do
# Sonoma and higher have a few extra values
# Ref: https://github.com/actions/runner-images/blob/main/images/macos/scripts/build/configure-tccdb-macos.sh
if [ "$OSTYPE" = "darwin23" ]; then
if [ "$OSTYPE" = "darwin23" ] || [ "$OSTYPE" = "darwin24" ]; then
configure_user_tccdb "$values,NULL,NULL,'UNUSED',${values##*,}"
configure_sys_tccdb "$values,NULL,NULL,'UNUSED',${values##*,}"
else
@@ -112,20 +112,49 @@ jobs:
configure_sys_tccdb "$values"
fi
done
- name: Turn off the unexpectedly quit dialog on macOS
if: ${{ inputs.target-platform == 'macos' }}
run: defaults write com.apple.CrashReporter DialogType server
- name: Set xcode to 16.4
if: ${{ inputs.target-platform == 'macos' }}
run: sudo xcode-select --switch /Applications/Xcode_16.4.app
- name: Checkout Electron
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd
with:
path: src/electron
fetch-depth: 0
ref: ${{ github.event.pull_request.head.sha }}
- name: Turn off screenshot nag on macOS
if: ${{ inputs.target-platform == 'macos' }}
run: |
defaults write ~/Library/Group\ Containers/group.com.apple.replayd/ScreenCaptureApprovals.plist "/bin/bash" -date "3024-09-23 12:00:00 +0000"
src/electron/script/actions/screencapture-nag-remover.sh -a $(which bash)
src/electron/script/actions/screencapture-nag-remover.sh -a /opt/hca/hosted-compute-agent
- name: Setup SSH Debugging
if: ${{ inputs.target-platform == 'macos' && (inputs.enable-ssh || env.ACTIONS_STEP_DEBUG == 'true') }}
uses: ./src/electron/.github/actions/ssh-debug
with:
tunnel: 'true'
env:
CLOUDFLARE_TUNNEL_CERT: ${{ secrets.CLOUDFLARE_TUNNEL_CERT }}
CLOUDFLARE_TUNNEL_HOSTNAME: ${{ vars.CLOUDFLARE_TUNNEL_HOSTNAME }}
CLOUDFLARE_USER_CA_CERT: ${{ secrets.CLOUDFLARE_USER_CA_CERT }}
AUTHORIZED_USERS: ${{ secrets.SSH_DEBUG_AUTHORIZED_USERS }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Install Dependencies
uses: ./src/electron/.github/actions/install-dependencies
- name: Set Chromium Git Cookie
uses: ./src/electron/.github/actions/set-chromium-cookie
- name: Get Depot Tools
timeout-minutes: 5
run: |
git config --global core.filemode false
git config --global core.autocrlf false
git config --global branch.autosetuprebase always
git config --global core.fscache true
git config --global core.longpaths true
git config --global core.preloadindex true
git config --global core.longpaths true
git clone --filter=tree:0 https://chromium.googlesource.com/chromium/tools/depot_tools.git
# Ensure depot_tools does not update.
test -d depot_tools && cd depot_tools
@@ -139,50 +168,42 @@ jobs:
echo "DISABLE_CRASH_REPORTER_TESTS=true" >> $GITHUB_ENV
echo "IS_ASAN=true" >> $GITHUB_ENV
- name: Download Generated Artifacts
uses: actions/download-artifact@fa0a91b85d4f404e444e00e005971372dc801d16
uses: actions/download-artifact@37930b1c2abaa49bbe596cd826c3c89aef350131
with:
name: generated_artifacts_${{ env.ARTIFACT_KEY }}
path: ./generated_artifacts_${{ matrix.build-type }}_${{ inputs.target-arch }}
- name: Download Src Artifacts
uses: actions/download-artifact@fa0a91b85d4f404e444e00e005971372dc801d16
uses: actions/download-artifact@37930b1c2abaa49bbe596cd826c3c89aef350131
with:
name: src_artifacts_${{ env.ARTIFACT_KEY }}
path: ./src_artifacts_${{ matrix.build-type }}_${{ inputs.target-arch }}
- name: Restore Generated Artifacts
run: ./src/electron/script/actions/restore-artifacts.sh
- name: Unzip Dist, Mksnapshot & Chromedriver (win)
- name: Unzip Dist (win)
if: ${{ inputs.target-platform == 'win' }}
shell: powershell
run: |
Set-ExecutionPolicy Bypass -Scope Process -Force
cd src/out/Default
Expand-Archive -Force dist.zip -DestinationPath ./
Expand-Archive -Force chromedriver.zip -DestinationPath ./
Expand-Archive -Force mksnapshot.zip -DestinationPath ./
- name: Unzip Dist, Mksnapshot & Chromedriver (unix)
- name: Unzip Dist (unix)
if: ${{ inputs.target-platform != 'win' }}
run: |
cd src/out/Default
unzip -:o dist.zip
unzip -:o chromedriver.zip
unzip -:o mksnapshot.zip
- name: Import & Trust Self-Signed Codesigning Cert on MacOS
if: ${{ inputs.target-platform == 'macos' && inputs.target-arch == 'x64' }}
run: |
sudo security authorizationdb write com.apple.trust-settings.admin allow
cd src/electron
./script/codesign/generate-identity.sh
- name: Install Datadog CLI
run: |
cd src/electron
node script/yarn global add @datadog/datadog-ci
#- name: Import & Trust Self-Signed Codesigning Cert on MacOS
# if: ${{ inputs.target-platform == 'macos' && inputs.target-arch == 'x64' }}
# run: |
# sudo security authorizationdb write com.apple.trust-settings.admin allow
# cd src/electron
# ./script/codesign/generate-identity.sh
- name: Run Electron Tests
shell: bash
env:
MOCHA_REPORTER: mocha-multi-reporters
MOCHA_MULTI_REPORTERS: mocha-junit-reporter, tap
ELECTRON_DISABLE_SECURITY_WARNINGS: 1
ELECTRON_SKIP_NATIVE_MODULE_TESTS: true
DISPLAY: ':99.0'
NPM_CONFIG_MSVS_VERSION: '2022'
run: |
@@ -202,7 +223,7 @@ jobs:
export ELECTRON_FORCE_TEST_SUITE_EXIT="true"
fi
fi
node script/yarn test --runners=main --trace-uncaught --enable-logging --files $tests_files
node script/yarn.js test --runners=main --enableRerun=3 --trace-uncaught --enable-logging --files $tests_files
else
chown :builduser .. && chmod g+w ..
chown -R :builduser . && chmod -R g+w .
@@ -219,9 +240,14 @@ jobs:
export MOCHA_TIMEOUT=180000
echo "Piping output to ASAN_SYMBOLIZE ($ASAN_SYMBOLIZE)"
cd electron
runuser -u builduser -- xvfb-run script/actions/run-tests.sh script/yarn test --runners=main --trace-uncaught --enable-logging --files $tests_files | $ASAN_SYMBOLIZE
runuser -u builduser -- xvfb-run script/actions/run-tests.sh script/yarn.js test --runners=main --trace-uncaught --enable-logging --files $tests_files | $ASAN_SYMBOLIZE
else
runuser -u builduser -- xvfb-run script/actions/run-tests.sh script/yarn test --runners=main --trace-uncaught --enable-logging --files $tests_files
if [ "${{ inputs.target-arch }}" = "arm" ]; then
runuser -u builduser -- xvfb-run script/actions/run-tests.sh script/yarn.js test --skipYarnInstall --runners=main --enableRerun=3 --trace-uncaught --enable-logging --files $tests_files
else
runuser -u builduser -- xvfb-run script/actions/run-tests.sh script/yarn.js test --runners=main --enableRerun=3 --trace-uncaught --enable-logging --files $tests_files
fi
fi
fi
- name: Upload Test results to Datadog
@@ -233,13 +259,14 @@ jobs:
DD_TAGS: "os.architecture:${{ inputs.target-arch }},os.family:${{ inputs.target-platform }},os.platform:${{ inputs.target-platform }},asan:${{ inputs.is-asan }}"
run: |
if ! [ -z $DD_API_KEY ] && [ -f src/electron/junit/test-results-main.xml ]; then
export DATADOG_PATH=`node src/electron/script/yarn global bin`
$DATADOG_PATH/datadog-ci junit upload src/electron/junit/test-results-main.xml
fi
cd src/electron
export DATADOG_PATH=`node script/yarn.js bin datadog-ci`
$DATADOG_PATH junit upload junit/test-results-main.xml
fi
if: always() && !cancelled()
- name: Upload Test Artifacts
if: always() && !cancelled()
uses: actions/upload-artifact@b4b15b8c7c6ac21ea08fcf65892d2ee8f75cf882
uses: actions/upload-artifact@b7c566a772e6b6bfb58ed0dc250532a479d7789f
with:
name: test_artifacts_${{ env.ARTIFACT_KEY }}_${{ matrix.shard }}
path: src/electron/spec/artifacts

View File

@@ -26,30 +26,37 @@ on:
type: string
default: testing
permissions: {}
concurrency:
group: electron-node-nan-test-${{ inputs.target-platform }}-${{ inputs.target-arch }}-${{ github.ref }}
cancel-in-progress: ${{ github.ref != 'refs/heads/main' && !endsWith(github.ref, '-x-y') }}
group: electron-node-nan-test-${{ inputs.target-platform }}-${{ inputs.target-arch }}-${{ github.ref_protected == true && github.run_id || github.ref }}
cancel-in-progress: ${{ github.ref_protected != true }}
env:
CHROMIUM_GIT_COOKIE: ${{ secrets.CHROMIUM_GIT_COOKIE }}
ELECTRON_OUT_DIR: Default
ELECTRON_RBE_JWT: ${{ secrets.ELECTRON_RBE_JWT }}
jobs:
node-tests:
name: Run Node.js Tests
runs-on: electron-arc-linux-amd64-8core
timeout-minutes: 20
runs-on: electron-arc-centralus-linux-amd64-8core
permissions:
contents: read
timeout-minutes: 30
env:
TARGET_ARCH: ${{ inputs.target-arch }}
BUILD_TYPE: linux
container: ${{ fromJSON(inputs.test-container) }}
steps:
- name: Checkout Electron
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd
with:
path: src/electron
fetch-depth: 0
ref: ${{ github.event.pull_request.head.sha }}
- name: Set Chromium Git Cookie
uses: ./src/electron/.github/actions/set-chromium-cookie
- name: Install Build Tools
uses: ./src/electron/.github/actions/install-build-tools
- name: Init Build Tools
@@ -57,22 +64,13 @@ jobs:
e init -f --root=$(pwd) --out=Default ${{ inputs.gn-build-type }} --import ${{ inputs.gn-build-type }} --target-cpu ${{ inputs.target-arch }}
- name: Install Dependencies
uses: ./src/electron/.github/actions/install-dependencies
- name: Get Depot Tools
timeout-minutes: 5
run: |
git clone --filter=tree:0 https://chromium.googlesource.com/chromium/tools/depot_tools.git
# Ensure depot_tools does not update.
test -d depot_tools && cd depot_tools
touch .disable_auto_update
- name: Add Depot Tools to PATH
run: echo "$(pwd)/depot_tools" >> $GITHUB_PATH
- name: Download Generated Artifacts
uses: actions/download-artifact@fa0a91b85d4f404e444e00e005971372dc801d16
uses: actions/download-artifact@37930b1c2abaa49bbe596cd826c3c89aef350131
with:
name: generated_artifacts_${{ env.BUILD_TYPE }}_${{ env.TARGET_ARCH }}
path: ./generated_artifacts_${{ env.BUILD_TYPE }}_${{ env.TARGET_ARCH }}
- name: Download Src Artifacts
uses: actions/download-artifact@fa0a91b85d4f404e444e00e005971372dc801d16
uses: actions/download-artifact@37930b1c2abaa49bbe596cd826c3c89aef350131
with:
name: src_artifacts_linux_${{ env.TARGET_ARCH }}
path: ./src_artifacts_linux_${{ env.TARGET_ARCH }}
@@ -98,19 +96,23 @@ jobs:
done
nan-tests:
name: Run Nan Tests
runs-on: electron-arc-linux-amd64-4core
timeout-minutes: 20
runs-on: electron-arc-centralus-linux-amd64-4core
permissions:
contents: read
timeout-minutes: 30
env:
TARGET_ARCH: ${{ inputs.target-arch }}
BUILD_TYPE: linux
container: ${{ fromJSON(inputs.test-container) }}
steps:
- name: Checkout Electron
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd
with:
path: src/electron
fetch-depth: 0
ref: ${{ github.event.pull_request.head.sha }}
- name: Set Chromium Git Cookie
uses: ./src/electron/.github/actions/set-chromium-cookie
- name: Install Build Tools
uses: ./src/electron/.github/actions/install-build-tools
- name: Init Build Tools
@@ -118,22 +120,13 @@ jobs:
e init -f --root=$(pwd) --out=Default ${{ inputs.gn-build-type }}
- name: Install Dependencies
uses: ./src/electron/.github/actions/install-dependencies
- name: Get Depot Tools
timeout-minutes: 5
run: |
git clone --filter=tree:0 https://chromium.googlesource.com/chromium/tools/depot_tools.git
# Ensure depot_tools does not update.
test -d depot_tools && cd depot_tools
touch .disable_auto_update
- name: Add Depot Tools to PATH
run: echo "$(pwd)/depot_tools" >> $GITHUB_PATH
- name: Download Generated Artifacts
uses: actions/download-artifact@fa0a91b85d4f404e444e00e005971372dc801d16
uses: actions/download-artifact@37930b1c2abaa49bbe596cd826c3c89aef350131
with:
name: generated_artifacts_${{ env.BUILD_TYPE }}_${{ env.TARGET_ARCH }}
path: ./generated_artifacts_${{ env.BUILD_TYPE }}_${{ env.TARGET_ARCH }}
- name: Download Src Artifacts
uses: actions/download-artifact@fa0a91b85d4f404e444e00e005971372dc801d16
uses: actions/download-artifact@37930b1c2abaa49bbe596cd826c3c89aef350131
with:
name: src_artifacts_linux_${{ env.TARGET_ARCH }}
path: ./src_artifacts_linux_${{ env.TARGET_ARCH }}
@@ -145,10 +138,16 @@ jobs:
unzip -:o dist.zip
- name: Setup Linux for Headless Testing
run: sh -e /etc/init.d/xvfb start
- name: Add Clang problem matcher
shell: bash
run: echo "::add-matcher::src/electron/.github/problem-matchers/clang.json"
- name: Run Nan Tests
run: |
cd src
node electron/script/nan-spec-runner.js
- name: Remove Clang problem matcher
shell: bash
run: echo "::remove-matcher owner=clang::"
- name: Wait for active SSH sessions
shell: bash
if: always() && !cancelled()

View File

@@ -11,31 +11,68 @@ jobs:
name: backport/requested label added
if: github.event.label.name == 'backport/requested 🗳'
runs-on: ubuntu-latest
permissions: {}
steps:
- name: Trigger Slack workflow
uses: slackapi/slack-github-action@485a9d42d3a73031f12ec201c457e2162c45d02d # v2.0.0
uses: slackapi/slack-github-action@91efab103c0de0a537f72a35f6b8cda0ee76bf0a # v2.1.1
with:
webhook: ${{ secrets.BACKPORT_REQUESTED_SLACK_WEBHOOK_URL }}
webhook-type: webhook-trigger
payload: |
{
"url": "${{ github.event.pull_request.html_url }}"
"base_ref": ${{ toJSON(github.event.pull_request.base.ref) }},
"title": ${{ toJSON(github.event.pull_request.title) }},
"url": ${{ toJSON(github.event.pull_request.html_url) }},
"user": ${{ toJSON(github.event.pull_request.user.login) }}
}
env:
SLACK_WEBHOOK_URL: ${{ secrets.BACKPORT_REQUESTED_SLACK_WEBHOOK_URL }}
pull-request-labeled-deprecation-review-complete:
name: deprecation-review/complete label added
if: github.event.label.name == 'deprecation-review/complete ✅'
runs-on: ubuntu-latest
permissions: {}
steps:
- name: Generate GitHub App token
uses: electron/github-app-auth-action@384fd19694fe7b6dcc9a684746c6976ad78228ae # v1.1.1
uses: electron/github-app-auth-action@e14e47722ed120360649d0789e25b9baece12725 # v2.0.0
id: generate-token
with:
creds: ${{ secrets.RELEASE_BOARD_GH_APP_CREDS }}
org: electron
- name: Set status
uses: dsanders11/project-actions/edit-item@438b25e007c2f4efec324497fadc6402e7cc61a6 # v1.4.0
uses: dsanders11/project-actions/edit-item@2134fe7cc71c58b7ae259c82a8e63c6058255678 # v1.7.0
with:
token: ${{ steps.generate-token.outputs.token }}
project-number: 94
field: Status
field-value: ✅ Reviewed
pull-request-labeled-ai-pr:
name: ai-pr label added
if: github.event.label.name == 'ai-pr'
runs-on: ubuntu-latest
permissions: {}
steps:
- name: Generate GitHub App token
uses: electron/github-app-auth-action@e14e47722ed120360649d0789e25b9baece12725 # v2.0.0
id: generate-token
with:
creds: ${{ secrets.ISSUE_TRIAGE_GH_APP_CREDS }}
- name: Create comment
uses: actions-cool/issues-helper@e2ff99831a4f13625d35064e2b3dfe65c07a0396 # v3.7.5
with:
actions: 'create-comment'
token: ${{ steps.generate-token.outputs.token }}
issue-number: ${{ github.event.pull_request.number }}
body: |
<!-- ai-pr -->
*AI PR Detected*
Hello @${{ github.event.pull_request.user.login }}. Due to the high amount of AI spam PRs we receive, if a PR is detected to be majority AI-generated without disclosure and untested, we will automatically close the PR.
We welcome the use of AI tools, as long as the PR meets our quality standards and has clearly been built and tested. If you believe your PR was closed in error, we welcome you to resubmit. However, please read our [CONTRIBUTING.md](http://contributing.md/) carefully before reopening. Thanks for your contribution.
- name: Close the pull request
env:
GITHUB_TOKEN: ${{ steps.generate-token.outputs.token }}
GH_REPO: electron/electron
PR_NUMBER: ${{ github.event.pull_request.number }}
run: |
gh pr close "$PR_NUMBER"

View File

@@ -0,0 +1,71 @@
name: Rerun PR Apply Patches
on:
push:
branches:
- main
- '[1-9][0-9]-x-y'
paths:
- 'DEPS'
- 'patches/**'
permissions: {}
jobs:
rerun-apply-patches:
runs-on: ubuntu-latest
permissions:
actions: write
checks: read
contents: read
pull-requests: read
steps:
- name: Find PRs and Rerun Apply Patches
env:
GH_REPO: ${{ github.repository }}
GH_TOKEN: ${{ github.token }}
run: |
BRANCH="${GITHUB_REF#refs/heads/}"
# Find all open PRs targeting this branch
PRS=$(gh pr list --base "$BRANCH" --state open --limit 250 --json number)
echo "$PRS" | jq -c '.[]' | while read -r pr; do
PR_NUMBER=$(echo "$pr" | jq -r '.number')
echo "Processing PR #${PR_NUMBER}"
# Find the Apply Patches workflow check for this PR
CHECK=$(gh pr view "$PR_NUMBER" --json statusCheckRollup --jq '[.statusCheckRollup[] | select(.workflowName == "Apply Patches" and .name == "apply-patches")] | first')
if [ -z "$CHECK" ] || [ "$CHECK" = "null" ]; then
echo " No Apply Patches workflow found for PR #${PR_NUMBER}"
continue
fi
CONCLUSION=$(echo "$CHECK" | jq -r '.conclusion')
if [ "$CONCLUSION" = "SKIPPED" ]; then
echo " apply-patches job was skipped for PR #${PR_NUMBER} (no patches)"
continue
fi
LINK=$(echo "$CHECK" | jq -r '.detailsUrl')
# Extract the run ID from the link (format: .../runs/RUN_ID/job/JOB_ID)
RUN_ID=$(echo "$LINK" | grep -oE 'runs/[0-9]+' | cut -d'/' -f2)
if [ -z "$RUN_ID" ]; then
echo " Could not extract run ID from link: ${LINK}"
continue
fi
# Check if the workflow is currently in progress
RUN_STATUS=$(gh run view "$RUN_ID" --json status --jq '.status')
if [ "$RUN_STATUS" = "in_progress" ] || [ "$RUN_STATUS" = "queued" ] || [ "$RUN_STATUS" = "waiting" ]; then
echo " Workflow run ${RUN_ID} is ${RUN_STATUS}, cancelling..."
gh run cancel "$RUN_ID" --force
gh run watch "$RUN_ID"
fi
gh run rerun "$RUN_ID"
done

View File

@@ -13,6 +13,7 @@ permissions: read-all
jobs:
analysis:
name: Scorecards analysis
if: github.repository == 'electron/electron'
runs-on: ubuntu-latest
permissions:
# Needed to upload the results to code-scanning dashboard.
@@ -22,13 +23,13 @@ jobs:
steps:
- name: "Checkout code"
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
with:
persist-credentials: false
# This is a pre-submit / pre-release.
- name: "Run analysis"
uses: ossf/scorecard-action@62b2cac7ed8198b15735ed49ab1e5cf35480ba46 # v2.4.0
uses: ossf/scorecard-action@4eaacf0543bb3f2c246792bd56e8cdeffafb205a # v2.4.3
with:
results_file: results.sarif
results_format: sarif
@@ -42,7 +43,7 @@ jobs:
# Upload the results as artifacts (optional). Commenting out will disable uploads of run results in SARIF
# format to the repository Actions tab.
- name: "Upload artifact"
uses: actions/upload-artifact@b4b15b8c7c6ac21ea08fcf65892d2ee8f75cf882 # v4.4.3
uses: actions/upload-artifact@b7c566a772e6b6bfb58ed0dc250532a479d7789f # v6.0.0
with:
name: SARIF file
path: results.sarif
@@ -50,6 +51,6 @@ jobs:
# Upload the results to GitHub's code scanning dashboard.
- name: "Upload to code-scanning"
uses: github/codeql-action/upload-sarif@df409f7d9260372bd5f19e5b04e83cb3c43714ae # v3.27.9
uses: github/codeql-action/upload-sarif@45cbd0c69e560cd9e7cd7f8c32362050c9b7ded2 # v3.29.5
with:
sarif_file: results.sarif

View File

@@ -7,8 +7,7 @@ on:
- edited
- synchronize
permissions:
contents: read
permissions: {}
jobs:
main:
@@ -19,7 +18,7 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: semantic-pull-request
uses: amannn/action-semantic-pull-request@0723387faaf9b38adef4775cd42cfd5155ed6017 # v5.5.3
uses: amannn/action-semantic-pull-request@48f256284bd46cdaab1048c3721360e808335d50 # v6.1.1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:

View File

@@ -10,10 +10,12 @@ permissions: {}
jobs:
check-stable-prep-items:
name: Check Stable Prep Items
if: github.repository == 'electron/electron'
runs-on: ubuntu-latest
permissions: {}
steps:
- name: Generate GitHub App token
uses: electron/github-app-auth-action@384fd19694fe7b6dcc9a684746c6976ad78228ae # v1.1.1
uses: electron/github-app-auth-action@e14e47722ed120360649d0789e25b9baece12725 # v2.0.0
id: generate-token
with:
creds: ${{ secrets.RELEASE_BOARD_GH_APP_CREDS }}
@@ -27,7 +29,7 @@ jobs:
PROJECT_NUMBER=$(gh project list --owner electron --format json | jq -r '.projects | map(select(.title | test("^[0-9]+-x-y$"))) | max_by(.number) | .number')
echo "PROJECT_NUMBER=$PROJECT_NUMBER" >> "$GITHUB_OUTPUT"
- name: Update Completed Stable Prep Items
uses: dsanders11/project-actions/completed-by@438b25e007c2f4efec324497fadc6402e7cc61a6 # v1.4.0
uses: dsanders11/project-actions/completed-by@2134fe7cc71c58b7ae259c82a8e63c6058255678 # v1.7.0
with:
field: Prep Status
field-value: ✅ Complete

View File

@@ -9,14 +9,16 @@ permissions: {}
jobs:
stale:
if: github.repository == 'electron/electron'
runs-on: ubuntu-latest
permissions: {}
steps:
- name: Generate GitHub App token
uses: electron/github-app-auth-action@384fd19694fe7b6dcc9a684746c6976ad78228ae # v1.1.1
uses: electron/github-app-auth-action@e14e47722ed120360649d0789e25b9baece12725 # v2.0.0
id: generate-token
with:
creds: ${{ secrets.ISSUE_TRIAGE_GH_APP_CREDS }}
- uses: actions/stale@28ca1036281a5e5922ead5184a1bbf96e5fc984e # tag: v9.0.0
- uses: actions/stale@997185467fa4f803885201cee163a9f38240193d # tag: v10.1.1
with:
repo-token: ${{ steps.generate-token.outputs.token }}
days-before-stale: 90
@@ -27,19 +29,20 @@ jobs:
This issue has been automatically marked as stale. **If this issue is still affecting you, please leave any comment** (for example, "bump"), and we'll keep it open. If you have any new additional information—in particular, if this is still reproducible in the [latest version of Electron](https://www.electronjs.org/releases/stable) or in the [beta](https://www.electronjs.org/releases/beta)—please include it with your comment!
close-issue-message: >
This issue has been closed due to inactivity, and will not be monitored. If this is a bug and you can reproduce this issue on a [supported version of Electron](https://www.electronjs.org/docs/latest/tutorial/electron-timelines#timeline) please open a new issue and include instructions for reproducing the issue.
exempt-issue-labels: "discussion,security \U0001F512,enhancement :sparkles:,status/confirmed,stale-exempt"
exempt-issue-labels: "discussion,security \U0001F512,enhancement :sparkles:,status/confirmed,stale-exempt,upgrade-follow-up,tracking-upstream"
only-pr-labels: not-a-real-label
pending-repro:
runs-on: ubuntu-latest
if: ${{ always() }}
permissions: {}
if: ${{ always() && github.repository == 'electron/electron' }}
needs: stale
steps:
- name: Generate GitHub App token
uses: electron/github-app-auth-action@384fd19694fe7b6dcc9a684746c6976ad78228ae # v1.1.1
uses: electron/github-app-auth-action@e14e47722ed120360649d0789e25b9baece12725 # v2.0.0
id: generate-token
with:
creds: ${{ secrets.ISSUE_TRIAGE_GH_APP_CREDS }}
- uses: actions/stale@28ca1036281a5e5922ead5184a1bbf96e5fc984e # tag: v9.0.0
- uses: actions/stale@997185467fa4f803885201cee163a9f38240193d # tag: v10.1.1
with:
repo-token: ${{ steps.generate-token.outputs.token }}
days-before-stale: -1

View File

@@ -0,0 +1,39 @@
name: Update Website Docs
on:
release:
types: [published]
permissions: {}
jobs:
update-website-docs:
name: Update Website Docs
runs-on: ubuntu-latest
environment: website-docs-updater
permissions:
contents: read
id-token: write # needed for secret-service-action
steps:
- name: Get GitHub App token
id: secret-service
uses: electron/secret-service-action@3476425e8b30555aac15b1b7096938e254b0e155 # v1.0.0
- name: Check if this release is the latest
id: check-if-latest-release
env:
GH_REPO: electron/electron
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
LATEST_RELEASE_TAG="$(gh release view --json tagName --jq '.tagName')"
if [ "$LATEST_RELEASE_TAG" = "${GITHUB_REF#refs/tags/}" ]; then
echo "isLatestRelease=true" >> $GITHUB_OUTPUT
else
echo "isLatestRelease=false" >> $GITHUB_OUTPUT
fi
- name: Trigger website docs update
if: ${{ steps.check-if-latest-release.outputs.isLatestRelease }}
env:
GH_REPO: electron/website
GH_TOKEN: ${{ fromJSON(steps.secret-service.outputs.secrets).WEBSITE_DOCS_UPDATER_APP_TOKEN }}
run: |
gh workflow run update-docs.yml -f sha=$GITHUB_SHA

View File

@@ -1,78 +0,0 @@
name: Update AppVeyor Image
# Run chron daily Mon-Fri
on:
workflow_dispatch:
schedule:
- cron: '0 8 * * 1-5' # runs 8:00 every business day (see https://crontab.guru)
permissions: {}
jobs:
bake-appveyor-image:
name: Bake AppVeyor Image
runs-on: ubuntu-latest
steps:
- name: Generate GitHub App token
uses: electron/github-app-auth-action@384fd19694fe7b6dcc9a684746c6976ad78228ae # v1.1.1
id: generate-token
with:
creds: ${{ secrets.APPVEYOR_UPDATER_GH_APP_CREDS }}
- name: Checkout
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
with:
fetch-depth: 0
token: ${{ steps.generate-token.outputs.token }}
ref: ${{ github.event.pull_request.head.sha }}
- name: Setup Node.js
uses: actions/setup-node@39370e3970a6d050c480ffad4ff0ed4d3fdee5af # v4.1.0
with:
node-version: 20.11.x
- name: Yarn install
run: |
node script/yarn.js install --frozen-lockfile
- name: Set Repo for Commit
run: git config --global --add safe.directory $GITHUB_WORKSPACE
- name: Check AppVeyor Image
env:
APPVEYOR_TOKEN: ${{ secrets.APPVEYOR_TOKEN }}
run: |
node ./script/prepare-appveyor
if [ -f ./image_version.txt ]; then
echo "APPVEYOR_IMAGE_VERSION="$(cat image_version.txt)"" >> $GITHUB_ENV
rm image_version.txt
fi
- name: (Optionally) Update Appveyor Image
if: ${{ env.APPVEYOR_IMAGE_VERSION }}
uses: mikefarah/yq@4839dbbf80445070a31c7a9c1055da527db2d5ee # v4.44.6
with:
cmd: |
yq '.image = "${{ env.APPVEYOR_IMAGE_VERSION }}"' "appveyor.yml" > "appveyor2.yml"
yq '.image = "${{ env.APPVEYOR_IMAGE_VERSION }}"' "appveyor-woa.yml" > "appveyor-woa2.yml"
- name: (Optionally) Generate Commit Diff
if: ${{ env.APPVEYOR_IMAGE_VERSION }}
run: |
diff -w -B appveyor.yml appveyor2.yml > appveyor.diff || true
patch -f appveyor.yml < appveyor.diff
rm appveyor2.yml appveyor.diff
git add appveyor.yml
- name: (Optionally) Generate Commit Diff for WOA
if: ${{ env.APPVEYOR_IMAGE_VERSION }}
run: |
diff -w -B appveyor-woa.yml appveyor-woa2.yml > appveyor-woa.diff || true
patch -f appveyor-woa.yml < appveyor-woa.diff
rm appveyor-woa2.yml appveyor-woa.diff
git add appveyor-woa.yml
- name: (Optionally) Commit to Branch
if: ${{ env.APPVEYOR_IMAGE_VERSION }}
uses: dsanders11/github-app-commit-action@43de6da2f4d927e997c0784c7a0b61bd19ad6aac # v1.5.0
with:
message: 'build: update appveyor image to latest version'
ref: bump-appveyor-image
token: ${{ steps.generate-token.outputs.token }}
- name: (Optionally) Create Pull Request
if: ${{ env.APPVEYOR_IMAGE_VERSION }}
run: |
printf "This PR updates appveyor.yml to the latest baked image, ${{ env.APPVEYOR_IMAGE_VERSION }}.\n\nNotes: none" | gh pr create --head bump-appveyor-image --label no-backport --label semver/none --title 'build: update appveyor image to latest version' --body-file=-
env:
GITHUB_TOKEN: ${{ steps.generate-token.outputs.token }}

109
.github/workflows/windows-publish.yml vendored Normal file
View File

@@ -0,0 +1,109 @@
name: Publish Windows
on:
workflow_dispatch:
inputs:
build-image-sha:
type: string
description: 'SHA for electron/build image'
default: 'a82b87d7a4f5ff0cab61405f8151ac4cf4942aeb'
required: true
upload-to-storage:
description: 'Uploads to Azure storage'
required: false
default: '1'
type: string
run-windows-publish:
description: 'Run the publish jobs vs just the build jobs'
type: boolean
default: false
permissions: {}
jobs:
checkout-windows:
if: github.repository == 'electron/electron'
runs-on: electron-arc-centralus-linux-amd64-32core
permissions:
contents: read
container:
image: ghcr.io/electron/build:${{ inputs.build-image-sha }}
options: --user root --device /dev/fuse --cap-add SYS_ADMIN
volumes:
- /mnt/win-cache:/mnt/win-cache
- /var/run/sas:/var/run/sas
env:
CHROMIUM_GIT_COOKIE_WINDOWS_STRING: ${{ secrets.CHROMIUM_GIT_COOKIE_WINDOWS_STRING }}
GCLIENT_EXTRA_ARGS: '--custom-var=checkout_win=True'
TARGET_OS: 'win'
ELECTRON_DEPOT_TOOLS_WIN_TOOLCHAIN: '1'
outputs:
build-image-sha: ${{ inputs.build-image-sha }}
steps:
- name: Checkout Electron
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd
with:
path: src/electron
fetch-depth: 0
- name: Checkout & Sync & Save
uses: ./src/electron/.github/actions/checkout
with:
generate-sas-token: 'true'
target-platform: win
publish-x64-win:
uses: ./.github/workflows/pipeline-segment-electron-publish.yml
permissions:
artifact-metadata: write
attestations: write
contents: read
id-token: write
needs: checkout-windows
with:
environment: production-release
build-runs-on: electron-arc-centralus-windows-amd64-16core
target-platform: win
target-arch: x64
is-release: true
gn-build-type: release
generate-symbols: true
upload-to-storage: ${{ inputs.upload-to-storage }}
secrets: inherit
publish-arm64-win:
uses: ./.github/workflows/pipeline-segment-electron-publish.yml
permissions:
artifact-metadata: write
attestations: write
contents: read
id-token: write
needs: checkout-windows
with:
environment: production-release
build-runs-on: electron-arc-centralus-windows-amd64-16core
target-platform: win
target-arch: arm64
is-release: true
gn-build-type: release
generate-symbols: true
upload-to-storage: ${{ inputs.upload-to-storage }}
secrets: inherit
publish-x86-win:
uses: ./.github/workflows/pipeline-segment-electron-publish.yml
permissions:
artifact-metadata: write
attestations: write
contents: read
id-token: write
needs: checkout-windows
with:
environment: production-release
build-runs-on: electron-arc-centralus-windows-amd64-16core
target-platform: win
target-arch: x86
is-release: true
gn-build-type: release
generate-symbols: true
upload-to-storage: ${{ inputs.upload-to-storage }}
secrets: inherit

2
.gitignore vendored
View File

@@ -53,3 +53,5 @@ ts-gen
patches/mtime-cache.json
spec/fixtures/logo.png
.yarn/install-state.gz

View File

@@ -1,4 +1 @@
#!/bin/sh
. "$(dirname "$0")/_/husky.sh"
npm run precommit

View File

@@ -1,4 +1 @@
#!/bin/sh
. "$(dirname "$0")/_/husky.sh"
npm run prepack

View File

@@ -1,6 +1,7 @@
{
"config": {
"extends": "@electron/lint-roller/configs/markdownlint.json",
"descriptive-link-text": false,
"link-image-style": {
"autolink": false,
"shortcut": false
@@ -20,12 +21,14 @@
"ul",
"unknown",
"Tabs",
"TabItem"
"TabItem",
"DocCardList",
"kbd"
]
},
"no-newline-in-links": true
},
"customRules": [
"@electron/lint-roller/markdownlint-rules/"
"./node_modules/@electron/lint-roller/markdownlint-rules/index.mjs"
]
}

2
.nvmrc
View File

@@ -1 +1 @@
20
22

942
.yarn/releases/yarn-4.12.0.cjs vendored Executable file

File diff suppressed because one or more lines are too long

12
.yarnrc.yml Normal file
View File

@@ -0,0 +1,12 @@
enableScripts: false
nmHoistingLimits: workspaces
nodeLinker: node-modules
npmMinimalAgeGate: 10080
npmPreapprovedPackages:
- "@electron/*"
yarnPath: .yarn/releases/yarn-4.12.0.cjs

197
BUILD.gn
View File

@@ -4,9 +4,9 @@ import("//build/config/win/manifest.gni")
import("//components/os_crypt/sync/features.gni")
import("//components/spellcheck/spellcheck_build_features.gni")
import("//content/public/app/mac_helpers.gni")
import("//content/public/common/features.gni")
import("//extensions/buildflags/buildflags.gni")
import("//pdf/features.gni")
import("//ppapi/buildflags/buildflags.gni")
import("//printing/buildflags/buildflags.gni")
import("//testing/test.gni")
import("//third_party/electron_node/node.gni")
@@ -17,19 +17,19 @@ import("//tools/grit/repack.gni")
import("//tools/v8_context_snapshot/v8_context_snapshot.gni")
import("//v8/gni/snapshot_toolchain.gni")
import("build/asar.gni")
import("build/electron_paks.gni")
import("build/extract_symbols.gni")
import("build/js2c_toolchain.gni")
import("build/npm.gni")
import("build/templated_file.gni")
import("build/tsc.gni")
import("build/webpack/webpack.gni")
import("buildflags/buildflags.gni")
import("electron_paks.gni")
import("filenames.auto.gni")
import("filenames.gni")
import("filenames.hunspell.gni")
import("filenames.libcxx.gni")
import("filenames.libcxxabi.gni")
import("js2c_toolchain.gni")
if (is_mac) {
import("//build/config/mac/rules.gni")
@@ -38,12 +38,13 @@ if (is_mac) {
import("build/rules.gni")
assert(
mac_deployment_target == "11.0",
"Chromium has updated the mac_deployment_target, please update this assert, update the supported versions documentation (docs/tutorial/support.md) and flag this as a breaking change")
mac_deployment_target == "12.0",
"Chromium has updated the mac_deployment_target, please update this assert and flag this as a breaking change (docs/breaking-changes.md)")
}
if (is_linux) {
import("//build/config/linux/pkg_config.gni")
import("//electron/build/linux/strip_binary.gni")
import("//tools/generate_stubs/rules.gni")
pkg_config("gio_unix") {
@@ -224,11 +225,21 @@ webpack_build("electron_utility_bundle") {
out_file = "$target_gen_dir/js2c/utility_init.js"
}
webpack_build("electron_preload_realm_bundle") {
deps = [ ":build_electron_definitions" ]
inputs = auto_filenames.preload_realm_bundle_deps
config_file = "//electron/build/webpack/webpack.config.preload_realm.js"
out_file = "$target_gen_dir/js2c/preload_realm_bundle.js"
}
action("electron_js2c") {
deps = [
":electron_browser_bundle",
":electron_isolated_renderer_bundle",
":electron_node_bundle",
":electron_preload_realm_bundle",
":electron_renderer_bundle",
":electron_sandboxed_renderer_bundle",
":electron_utility_bundle",
@@ -240,6 +251,7 @@ action("electron_js2c") {
"$target_gen_dir/js2c/browser_init.js",
"$target_gen_dir/js2c/isolated_bundle.js",
"$target_gen_dir/js2c/node_init.js",
"$target_gen_dir/js2c/preload_realm_bundle.js",
"$target_gen_dir/js2c/renderer_init.js",
"$target_gen_dir/js2c/sandbox_bundle.js",
"$target_gen_dir/js2c/utility_init.js",
@@ -303,7 +315,7 @@ asar("default_app_asar") {
}
grit("resources") {
source = "electron_resources.grd"
source = "build/electron_resources.grd"
outputs = [
"grit/electron_resources.h",
@@ -430,17 +442,19 @@ source_set("electron_lib") {
"chromium_src:chrome_spellchecker",
"shell/common:mojo",
"shell/common:plugin",
"shell/common:web_contents_utility",
"shell/services/node/public/mojom",
"//base:base_static",
"//base/allocator:buildflags",
"//build/util:chromium_git_revision",
"//chrome:strings",
"//chrome/app:command_ids",
"//chrome/app/resources:platform_locale_settings",
"//components/autofill/core/common:features",
"//components/certificate_transparency",
"//components/compose:buildflags",
"//components/embedder_support:browser_util",
"//components/input:input",
"//components/embedder_support:user_agent",
"//components/input",
"//components/language/core/browser",
"//components/net_log",
"//components/network_hints/browser",
@@ -467,13 +481,14 @@ source_set("electron_lib") {
"//device/bluetooth",
"//device/bluetooth/public/cpp",
"//gin",
"//gpu/ipc/client",
"//media/capture/mojom:video_capture",
"//media/mojo/mojom",
"//media/mojo/mojom:web_speech_recognition",
"//net:extras",
"//net:net_resources",
"//printing/buildflags",
"//services/device/public/cpp/bluetooth:bluetooth",
"//services/device/public/cpp/bluetooth",
"//services/device/public/cpp/geolocation",
"//services/device/public/cpp/hid",
"//services/device/public/mojom",
@@ -487,6 +502,7 @@ source_set("electron_lib") {
"//third_party/blink/public/platform/media",
"//third_party/boringssl",
"//third_party/electron_node:libnode",
"//third_party/highway:libhwy",
"//third_party/inspector_protocol:crdtp",
"//third_party/leveldatabase",
"//third_party/libyuv",
@@ -506,10 +522,15 @@ source_set("electron_lib") {
"//v8:v8_libplatform",
]
if (v8_use_external_startup_data && use_v8_context_snapshot) {
deps += [ ":mksnapshot_checksum_gen" ]
}
public_deps = [
"//base",
"//base:i18n",
"//content/public/app",
"//ui/base/unowned_user_data",
]
include_dirs = [
@@ -569,7 +590,14 @@ source_set("electron_lib") {
}
if (is_mac) {
# Disable C++ modules to resolve linking error when including MacOS SDK
# headers from third_party/electron_node/deps/uv/include/uv/darwin.h
# TODO(samuelmaddock): consider revisiting this in the future
use_libcxx_modules = false
deps += [
"//components/os_crypt/async/browser:keychain_key_provider",
"//components/os_crypt/common:keychain_password_mac",
"//components/remote_cocoa/app_shim",
"//components/remote_cocoa/browser",
"//content/browser:mac_helpers",
@@ -631,6 +659,9 @@ source_set("electron_lib") {
":libnotify_loader",
"//build/config/linux/gtk",
"//components/crash/content/browser",
"//components/os_crypt/async/browser:freedesktop_secret_key_provider",
"//components/os_crypt/async/browser:posix_key_provider",
"//components/os_crypt/async/browser:secret_portal_key_provider",
"//dbus",
"//device/bluetooth",
"//third_party/crashpad/crashpad/client",
@@ -638,6 +669,7 @@ source_set("electron_lib") {
"//ui/events/devices/x11",
"//ui/events/platform/x11",
"//ui/gtk:gtk_config",
"//ui/linux:display_server_utils",
"//ui/linux:linux_ui",
"//ui/linux:linux_ui_factory",
"//ui/wm",
@@ -658,6 +690,8 @@ source_set("electron_lib") {
sources += [
"shell/browser/certificate_manager_model.cc",
"shell/browser/certificate_manager_model.h",
"shell/browser/linux/x11_util.cc",
"shell/browser/linux/x11_util.h",
"shell/browser/ui/gtk_util.cc",
"shell/browser/ui/gtk_util.h",
]
@@ -668,7 +702,8 @@ source_set("electron_lib") {
deps += [
"//components/app_launch_prefetch",
"//components/crash/core/app:crash_export_thunks",
"//ui/native_theme:native_theme_browser",
"//components/os_crypt/async/browser:dpapi_key_provider",
"//third_party/libxml:xml_writer",
"//ui/wm",
"//ui/wm/public",
]
@@ -713,7 +748,7 @@ source_set("electron_lib") {
"shell/common/extensions/api:extensions_features",
"//chrome/browser/resources:component_extension_resources",
"//components/guest_view/common:mojom",
"//components/update_client:update_client",
"//components/update_client",
"//components/zoom",
"//extensions/browser",
"//extensions/browser/api:api_provider",
@@ -735,11 +770,13 @@ source_set("electron_lib") {
if (enable_pdf_viewer) {
deps += [
"//chrome/browser/resources/pdf:resources",
"//chrome/browser/ui:browser_element_identifiers",
"//components/pdf/browser",
"//components/pdf/browser:interceptors",
"//components/pdf/common:constants",
"//components/pdf/common:util",
"//components/pdf/renderer",
"//components/user_education/webui",
"//pdf",
"//pdf:content_restriction",
]
@@ -758,6 +795,18 @@ source_set("electron_lib") {
}
}
action("mksnapshot_checksum_gen") {
script = "build/checksum_header.py"
outputs = [ "$target_gen_dir/snapshot_checksum.h" ]
inputs = [ "$root_out_dir/$v8_context_snapshot_filename" ]
args = rebase_path(inputs)
args += rebase_path(outputs)
deps = [ "//tools/v8_context_snapshot" ]
}
electron_paks("packed_resources") {
if (is_mac) {
output_dir = "$root_gen_dir/electron_repack"
@@ -801,7 +850,7 @@ if (is_mac) {
sources = []
public_deps = []
sources += [ "$root_out_dir/libffmpeg.dylib" ]
public_deps += [ "//third_party/ffmpeg:ffmpeg" ]
public_deps += [ "//third_party/ffmpeg" ]
outputs = [ "{{bundle_contents_dir}}/Libraries/{{source_file_part}}" ]
}
} else {
@@ -1216,7 +1265,7 @@ if (is_mac) {
}
if (use_v8_context_snapshot) {
public_deps = [ "//tools/v8_context_snapshot:v8_context_snapshot" ]
public_deps = [ "//tools/v8_context_snapshot" ]
}
if (is_linux) {
@@ -1234,7 +1283,7 @@ if (is_mac) {
"//components/crash/core/app:run_as_crashpad_handler",
]
ldflags = []
ldflags = [ "/DELAYLOAD:ffmpeg.dll" ]
libs = [
"comctl32.lib",
@@ -1395,6 +1444,18 @@ dist_zip("electron_dist_zip") {
":licenses",
]
if (is_linux) {
if (is_official_build) {
data_deps += [
":strip_chrome_crashpad_handler",
":strip_chrome_sandbox",
":strip_electron_binary",
":strip_libEGL_shlib",
":strip_libGLESv2_shlib",
":strip_libffmpeg_shlib",
":strip_libvk_swiftshader_shlib",
]
}
data_deps += [ "//sandbox/linux:chrome_sandbox" ]
}
deps = data_deps
@@ -1440,6 +1501,16 @@ group("electron_mksnapshot") {
dist_zip("electron_mksnapshot_zip") {
data_deps = mksnapshot_deps
if (is_linux && is_official_build) {
data_deps += [
":strip_libEGL_shlib",
":strip_libGLESv2_shlib",
":strip_libffmpeg_shlib",
":strip_libvk_swiftshader_shlib",
":strip_mksnapshot_binary",
":strip_v8_context_snapshot_generator_binary",
]
}
deps = data_deps
outputs = [ "$root_build_dir/mksnapshot.zip" ]
}
@@ -1564,3 +1635,101 @@ group("copy_node_headers") {
group("node_headers") {
public_deps = [ ":tar_node_headers" ]
}
group("testing_build") {
public_deps = [
":electron_dist_zip",
":electron_mksnapshot_zip",
":node_headers",
]
}
group("release_build") {
public_deps = [ ":testing_build" ]
if (is_official_build) {
public_deps += [ ":electron_symbols" ]
}
if (is_linux) {
public_deps += [
":hunspell_dictionaries_zip",
":libcxx_headers_zip",
":libcxx_objects_zip",
":libcxxabi_headers_zip",
]
}
}
if (is_linux && is_official_build) {
strip_binary("strip_electron_binary") {
binary_input = "$root_out_dir/$electron_project_name"
symbol_output = "$root_out_dir/debug/$electron_project_name.debug"
compress_debug_sections = true
deps = [ ":electron_app" ]
}
strip_binary("strip_chrome_crashpad_handler") {
binary_input = "$root_out_dir/chrome_crashpad_handler"
symbol_output = "$root_out_dir/debug/chrome_crashpad_handler.debug"
compress_debug_sections = true
deps = [ "//components/crash/core/app:chrome_crashpad_handler" ]
}
strip_binary("strip_chrome_sandbox") {
binary_input = "$root_out_dir/chrome_sandbox"
symbol_output = "$root_out_dir/debug/chrome-sandbox.debug"
compress_debug_sections = true
deps = [ "//sandbox/linux:chrome_sandbox" ]
}
strip_binary("strip_libEGL_shlib") {
binary_input = "$root_out_dir/libEGL.so"
symbol_output = "$root_out_dir/debug/libEGL.so.debug"
compress_debug_sections = true
deps = [ "//third_party/angle:libEGL" ]
}
strip_binary("strip_libGLESv2_shlib") {
binary_input = "$root_out_dir/libGLESv2.so"
symbol_output = "$root_out_dir/debug/libGLESv2.so.debug"
compress_debug_sections = true
deps = [ "//third_party/angle:libGLESv2" ]
}
strip_binary("strip_libffmpeg_shlib") {
binary_input = "$root_out_dir/libffmpeg.so"
symbol_output = "$root_out_dir/debug/libffmpeg.so.debug"
compress_debug_sections = true
deps = [ "//third_party/ffmpeg" ]
}
strip_binary("strip_libvk_swiftshader_shlib") {
binary_input = "$root_out_dir/libvk_swiftshader.so"
symbol_output = "$root_out_dir/debug/libvk_swiftshader.so.debug"
compress_debug_sections = true
deps = [ "//third_party/swiftshader/src/Vulkan:swiftshader_libvulkan" ]
}
strip_binary("strip_mksnapshot_binary") {
_binary_path = rebase_path(
get_label_info(
":v8_context_snapshot_generator($v8_snapshot_toolchain)",
"root_out_dir") + "/mksnapshot",
root_build_dir)
binary_input = "$root_out_dir/$_binary_path"
symbol_output = "$root_out_dir/debug/${_binary_path}.debug"
compress_debug_sections = true
deps = mksnapshot_deps
}
strip_binary("strip_v8_context_snapshot_generator_binary") {
_binary_path = rebase_path(
get_label_info(
":v8_context_snapshot_generator($v8_snapshot_toolchain)",
"root_out_dir") + "/v8_context_snapshot_generator",
root_build_dir)
binary_input = "$root_out_dir/$_binary_path"
symbol_output = "$root_out_dir/debug/${_binary_path}.debug"
compress_debug_sections = true
deps = mksnapshot_deps
}
}

226
CLAUDE.md Normal file
View File

@@ -0,0 +1,226 @@
# Electron Development Guide
## Project Overview
Electron is a framework for building cross-platform desktop applications using web technologies. It embeds Chromium for rendering and Node.js for backend functionality.
## Directory Structure
```text
electron/ # This repo (run `e` commands here)
├── shell/ # Core C++ application code
│ ├── browser/ # Main process implementation (107+ API modules)
│ ├── renderer/ # Renderer process code
│ ├── common/ # Shared code between processes
│ ├── app/ # Application entry points
│ └── services/ # Node.js service integration
├── lib/ # TypeScript/JavaScript library code
│ ├── browser/ # Main process JS (47 API implementations)
│ ├── renderer/ # Renderer process JS
│ └── common/ # Shared JS modules
├── patches/ # Patches for upstream dependencies
│ ├── chromium/ # ~159 patches to Chromium
│ ├── node/ # ~48 patches to Node.js
│ └── ... # Other targets (v8, boringssl, etc.)
├── spec/ # Test suite (1189+ TypeScript test files)
├── docs/ # API documentation and guides
├── build/ # Build configuration
├── script/ # Build and automation scripts
└── chromium_src/ # Chromium source overrides
../ # Parent directory is Chromium source
```
## Build Tools Setup
Electron uses `@electron/build-tools` for development. The `e` command is the primary CLI.
**Installation:**
```bash
npm i -g @electron/build-tools
```
**Configuration location:** `~/.electron_build_tools/configs/`
## Essential Commands
### Configuration Management
| Command | Purpose |
|---------|---------|
| `e init <name> --root=<path> --bootstrap testing` | Create new build config and sync |
| `e use <name>` | Switch to a different build configuration |
| `e show current` | Display active configuration name |
| `e show configs` | List all available configurations |
### Build & Development Loop
| Command | Purpose |
|---------|---------|
| `e sync` | Fetch/update all source code and apply patches |
| `e sync --3` | Sync with 3-way merge (required for Chromium upgrades) |
| `e build` | Build Electron (runs GN + Ninja) |
| `e build -k 999` | Build and continue on errors (up to 999) |
| `e build -t <target>` | Build specific target (e.g., `electron:node_headers`) |
| `e start` | Run the built Electron executable |
| `e start --version` | Verify Electron launches and print version |
| `e test` | Run the test suite |
| `e debug` | Run Electron in debugger (lldb on macOS, gdb on Linux) |
### Patch Management
| Command | Purpose |
|---------|---------|
| `e patches <target>` | Export patches for a target (chromium, node, v8, etc.) |
| `e patches all` | Export all patches from all targets |
| `e patches --list-targets` | List available patch targets |
## Typical Development Workflow
```bash
# 1. Ensure you're on the right config
e show current
# 2. Sync to get latest code
e sync
# 3. Make your changes in shell/ or lib/ or ../
# 4. Build
e build
# 5. Test your changes (Leave the user to do this, don't run these commands unless asked)
e start
e test
# 6. If you modified patched files in Chromium:
cd .. # Go to Chromium repo
git add <files>
git commit -m "description of change"
cd electron
e patches chromium # Export the patch
```
## Patches System
Electron patches upstream dependencies (Chromium, Node.js, V8, etc.) to add features or modify behavior.
**How patches work:**
```text
patches/{target}/*.patch → [e sync --3] → target repo commits
← [e patches] ←
```
**Patch configuration:** `patches/config.json` maps patch directories to target repos.
**Key rules:**
- Fix existing patches 99% of the time rather than creating new ones
- Preserve original authorship in TODO comments
- Never change TODO assignees (`TODO(name)` must retain original name)
- Each patch file includes commit message explaining its purpose
**Creating/modifying patches:**
1. Make changes in the target repo (e.g., `../` for Chromium)
2. Create a git commit
3. Run `e patches <target>` to export
## Testing
**Test location:** `spec/` directory
**Running tests:**
```bash
e test # Run full test suite
```
**Test frameworks:** Mocha, Chai, Sinon
## Build Configuration
**GN build arguments:** Located in `build/args/`:
- `testing.gn` - Debug/testing builds
- `release.gn` - Release builds
- `all.gn` - Common arguments for all builds
**Main build file:** `BUILD.gn`
**Feature flags:** `buildflags/buildflags.gni`
## Chromium Upgrade Workflow
When working on the `roller/chromium/main` branch to upgrade Chromium activate the "Electron Chromium Upgrade" skill.
## Code Style
**C++:** Follows Chromium style, enforced by clang-format
**TypeScript/JavaScript:** ESLint configuration in `.eslintrc.json`
**Linting:**
```bash
npm run lint # Run all linters
npm run lint:clang-format # C++ formatting
```
## Key Files
| File | Purpose |
|------|---------|
| `BUILD.gn` | Main GN build configuration |
| `DEPS` | Dependency versions and checkout paths |
| `patches/config.json` | Patch target configuration |
| `filenames.gni` | Source file lists by platform |
| `package.json` | Node.js dependencies and scripts |
## Environment Variables
| Variable | Purpose |
|----------|---------|
| `GN_EXTRA_ARGS` | Additional GN arguments (useful in CI) |
| `ELECTRON_RUN_AS_NODE=1` | Run Electron as Node.js |
## Useful Git Commands for Chromium
```bash
# Find CL that changed a file
cd ..
git log --oneline -10 -- {file}
git blame -L {start},{end} -- {file}
# Look for Chromium CL reference in commit
git log -1 {commit_sha} # Find "Reviewed-on:" line
# Find which patch affects a file
grep -l "filename.cc" patches/chromium/*.patch
```
## CI/CD
GitHub Actions workflows in `.github/workflows/`:
- `build.yml` - Main build workflow
- `pipeline-electron-lint.yml` - Linting
- `pipeline-segment-electron-test.yml` - Testing
## Common Issues
**Patch conflict during sync:**
- Use `e sync --3` for 3-way merge
- Check if file was renamed/moved upstream
- Verify patch is still needed
**Build error in patched file:**
- Find the patch: `grep -l "filename" patches/chromium/*.patch`
- Match existing patch style (#if 0 guards, BUILDFLAG conditionals, etc.)
**Remote build issues:**
- Try `e build --no-remote` to build locally
- Check reclient/siso configuration in your build config

View File

@@ -71,4 +71,4 @@ See [Coding Style](https://electronjs.org/docs/development/coding-style) for inf
## Further Reading
For more in-depth guides on developing Electron, see
[/docs/development](/docs/development/README.md)
[/docs/development](/docs/development/README.md).

19
DEPS
View File

@@ -2,17 +2,17 @@ gclient_gn_args_from = 'src'
vars = {
'chromium_version':
'133.0.6887.0',
'146.0.7666.0',
'node_version':
'v22.9.0',
'v24.13.1',
'nan_version':
'e14bdcd1f72d62bca1d541b66da43130384ec213',
'675cefebca42410733da8a454c8d9391fcebfbc2',
'squirrel.mac_version':
'0e5d146ba13101a1302d59ea6e6e0b3cace4ae38',
'reactiveobjc_version':
'74ab5baccc6f7202c8ac69a8d1e152c29dc1ea76',
'mantle_version':
'78d3966b3c331292ea29ec38661b25df0a245948',
'2a8e2123a3931038179ee06105c9e6ec336b12ea',
'engflow_reclient_configs_version':
'955335c30a752e9ef7bff375baab5e0819b6c00d',
@@ -30,9 +30,6 @@ vars = {
# The path of the sysroots.json file.
'sysroots_json_path': 'electron/script/sysroots.json',
# KEEP IN SYNC WITH utils.js FILE
'yarn_version': '1.15.2',
# To be able to build clean Chromium from sources.
'apply_patches': True,
@@ -62,10 +59,6 @@ vars = {
'checkout_nacl':
False,
'checkout_libaom':
True,
'checkout_oculus_sdk':
False,
'checkout_openxr':
False,
'build_with_chromium':
@@ -74,8 +67,6 @@ vars = {
False,
'checkout_android_native_support':
False,
'checkout_google_benchmark':
False,
'checkout_clang_tidy':
True,
}
@@ -161,7 +152,7 @@ hooks = [
'action': [
'python3',
'-c',
'import os, subprocess; os.chdir(os.path.join("src", "electron")); subprocess.check_call(["python3", "script/lib/npx.py", "yarn@' + (Var("yarn_version")) + '", "install", "--frozen-lockfile"]);',
'import os, subprocess; os.chdir(os.path.join("src", "electron")); subprocess.check_call(["node", ".yarn/releases/yarn-4.12.0.cjs", "install", "--immutable"]);',
],
},
{

View File

@@ -1,7 +1,6 @@
[![Electron Logo](https://electronjs.org/images/electron-logo.svg)](https://electronjs.org)
[![GitHub Actions Build Status](https://github.com/electron/electron/actions/workflows/build.yml/badge.svg)](https://github.com/electron/electron/actions/workflows/build.yml)
[![AppVeyor Build Status](https://ci.appveyor.com/api/projects/status/4lggi9dpjc1qob7k/branch/main?svg=true)](https://ci.appveyor.com/project/electron-bot/electron-ljo26/branch/main)
[![Electron Discord Invite](https://img.shields.io/discord/745037351163527189?color=%237289DA&label=chat&logo=discord&logoColor=white)](https://discord.gg/electronjs)
:memo: Available Translations: 🇨🇳 🇧🇷 🇪🇸 🇯🇵 🇷🇺 🇫🇷 🇺🇸 🇩🇪.
@@ -38,36 +37,24 @@ For more installation options and troubleshooting tips, see
Each Electron release provides binaries for macOS, Windows, and Linux.
* macOS (Big Sur and up): Electron provides 64-bit Intel and Apple Silicon / ARM binaries for macOS.
* macOS (Monterey and up): Electron provides 64-bit Intel and Apple Silicon / ARM binaries for macOS.
* Windows (Windows 10 and up): Electron provides `ia32` (`x86`), `x64` (`amd64`), and `arm64` binaries for Windows. Windows on ARM support was added in Electron 5.0.8. Support for Windows 7, 8 and 8.1 was [removed in Electron 23, in line with Chromium's Windows deprecation policy](https://www.electronjs.org/blog/windows-7-to-8-1-deprecation-notice).
* Linux: The prebuilt binaries of Electron are built on Ubuntu 20.04. They have also been verified to work on:
* Linux: The prebuilt binaries of Electron are built on Ubuntu 22.04. They have also been verified to work on:
* Ubuntu 18.04 and newer
* Fedora 32 and newer
* Debian 10 and newer
## Quick start & Electron Fiddle
## Electron Fiddle
Use [`Electron Fiddle`](https://github.com/electron/fiddle)
to build, run, and package small Electron experiments, to see code examples for all of Electron's APIs, and
to try out different versions of Electron. It's designed to make the start of your journey with
Electron easier.
Alternatively, clone and run the
[electron/electron-quick-start](https://github.com/electron/electron-quick-start)
repository to see a minimal Electron app in action:
```sh
git clone https://github.com/electron/electron-quick-start
cd electron-quick-start
npm install
npm start
```
## Resources for learning Electron
* [electronjs.org/docs](https://electronjs.org/docs) - All of Electron's documentation
* [electron/fiddle](https://github.com/electron/fiddle) - A tool to build, run, and package small Electron experiments
* [electron/electron-quick-start](https://github.com/electron/electron-quick-start) - A very basic starter Electron app
* [electronjs.org/community#boilerplates](https://electronjs.org/community#boilerplates) - Sample starter apps created by the community
## Programmatic usage

View File

@@ -8,6 +8,12 @@ The Electron team will send a response indicating the next steps in handling you
Report security bugs in third-party modules to the person or team maintaining the module. You can also report a vulnerability through the [npm contact form](https://www.npmjs.com/support) by selecting "I'm reporting a security vulnerability".
## Escalation
If you do not receive an acknowledgement of your report within 6 business days, or if you cannot find a private security contact for the project, you may escalate to the OpenJS Foundation CNA at `security@lists.openjsf.org`.
If the project acknowledges your report but does not provide any further response or engagement within 14 days, escalation is also appropriate.
## The Electron Security Notification Process
For context on Electron's security notification process, please see the [Notifications](https://github.com/electron/governance/blob/main/wg-security/membership-and-notifications.md#notifications) section of the Security WG's [Membership and Notifications](https://github.com/electron/governance/blob/main/wg-security/membership-and-notifications.md) Governance document.

View File

@@ -1,107 +0,0 @@
# The config is used to bake appveyor images, not for running CI jobs.
# The config expects the following environment variables to be set:
# - "APPVEYOR_BAKE_IMAGE" e.g. 'electron-99.0.4767.0'. Name of the image to be baked.
# Typically named after the Chromium version on which the image is built.
# This can be set dynamically in the prepare-appveyor script.
version: 1.0.{build}
build_cloud: electronhq-16-core
image: base-bake-image
environment:
GIT_CACHE_PATH: C:\Users\appveyor\libcc_cache
ELECTRON_OUT_DIR: Default
ELECTRON_ENABLE_STACK_DUMPING: 1
MOCHA_REPORTER: mocha-multi-reporters
MOCHA_MULTI_REPORTERS: mocha-appveyor-reporter, tap
DEPOT_TOOLS_WIN_TOOLCHAIN: 0
PYTHONIOENCODING: UTF-8
# The following lines are needed when baking from a completely new image (eg MicrosoftWindowsServer:WindowsServer:2019-Datacenter:latest via image: base-windows-server2019)
# init:
# - ps: $blockRdp = $true; iex ((new-object net.webclient).DownloadString('https://raw.githubusercontent.com/appveyor/ci/master/scripts/enable-rdp.ps1'))
# - appveyor version
# - ps: $ErrorActionPreference = 'Stop'
# - ps: 'Write-Host "OS Build: $((Get-CimInstance Win32_OperatingSystem).BuildNumber)"'
# clone_folder: '%USERPROFILE%\image-bake-scripts'
# clone_script:
# - ps: Invoke-WebRequest "https://github.com/appveyor/build-images/archive/1f90d94e74c8243c909a09b994e527584dfcb838.zip" -OutFile "$env:temp\scripts.zip"
# - ps: Expand-Archive -Path "$env:temp\scripts.zip" -DestinationPath "$env:temp\scripts" -Force
# - ps: Copy-Item -Path "$env:temp\scripts\build-images-1f90d94e74c8243c909a09b994e527584dfcb838\scripts\Windows\*" -Destination $env:APPVEYOR_BUILD_FOLDER -Recurse
build_script:
# The following lines are needed when baking from a completely new image (eg MicrosoftWindowsServer:WindowsServer:2019-Datacenter:latest via image: base-windows-server2019)
# - ps: .\init_server.ps1
# - ps: .\extend_system_volume.ps1
# # Restart VM
# - ps: Start-Sleep -s 5; Restart-Computer
# - ps: Start-Sleep -s 5
# - appveyor version
# - ps: .\install_path_utils.ps1
# - ps: .\install_powershell_core.ps1
# - ps: .\install_powershell_get.ps1
# - ps: .\install_7zip.ps1
# - ps: .\install_chocolatey.ps1
# - ps: .\install_webpi.ps1
# - ps: .\install_nuget.ps1
# - ps: .\install_pstools.ps1
# - ps: .\install_git.ps1
# - ps: .\install_git_lfs.ps1
# # Restart VM
# - ps: Start-Sleep -s 5; Restart-Computer
# - ps: Start-Sleep -s 5
# END LINES FOR COMPLETELY NEW IMAGE
- git config --global core.longpaths true
- ps: >-
if (-not (Test-Path -Path C:\projects\src)) {
New-Item -Path C:\projects\src -ItemType Directory
}
- cd C:\projects\
- git clone -q --branch=%APPVEYOR_REPO_BRANCH% https://github.com/electron/electron.git C:\projects\src\electron
- git clone --depth=1 https://chromium.googlesource.com/chromium/tools/depot_tools.git
- ps: $env:PATH="$pwd\depot_tools;$env:PATH"
- update_depot_tools.bat
# Uncomment the following line if windows deps change
- src\electron\script\setup-win-for-dev.bat
- >-
gclient config
--name "src\electron"
--unmanaged
%GCLIENT_EXTRA_ARGS%
"https://github.com/electron/electron"
- ps: cd src\electron
- ps: node script\generate-deps-hash.js
- ps: $depshash = Get-Content .\.depshash -Raw
- ps: Copy-Item -path .\.depshash -destination ..\.depshash
- ps: cd ..\..
- gclient sync --with_branch_heads --with_tags --nohooks
- ps: regsvr32 /s "C:\Program Files\Microsoft Visual Studio\2022\Community\DIA SDK\bin\amd64\msdia140.dll"
- ps: set vs2022_install="C:\Program Files\Microsoft Visual Studio\2022\Community"
# The following lines are needed when baking from a completely new image (eg MicrosoftWindowsServer:WindowsServer:2019-Datacenter:latest via image: base-windows-server2019)
# # Restart VM
# - ps: Start-Sleep -s 5; Restart-Computer
# - ps: Start-Sleep -s 5
# - cd %USERPROFILE%\image-bake-scripts
# - appveyor version
# - ps: .\optimize_dotnet_runtime.ps1
# - ps: .\disable_windows_background_services.ps1
# - ps: .\enforce_windows_firewall.ps1
# - ps: .\cleanup_windows.ps1
# END LINES FOR COMPLETELY NEW IMAGE
on_image_bake:
- ps: >-
echo "Baking image: $env:APPVEYOR_BAKE_IMAGE at dir $PWD"
- ps: Remove-Item -Recurse -Force C:\projects\depot_tools
- ps: Remove-Item -Recurse -Force C:\projects\src\electron
# Uncomment these lines and set APPVEYOR_RDP_PASSWORD in project settings to enable RDP after bake is done
# # on_finish:
# - ps: >-
# $blockRdp = $true; iex ((new-object net.webclient).DownloadString('https://raw.githubusercontent.com/appveyor/ci/master/scripts/enable-rdp.ps1'))

View File

@@ -1,352 +0,0 @@
# NOTE IF CHANGING THIS FILE, ALSO APPLY THE CHANGE TO appveyor.yml
# IF APPLICABLE!!!!
#
#
# The config expects the following environment variables to be set:
# - "GN_CONFIG" Build type. One of {'testing', 'release'}.
# - "GN_EXTRA_ARGS" Additional gn arguments for a build config,
# e.g. 'target_cpu="x86"' to build for a 32bit platform.
# https://gn.googlesource.com/gn/+/main/docs/reference.md#var_target_cpu
# Don't forget to set up "NPM_CONFIG_ARCH" and "TARGET_ARCH" accordingly
# if you pass a custom value for 'target_cpu'.
# - "ELECTRON_RELEASE" Set it to '1' upload binaries on success.
# - "NPM_CONFIG_ARCH" E.g. 'x86'. Is used to build native Node.js modules.
# Must match 'target_cpu' passed to "GN_EXTRA_ARGS" and "TARGET_ARCH" value.
# - "TARGET_ARCH" Choose from {'ia32', 'x64', 'arm', 'arm64'}.
# Is used in some publishing scripts, but does NOT affect the Electron binary.
# Must match 'target_cpu' passed to "GN_EXTRA_ARGS" and "NPM_CONFIG_ARCH" value.
# - "UPLOAD_TO_STORAGE" Set it to '1' upload a release to the Azure bucket.
# Otherwise the release will be uploaded to the GitHub Releases.
# (The value is only checked if "ELECTRON_RELEASE" is defined.)
#
# The publishing scripts expect access tokens to be defined as env vars,
# but those are not covered here.
#
# AppVeyor docs on variables:
# https://www.appveyor.com/docs/environment-variables/
# https://www.appveyor.com/docs/build-configuration/#secure-variables
# https://www.appveyor.com/docs/build-configuration/#custom-environment-variables
version: 1.0.{build}
build_cloud: electronhq-16-core
image: e-133.0.6878.0
environment:
GIT_CACHE_PATH: C:\Users\appveyor\libcc_cache
ELECTRON_OUT_DIR: Default
ELECTRON_ENABLE_STACK_DUMPING: 1
ELECTRON_ALSO_LOG_TO_STDERR: 1
MOCHA_REPORTER: mocha-multi-reporters
MOCHA_MULTI_REPORTERS: "@marshallofsound/mocha-appveyor-reporter, mocha-junit-reporter, tap"
DEPOT_TOOLS_WIN_TOOLCHAIN: 1
DEPOT_TOOLS_WIN_TOOLCHAIN_BASE_URL: "https://dev-cdn.electronjs.org/windows-toolchains/_"
GYP_MSVS_HASH_7393122652: 3ba76c5c20
PYTHONIOENCODING: UTF-8
matrix:
- job_name: Build Arm on X64 Windows
- job_name: Test On Windows On Arm Hardware 1
job_depends_on: Build Arm on X64 Windows
APPVEYOR_BUILD_WORKER_IMAGE: base-woa
APPVEYOR_BUILD_WORKER_CLOUD: electronhq-woa
shard: 1
- job_name: Test On Windows On Arm Hardware 2
job_depends_on: Build Arm on X64 Windows
APPVEYOR_BUILD_WORKER_IMAGE: base-woa
APPVEYOR_BUILD_WORKER_CLOUD: electronhq-woa
shard: 2
clone_script:
- ps: git clone -q $("--branch=" + $Env:APPVEYOR_REPO_BRANCH) $("https://github.com/" + $Env:APPVEYOR_REPO_NAME + ".git") $Env:APPVEYOR_BUILD_FOLDER
- ps: if (!$Env:APPVEYOR_PULL_REQUEST_NUMBER) {$("git checkout -qf " + $Env:APPVEYOR_REPO_COMMIT)}
- ps: if ($Env:APPVEYOR_PULL_REQUEST_NUMBER) {git fetch -q origin +refs/pull/$($Env:APPVEYOR_PULL_REQUEST_NUMBER)/head; git checkout -qf FETCH_HEAD}
clone_folder: C:\projects\src\electron
skip_branch_with_pr: true
# the first failed job cancels other jobs and fails entire build
matrix:
fast_finish: true
for:
- matrix:
only:
- job_name: Build Arm on X64 Windows
build_script:
# TODO: Remove --ignore-engines once WOA image is up to node 20
- ps: |
node script/yarn.js install --frozen-lockfile --ignore-engines
node script/doc-only-change.js --prNumber=$env:APPVEYOR_PULL_REQUEST_NUMBER
$env:SHOULD_SKIP_ARTIFACT_VALIDATION = "false"
if ($LASTEXITCODE -eq 0) {
Write-warning "Skipping build for doc-only change"
$env:SHOULD_SKIP_ARTIFACT_VALIDATION = "true"
Exit-AppveyorBuild
} else {
$global:LASTEXITCODE = 0
}
- cd ..
- ps: Write-Host "Building $env:GN_CONFIG build"
- git config --global core.longpaths true
- ps: >-
if (Test-Path -Path "$pwd\depot_tools") {
Remove-Item -Recurse -Force $pwd\depot_tools
}
- ps: >-
if (Test-Path -Path "$pwd\build-tools") {
Remove-Item -Recurse -Force $pwd\build-tools
}
- git clone --depth=1 https://chromium.googlesource.com/chromium/tools/depot_tools.git
- ps: New-Item -Name depot_tools\.disable_auto_update -ItemType File
- depot_tools\bootstrap\win_tools.bat
- ps: |
Set-Content -Path $pwd\depot_tools\build_telemetry.cfg -Value '{"user": "info@electronjs.org", "status": "opt-out", "countdown": 10, "version": 1}'
- ps: $env:PATH="$pwd\depot_tools;$env:PATH"
- ps: >-
if (Test-Path -Path "$pwd\src\electron") {
Remove-Item -Recurse -Force $pwd\src\electron
}
- git clone https://github.com/electron/build-tools.git
- cd build-tools
- npx yarn --ignore-engines
- mkdir third_party
- ps: >-
node -e "require('./src/utils/reclient.js').downloadAndPrepare({})"
- ps: $env:RECLIENT_HELPER = node -p "require('./src/utils/reclient.js').helperPath({})"
- ps: >-
& $env:RECLIENT_HELPER login
- ps: >-
$env:RBE_service = node -e "console.log(require('./src/utils/reclient.js').serviceAddress)"
- ps: >-
$env:RBE_credentials_helper = $env:RECLIENT_HELPER
- ps: >-
$env:RBE_credentials_helper_args = "print"
- ps: >-
if ($env:ELECTRON_RBE_JWT -eq '') {
$env:RBE_fail_early_min_action_count = "0"
$env:RBE_fail_early_min_fallback_ratio = "0"
}
- cd ..\..
- ps: $env:CHROMIUM_BUILDTOOLS_PATH="$pwd\src\buildtools"
- ps: >-
if ($env:GN_CONFIG -ne 'release') {
$env:NINJA_STATUS="[%r processes, %f/%t @ %o/s : %es] "
}
- gclient config --name "src\electron" --unmanaged %GCLIENT_EXTRA_ARGS% "https://github.com/electron/electron"
# Patches are applied in the image bake. Check depshash to see if patches have changed.
- ps: $env:RUN_GCLIENT_SYNC="false"
- ps: $depshash_baked = Get-Content .\src\.depshash -Raw
- ps: cd src\electron
- ps: node script\generate-deps-hash.js
- ps: $depshash = Get-Content .\.depshash -Raw
- ps: cd ..\..
- ps: >-
if ($depshash_baked -ne $depshash) {
$env:RUN_GCLIENT_SYNC="true"
}
- if "%RUN_GCLIENT_SYNC%"=="true" ( gclient sync --with_branch_heads --with_tags ) else ( gclient runhooks )
- cd src
- ps: $env:PATH="$pwd\third_party\ninja;$env:PATH"
- set BUILD_CONFIG_PATH=//electron/build/args/%GN_CONFIG%.gn
- gn gen out/Default "--args=import(\"%BUILD_CONFIG_PATH%\") use_remoteexec=true %GN_EXTRA_ARGS% "
- gn check out/Default //electron:electron_lib
- gn check out/Default //electron:electron_app
- gn check out/Default //electron/shell/common:mojo
- gn check out/Default //electron/shell/common:plugin
- autoninja -j 300 -C out/Default electron:electron_app
- if "%GN_CONFIG%"=="testing" ( python C:\depot_tools\post_build_ninja_summary.py -C out\Default )
- gn gen out/ffmpeg "--args=import(\"//electron/build/args/ffmpeg.gn\") use_remoteexec=true %GN_EXTRA_ARGS%"
- autoninja -C out/ffmpeg electron:electron_ffmpeg_zip
- autoninja -C out/Default electron:electron_dist_zip
- gn desc out/Default v8:run_mksnapshot_default args > out/Default/default_mksnapshot_args
# Remove unused args from mksnapshot_args
- ps: >-
Get-Content out/Default/default_mksnapshot_args | Where-Object { -not $_.Contains('--turbo-profiling-input') -And -not $_.Contains('builtins-pgo') } | Set-Content out/Default/mksnapshot_args
- autoninja -C out/Default electron:electron_mksnapshot_zip
- cd out\Default
- 7z a mksnapshot.zip mksnapshot_args gen\v8\embedded.S
- cd ..\..
- autoninja -C out/Default electron:hunspell_dictionaries_zip
- autoninja -C out/Default electron:electron_chromedriver_zip
- autoninja -C out/Default electron:node_headers
- ps: >-
Get-CimInstance -Namespace root\cimv2 -Class Win32_product | Select vendor, description, @{l='install_location';e='InstallLocation'}, @{l='install_date';e='InstallDate'}, @{l='install_date_2';e='InstallDate2'}, caption, version, name, @{l='sku_number';e='SKUNumber'} | ConvertTo-Json | Out-File -Encoding utf8 -FilePath .\installed_software.json
- python3 electron/build/profile_toolchain.py --output-json=out/Default/windows_toolchain_profile.json
- 7z a node_headers.zip out\Default\gen\node_headers
- 7z a nan.zip third_party\nan
- ps: >-
if ($env:GN_CONFIG -eq 'release') {
# Needed for msdia140.dll on 64-bit windows
$env:Path += ";$pwd\third_party\llvm-build\Release+Asserts\bin"
}
- if "%GN_CONFIG%"=="release" ( autoninja -C out/Default electron:electron_symbols )
- ps: >-
if ($env:GN_CONFIG -eq 'release') {
python3 electron\script\zip-symbols.py
appveyor-retry appveyor PushArtifact out/Default/symbols.zip
} else {
# It's useful to have pdb files when debugging testing builds that are
# built on CI.
7z a pdb.zip out\Default\*.pdb
}
- ps: |
$manifest_file = "electron/script/zip_manifests/dist_zip.win.$env:TARGET_ARCH.manifest"
python3 electron/script/zip_manifests/check-zip-manifest.py out/Default/dist.zip $manifest_file
if ($LASTEXITCODE -ne 0) {
throw "Zip contains files not listed in the manifest $manifest_file"
}
- ps: |
cd C:\projects\src
$missing_artifacts = $false
if ($env:SHOULD_SKIP_ARTIFACT_VALIDATION -eq 'true') {
Write-warning "Skipping artifact validation for doc-only $env:APPVEYOR_PROJECT_NAME"
} else {
$artifacts_to_validate = 'dist.zip','windows_toolchain_profile.json','chromedriver.zip','ffmpeg.zip','node_headers.zip','mksnapshot.zip','electron.lib','hunspell_dictionaries.zip','nan.zip'
foreach($artifact_name in $artifacts_to_validate) {
if ($artifact_name -eq 'ffmpeg.zip') {
$artifact_file = "out\ffmpeg\ffmpeg.zip"
} elseif (
$artifact_name -eq 'node_headers.zip') {
$artifact_file = $artifact_name
} elseif (
$artifact_name -eq 'nan.zip') {
$artifact_file = $artifact_name
} else {
$artifact_file = "out\Default\$artifact_name"
}
if (-not(Test-Path $artifact_file)) {
Write-warning "$artifact_name is missing and cannot be added to artifacts"
$missing_artifacts = $true
}
}
}
if ($missing_artifacts) {
throw "Build failed due to missing artifacts"
}
deploy_script:
- cd electron
- ps: >-
if (Test-Path Env:\ELECTRON_RELEASE) {
if (Test-Path Env:\UPLOAD_TO_STORAGE) {
Write-Output "Uploading Electron release distribution to azure"
& python3 script\release\uploaders\upload.py --verbose --upload_to_storage
} else {
Write-Output "Uploading Electron release distribution to github releases"
& python3 script\release\uploaders\upload.py --verbose
}
}
on_finish:
# Uncomment this lines to enable RDP
# - ps: $blockRdp = $true; iex ((new-object net.webclient).DownloadString('https://raw.githubusercontent.com/appveyor/ci/master/scripts/enable-rdp.ps1'))
- cd C:\projects\src
- if exist out\Default\windows_toolchain_profile.json ( appveyor-retry appveyor PushArtifact out\Default\windows_toolchain_profile.json )
- if exist out\Default\dist.zip (appveyor-retry appveyor PushArtifact out\Default\dist.zip)
- if exist out\Default\chromedriver.zip (appveyor-retry appveyor PushArtifact out\Default\chromedriver.zip)
- if exist out\ffmpeg\ffmpeg.zip (appveyor-retry appveyor PushArtifact out\ffmpeg\ffmpeg.zip)
- if exist node_headers.zip (appveyor-retry appveyor PushArtifact node_headers.zip)
- if exist nan.zip (appveyor-retry appveyor PushArtifact nan.zip)
- if exist out\Default\mksnapshot.zip (appveyor-retry appveyor PushArtifact out\Default\mksnapshot.zip)
- if exist out\Default\hunspell_dictionaries.zip (appveyor-retry appveyor PushArtifact out\Default\hunspell_dictionaries.zip)
- if exist out\Default\electron.lib (appveyor-retry appveyor PushArtifact out\Default\electron.lib)
- ps: >-
if ((Test-Path "pdb.zip") -And ($env:GN_CONFIG -ne 'release')) {
appveyor-retry appveyor PushArtifact pdb.zip
}
- matrix:
only:
- job_name: Test On Windows On Arm Hardware 1
- job_name: Test On Windows On Arm Hardware 2
environment:
IGNORE_YARN_INSTALL_ERROR: 1
ELECTRON_TEST_RESULTS_DIR: C:\projects\src\electron\junit
MOCHA_MULTI_REPORTERS: "@marshallofsound/mocha-appveyor-reporter, mocha-junit-reporter, tap"
MOCHA_REPORTER: mocha-multi-reporters
ELECTRON_SKIP_NATIVE_MODULE_TESTS: true
DD_ENV: ci
DD_SERVICE: electron
DD_CIVISIBILITY_LOGS_ENABLED: true
DD_GIT_REPOSITORY_URL: "https://github.com/electron/electron.git"
build_script:
- ps: |
node script/yarn.js install --frozen-lockfile --ignore-engines
node script/doc-only-change.js --prNumber=$env:APPVEYOR_PULL_REQUEST_NUMBER
if ($LASTEXITCODE -eq 0) {
Write-warning "Skipping build for doc only change"
Exit-AppveyorBuild
} else {
$global:LASTEXITCODE = 0
}
- ps: Invoke-WebRequest -Uri "https://github.com/DataDog/datadog-ci/releases/latest/download/datadog-ci_win-x64" -OutFile "C:\projects\src\electron\datadog-ci.exe"
- cd ..
- mkdir out\Default
- cd ..
- ps: |
# Download build artifacts
$apiUrl = 'https://ci.appveyor.com/api'
$build_info = Invoke-RestMethod -Method Get -Uri "$apiUrl/projects/$env:APPVEYOR_ACCOUNT_NAME/$env:APPVEYOR_PROJECT_SLUG/builds/$env:APPVEYOR_BUILD_ID"
$artifacts_to_download = @('dist.zip','ffmpeg.zip','node_headers.zip','electron.lib', 'nan.zip')
foreach ($job in $build_info.build.jobs) {
if ($job.name -eq "Build Arm on X64 Windows") {
$jobId = $job.jobId
foreach($artifact_name in $artifacts_to_download) {
if ($artifact_name -eq 'electron.lib') {
$outfile = "src\out\Default\$artifact_name"
} else {
$outfile = $artifact_name
}
Invoke-RestMethod -Method Get -Uri "$apiUrl/buildjobs/$jobId/artifacts/$artifact_name" -OutFile $outfile
}
# Uncomment the following lines to download the pdb.zip to show real stacktraces when crashes happen during testing
Invoke-RestMethod -Method Get -Uri "$apiUrl/buildjobs/$jobId/artifacts/pdb.zip" -OutFile pdb.zip
7z x -y -osrc pdb.zip
}
}
- ps: |
$out_default_zips = @('dist.zip')
foreach($zip_name in $out_default_zips) {
7z x -y -osrc\out\Default $zip_name
}
- ps: 7z x -y -osrc\out\ffmpeg ffmpeg.zip
- ps: 7z x -y -osrc node_headers.zip
- ps: 7z x -y -osrc nan.zip
test_script:
# Workaround for https://github.com/appveyor/ci/issues/2420
- set "PATH=%PATH%;C:\Program Files\Git\mingw64\libexec\git-core"
- ps: |
cd src
New-Item .\out\Default\gen\node_headers\Release -Type directory
Copy-Item -path .\out\Default\electron.lib -destination .\out\Default\gen\node_headers\Release\node.lib
- set npm_config_nodedir=%cd%\out\Default\gen\node_headers
- set npm_config_arch=arm64
- cd electron
# Explicitly set npm_config_arch because the .env doesn't persist
- ps: >-
if ($env:TARGET_ARCH -eq 'ia32') {
$env:npm_config_arch = "ia32"
}
- ps: $env:tests_files=node script\split-tests $env:shard 2
- echo "Running shard %shard% specs %tests_files%"
- echo Running main test suite & node script/yarn test --runners=main --enable-logging --disable-features=CalculateNativeWinOcclusion --files %tests_files%
- cd ..
- echo Verifying non proprietary ffmpeg & python electron\script\verify-ffmpeg.py --build-dir out\Default --source-root %cd% --ffmpeg-path out\ffmpeg
on_finish:
# Uncomment these lines to enable RDP
# - ps: $blockRdp = $true; iex ((new-object net.webclient).DownloadString('https://raw.githubusercontent.com/appveyor/ci/master/scripts/enable-rdp.ps1'))
- if exist electron\junit\test-results-main.xml ( appveyor-retry appveyor PushArtifact electron\junit\test-results-main.xml )
- ps: |
if ($env:DD_API_KEY) {
$env:DD_GIT_COMMIT_SHA = $env:APPVEYOR_REPO_COMMIT
$env:DD_GIT_BRANCH = $env:APPVEYOR_PULL_REQUEST_HEAD_REPO_BRANCH
$env:DD_TAGS = "os.architecture:$env:TARGET_ARCH,os.family:windows,os.platform:win32"
if (Test-Path -Path "C:\projects\src\electron\junit\test-results-main.xml") {
C:\projects\src\electron\datadog-ci.exe junit upload --verbose C:\projects\src\electron\junit\test-results-main.xml
}
}

View File

@@ -1,350 +0,0 @@
# NOTE IF CHANGING THIS FILE, ALSO APPLY THE CHANGE TO appveyor-woa.yml
# IF APPLICABLE!!!!
#
#
# The config expects the following environment variables to be set:
# - "GN_CONFIG" Build type. One of {'testing', 'release'}.
# - "GN_EXTRA_ARGS" Additional gn arguments for a build config,
# e.g. 'target_cpu="x86"' to build for a 32bit platform.
# https://gn.googlesource.com/gn/+/main/docs/reference.md#var_target_cpu
# Don't forget to set up "NPM_CONFIG_ARCH" and "TARGET_ARCH" accordingly
# if you pass a custom value for 'target_cpu'.
# - "ELECTRON_RELEASE" Set it to '1' upload binaries on success.
# - "NPM_CONFIG_ARCH" E.g. 'x86'. Is used to build native Node.js modules.
# Must match 'target_cpu' passed to "GN_EXTRA_ARGS" and "TARGET_ARCH" value.
# - "TARGET_ARCH" Choose from {'ia32', 'x64', 'arm', 'arm64'}.
# Is used in some publishing scripts, but does NOT affect the Electron binary.
# Must match 'target_cpu' passed to "GN_EXTRA_ARGS" and "NPM_CONFIG_ARCH" value.
# - "UPLOAD_TO_STORAGE" Set it to '1' upload a release to the Azure bucket.
# Otherwise the release will be uploaded to the GitHub Releases.
# (The value is only checked if "ELECTRON_RELEASE" is defined.)
#
# The publishing scripts expect access tokens to be defined as env vars,
# but those are not covered here.
#
# AppVeyor docs on variables:
# https://www.appveyor.com/docs/environment-variables/
# https://www.appveyor.com/docs/build-configuration/#secure-variables
# https://www.appveyor.com/docs/build-configuration/#custom-environment-variables
version: 1.0.{build}
build_cloud: electronhq-16-core
image: e-133.0.6878.0
environment:
GIT_CACHE_PATH: C:\Users\appveyor\libcc_cache
ELECTRON_OUT_DIR: Default
ELECTRON_ENABLE_STACK_DUMPING: 1
ELECTRON_ALSO_LOG_TO_STDERR: 1
MOCHA_REPORTER: mocha-multi-reporters
MOCHA_MULTI_REPORTERS: "@marshallofsound/mocha-appveyor-reporter, mocha-junit-reporter, tap"
DEPOT_TOOLS_WIN_TOOLCHAIN: 1
DEPOT_TOOLS_WIN_TOOLCHAIN_BASE_URL: "https://dev-cdn.electronjs.org/windows-toolchains/_"
GYP_MSVS_HASH_7393122652: 3ba76c5c20
PYTHONIOENCODING: UTF-8
matrix:
- job_name: Build
- job_name: Test 1
job_depends_on: Build
shard: 1
- job_name: Test 2
job_depends_on: Build
shard: 2
clone_script:
- ps: git clone -q $("--branch=" + $Env:APPVEYOR_REPO_BRANCH) $("https://github.com/" + $Env:APPVEYOR_REPO_NAME + ".git") $Env:APPVEYOR_BUILD_FOLDER
- ps: if (!$Env:APPVEYOR_PULL_REQUEST_NUMBER) {$("git checkout -qf " + $Env:APPVEYOR_REPO_COMMIT)}
- ps: if ($Env:APPVEYOR_PULL_REQUEST_NUMBER) {git fetch -q origin +refs/pull/$($Env:APPVEYOR_PULL_REQUEST_NUMBER)/head; git checkout -qf FETCH_HEAD}
clone_folder: C:\projects\src\electron
skip_branch_with_pr: true
# the first failed job cancels other jobs and fails entire build
matrix:
fast_finish: true
for:
- matrix:
only:
- job_name: Build
build_script:
- ps: |
node script/yarn.js install --frozen-lockfile
node script/doc-only-change.js --prNumber=$env:APPVEYOR_PULL_REQUEST_NUMBER
$env:SHOULD_SKIP_ARTIFACT_VALIDATION = "false"
if ($LASTEXITCODE -eq 0) {
Write-warning "Skipping build for doc-only change"
$env:SHOULD_SKIP_ARTIFACT_VALIDATION = "true"
Exit-AppveyorBuild
} else {
$global:LASTEXITCODE = 0
}
- cd ..
- ps: Write-Host "Building $env:GN_CONFIG build"
- git config --global core.longpaths true
- ps: >-
if (Test-Path -Path "$pwd\depot_tools") {
Remove-Item -Recurse -Force $pwd\depot_tools
}
- ps: >-
if (Test-Path -Path "$pwd\build-tools") {
Remove-Item -Recurse -Force $pwd\build-tools
}
- git clone --depth=1 https://chromium.googlesource.com/chromium/tools/depot_tools.git
- ps: New-Item -Name depot_tools\.disable_auto_update -ItemType File
- depot_tools\bootstrap\win_tools.bat
- ps: |
Set-Content -Path $pwd\depot_tools\build_telemetry.cfg -Value '{"user": "info@electronjs.org", "status": "opt-out", "countdown": 10, "version": 1}'
- ps: $env:PATH="$pwd\depot_tools;$env:PATH"
- ps: >-
if (Test-Path -Path "$pwd\src\electron") {
Remove-Item -Recurse -Force $pwd\src\electron
}
- git clone https://github.com/electron/build-tools.git
- cd build-tools
- npx yarn --ignore-engines
- mkdir third_party
- ps: >-
node -e "require('./src/utils/reclient.js').downloadAndPrepare({})"
- ps: $env:RECLIENT_HELPER = node -p "require('./src/utils/reclient.js').helperPath({})"
- ps: >-
& $env:RECLIENT_HELPER login
- ps: >-
$env:RBE_service = node -e "console.log(require('./src/utils/reclient.js').serviceAddress)"
- ps: >-
$env:RBE_credentials_helper = $env:RECLIENT_HELPER
- ps: >-
$env:RBE_credentials_helper_args = "print"
- ps: >-
if ($env:ELECTRON_RBE_JWT -eq '') {
$env:RBE_fail_early_min_action_count = "0"
$env:RBE_fail_early_min_fallback_ratio = "0"
}
- cd ..\..
- ps: $env:CHROMIUM_BUILDTOOLS_PATH="$pwd\src\buildtools"
- ps: >-
if ($env:GN_CONFIG -ne 'release') {
$env:NINJA_STATUS="[%r processes, %f/%t @ %o/s : %es] "
}
- gclient config --name "src\electron" --unmanaged %GCLIENT_EXTRA_ARGS% "https://github.com/electron/electron"
# Patches are applied in the image bake. Check depshash to see if patches have changed.
- ps: $env:RUN_GCLIENT_SYNC="false"
- ps: $depshash_baked = Get-Content .\src\.depshash -Raw
- ps: cd src\electron
- ps: node script\generate-deps-hash.js
- ps: $depshash = Get-Content .\.depshash -Raw
- ps: cd ..\..
- ps: >-
if ($depshash_baked -ne $depshash) {
$env:RUN_GCLIENT_SYNC="true"
}
- if "%RUN_GCLIENT_SYNC%"=="true" ( gclient sync --with_branch_heads --with_tags ) else ( gclient runhooks )
- cd src
- ps: $env:PATH="$pwd\third_party\ninja;$env:PATH"
- set BUILD_CONFIG_PATH=//electron/build/args/%GN_CONFIG%.gn
- gn gen out/Default "--args=import(\"%BUILD_CONFIG_PATH%\") use_remoteexec=true %GN_EXTRA_ARGS% "
- gn check out/Default //electron:electron_lib
- gn check out/Default //electron:electron_app
- gn check out/Default //electron/shell/common:mojo
- gn check out/Default //electron/shell/common:plugin
- autoninja -j 300 -C out/Default electron:electron_app
- if "%GN_CONFIG%"=="testing" ( python C:\depot_tools\post_build_ninja_summary.py -C out\Default )
- gn gen out/ffmpeg "--args=import(\"//electron/build/args/ffmpeg.gn\") use_remoteexec=true %GN_EXTRA_ARGS%"
- autoninja -C out/ffmpeg electron:electron_ffmpeg_zip
- autoninja -C out/Default electron:electron_dist_zip
- gn desc out/Default v8:run_mksnapshot_default args > out/Default/default_mksnapshot_args
# Remove unused args from mksnapshot_args
- ps: >-
Get-Content out/Default/default_mksnapshot_args | Where-Object { -not $_.Contains('--turbo-profiling-input') -And -not $_.Contains('builtins-pgo') } | Set-Content out/Default/mksnapshot_args
- autoninja -C out/Default electron:electron_mksnapshot_zip
- cd out\Default
- 7z a mksnapshot.zip mksnapshot_args gen\v8\embedded.S
- cd ..\..
- autoninja -C out/Default electron:hunspell_dictionaries_zip
- autoninja -C out/Default electron:electron_chromedriver_zip
- autoninja -C out/Default electron:node_headers
- ps: >-
Get-CimInstance -Namespace root\cimv2 -Class Win32_product | Select vendor, description, @{l='install_location';e='InstallLocation'}, @{l='install_date';e='InstallDate'}, @{l='install_date_2';e='InstallDate2'}, caption, version, name, @{l='sku_number';e='SKUNumber'} | ConvertTo-Json | Out-File -Encoding utf8 -FilePath .\installed_software.json
- python3 electron/build/profile_toolchain.py --output-json=out/Default/windows_toolchain_profile.json
- 7z a node_headers.zip out\Default\gen\node_headers
- ps: >-
if ($env:GN_CONFIG -eq 'release') {
# Needed for msdia140.dll on 64-bit windows
$env:Path += ";$pwd\third_party\llvm-build\Release+Asserts\bin"
}
- if "%GN_CONFIG%"=="release" ( autoninja -C out/Default electron:electron_symbols )
- ps: >-
if ($env:GN_CONFIG -eq 'release') {
python3 electron\script\zip-symbols.py
appveyor-retry appveyor PushArtifact out/Default/symbols.zip
} else {
# It's useful to have pdb files when debugging testing builds that are
# built on CI.
7z a pdb.zip out\Default\*.pdb
}
- ps: |
if ($env:TARGET_ARCH -eq 'ia32') {
$env:MANIFEST_ARCH = "x86"
} else {
$env:MANIFEST_ARCH = $env:TARGET_ARCH
}
$manifest_file = "electron/script/zip_manifests/dist_zip.win.$env:MANIFEST_ARCH.manifest"
python3 electron/script/zip_manifests/check-zip-manifest.py out/Default/dist.zip $manifest_file
if ($LASTEXITCODE -ne 0) {
throw "Zip contains files not listed in the manifest $manifest_file"
}
- ps: |
cd C:\projects\src
$missing_artifacts = $false
if ($env:SHOULD_SKIP_ARTIFACT_VALIDATION -eq 'true') {
Write-warning "Skipping artifact validation for doc-only $env:APPVEYOR_PROJECT_NAME"
} else {
$artifacts_to_validate = 'dist.zip','windows_toolchain_profile.json','chromedriver.zip','ffmpeg.zip','node_headers.zip','mksnapshot.zip','electron.lib','hunspell_dictionaries.zip'
foreach($artifact_name in $artifacts_to_validate) {
if ($artifact_name -eq 'ffmpeg.zip') {
$artifact_file = "out\ffmpeg\ffmpeg.zip"
} elseif (
$artifact_name -eq 'node_headers.zip') {
$artifact_file = $artifact_name
} else {
$artifact_file = "out\Default\$artifact_name"
}
if (-not(Test-Path $artifact_file)) {
Write-warning "$artifact_name is missing and cannot be added to artifacts"
$missing_artifacts = $true
}
}
}
if ($missing_artifacts) {
throw "Build failed due to missing artifacts"
}
deploy_script:
- cd electron
- ps: >-
if (Test-Path Env:\ELECTRON_RELEASE) {
if (Test-Path Env:\UPLOAD_TO_STORAGE) {
Write-Output "Uploading Electron release distribution to azure"
& python3 script\release\uploaders\upload.py --verbose --upload_to_storage
} else {
Write-Output "Uploading Electron release distribution to github releases"
& python3 script\release\uploaders\upload.py --verbose
}
}
on_finish:
# Uncomment this lines to enable RDP
# - ps: $blockRdp = $true; iex ((new-object net.webclient).DownloadString('https://raw.githubusercontent.com/appveyor/ci/master/scripts/enable-rdp.ps1'))
- cd C:\projects\src
- if exist out\Default\windows_toolchain_profile.json ( appveyor-retry appveyor PushArtifact out\Default\windows_toolchain_profile.json )
- if exist out\Default\dist.zip (appveyor-retry appveyor PushArtifact out\Default\dist.zip)
- if exist out\Default\chromedriver.zip (appveyor-retry appveyor PushArtifact out\Default\chromedriver.zip)
- if exist out\ffmpeg\ffmpeg.zip (appveyor-retry appveyor PushArtifact out\ffmpeg\ffmpeg.zip)
- if exist node_headers.zip (appveyor-retry appveyor PushArtifact node_headers.zip)
- if exist out\Default\mksnapshot.zip (appveyor-retry appveyor PushArtifact out\Default\mksnapshot.zip)
- if exist out\Default\hunspell_dictionaries.zip (appveyor-retry appveyor PushArtifact out\Default\hunspell_dictionaries.zip)
- if exist out\Default\electron.lib (appveyor-retry appveyor PushArtifact out\Default\electron.lib)
- ps: >-
if ((Test-Path "pdb.zip") -And ($env:GN_CONFIG -ne 'release')) {
appveyor-retry appveyor PushArtifact pdb.zip
}
- matrix:
only:
- job_name: Test 1
- job_name: Test 2
environment:
DD_ENV: ci
DD_SERVICE: electron
DD_CIVISIBILITY_LOGS_ENABLED: true
DD_GIT_REPOSITORY_URL: "https://github.com/electron/electron.git"
ELECTRON_TEST_RESULTS_DIR: C:\projects\src\electron\junit
init:
- ps: |
if ($env:RUN_TESTS -ne 'true') {
Write-warning "Skipping tests for $env:APPVEYOR_PROJECT_NAME"; Exit-AppveyorBuild
}
build_script:
- ps: |
node script/yarn.js install --frozen-lockfile
node script/doc-only-change.js --prNumber=$env:APPVEYOR_PULL_REQUEST_NUMBER
if ($LASTEXITCODE -eq 0) {
Write-warning "Skipping build for doc only change"
Exit-AppveyorBuild
} else {
$global:LASTEXITCODE = 0
}
- npm install -g @datadog/datadog-ci
- cd ..
- mkdir out\Default
- cd ..
- ps: |
# Download build artifacts
$apiUrl = 'https://ci.appveyor.com/api'
$build_info = Invoke-RestMethod -Method Get -Uri "$apiUrl/projects/$env:APPVEYOR_ACCOUNT_NAME/$env:APPVEYOR_PROJECT_SLUG/builds/$env:APPVEYOR_BUILD_ID"
$artifacts_to_download = @('dist.zip','chromedriver.zip','ffmpeg.zip','node_headers.zip','mksnapshot.zip','electron.lib')
foreach ($job in $build_info.build.jobs) {
if ($job.name -eq "Build") {
$jobId = $job.jobId
foreach($artifact_name in $artifacts_to_download) {
if ($artifact_name -eq 'electron.lib') {
$outfile = "src\out\Default\$artifact_name"
} else {
$outfile = $artifact_name
}
Invoke-RestMethod -Method Get -Uri "$apiUrl/buildjobs/$jobId/artifacts/$artifact_name" -OutFile $outfile
}
# Uncomment the following lines to download the pdb.zip to show real stacktraces when crashes happen during testing
Invoke-RestMethod -Method Get -Uri "$apiUrl/buildjobs/$jobId/artifacts/pdb.zip" -OutFile pdb.zip
7z x -y -osrc pdb.zip
}
}
- ps: |
$out_default_zips = @('dist.zip','chromedriver.zip','mksnapshot.zip')
foreach($zip_name in $out_default_zips) {
7z x -y -osrc\out\Default $zip_name
}
- ps: 7z x -y -osrc\out\ffmpeg ffmpeg.zip
- ps: 7z x -y -osrc node_headers.zip
test_script:
# Workaround for https://github.com/appveyor/ci/issues/2420
- set "PATH=%PATH%;C:\Program Files\Git\mingw64\libexec\git-core"
- ps: |
cd src
New-Item .\out\Default\gen\node_headers\Release -Type directory
Copy-Item -path .\out\Default\electron.lib -destination .\out\Default\gen\node_headers\Release\node.lib
- cd electron
# Explicitly set npm_config_arch because the .env doesn't persist
- ps: >-
if ($env:TARGET_ARCH -eq 'ia32') {
$env:npm_config_arch = "ia32"
}
- ps: $env:tests_files=node script\split-tests $env:shard 2
- echo "Running shard %shard% specs %tests_files%"
- echo Running main test suite & node script/yarn test -- --trace-uncaught --runners=main --enable-logging --files %tests_files%
- cd ..
- echo Verifying non proprietary ffmpeg & python electron\script\verify-ffmpeg.py --build-dir out\Default --source-root %cd% --ffmpeg-path out\ffmpeg
- echo "About to verify mksnapshot"
- echo Verifying mksnapshot & python electron\script\verify-mksnapshot.py --build-dir out\Default --source-root %cd%
- echo "Done verifying mksnapshot"
- echo Verifying chromedriver & python electron\script\verify-chromedriver.py --build-dir out\Default --source-root %cd%
- echo "Done verifying chromedriver"
on_finish:
# Uncomment these lines to enable RDP
# - ps: $blockRdp = $true; iex ((new-object net.webclient).DownloadString('https://raw.githubusercontent.com/appveyor/ci/master/scripts/enable-rdp.ps1'))
- if exist electron\junit\test-results-main.xml ( appveyor-retry appveyor PushArtifact electron\junit\test-results-main.xml )
- ps: |
if ($env:RUN_TESTS -eq 'true' -And $env:DD_API_KEY) {
$env:DD_GIT_COMMIT_SHA = $env:APPVEYOR_REPO_COMMIT
$env:DD_GIT_BRANCH = $env:APPVEYOR_PULL_REQUEST_HEAD_REPO_BRANCH
$env:DD_TAGS = "os.architecture:$env:TARGET_ARCH,os.family:windows,os.platform:win32"
if (Test-Path -Path "C:\projects\src\electron\junit\test-results-main.xml") {
C:\Users\appveyor\AppData\Roaming\npm\datadog-ci.ps1 junit upload --verbose C:\projects\src\electron\junit\test-results-main.xml
}
}

View File

@@ -1,8 +1,8 @@
{
"plugins": [
"unicorn"
"import"
],
"rules": {
"unicorn/prefer-node-protocol": "error"
"import/enforce-node-protocol-usage": ["error", "always"]
}
}

View File

@@ -2,7 +2,7 @@ is_electron_build = true
root_extra_deps = [ "//electron" ]
# Registry of NMVs --> https://github.com/nodejs/node/blob/main/doc/abi_version_registry.json
node_module_version = 132
node_module_version = 145
v8_promise_internal_field_count = 1
v8_embedder_string = "-electron.0"
@@ -14,20 +14,20 @@ v8_enable_snapshot_native_code_counters = false
v8_enable_javascript_promise_hooks = true
enable_cdm_host_verification = false
proprietary_codecs = true
ffmpeg_branding = "Chrome"
proprietary_codecs = true
enable_printing = true
# Refs https://chromium-review.googlesource.com/c/chromium/src/+/6986517
# CI is using MacOS 15.5 which doesn't have the required modulemaps.
use_clang_modules = false
# Removes DLLs from the build, which are only meant to be used for Chromium development.
# See https://github.com/electron/electron/pull/17985
angle_enable_vulkan_validation_layers = false
dawn_enable_vulkan_validation_layers = false
# Removes dxc dll's that are only used experimentally.
# See https://bugs.chromium.org/p/chromium/issues/detail?id=1474897
dawn_use_built_dxc = false
# These are disabled because they cause the zip manifest to differ between
# testing and release builds.
# See https://chromium-review.googlesource.com/c/chromium/src/+/2774898.
@@ -48,7 +48,8 @@ enable_cet_shadow_stack = false
is_cfi = false
# TODO: fix this once sysroots have been updated.
use_qt = false
use_qt5 = false
use_qt6 = false
# Disables the builtins PGO for V8
v8_builtins_profiling_log_file = ""
@@ -65,18 +66,12 @@ v8_enable_private_mapping_fork_optimization = true
# Expose public V8 symbols for native modules.
v8_expose_public_symbols = true
# Disables unsafe-buffers-usage plugin due to incompatibilities with our reclient implementation
# Ref: https://chromium-review.googlesource.com/c/chromium/src/+/5426599
# Ref: https://github.com/electron/electron/commit/8e20f16ea35eeaeb149ae63bad3703d782665f6a
clang_unsafe_buffers_paths = ""
# Disable snapshotting a page when printing for its content to be analyzed for
# sensitive content by enterprise users.
enterprise_cloud_content_analysis = false
# TODO: remove dependency on legacy ipc
# https://issues.chromium.org/issues/40943039
content_enable_legacy_ipc = true
# We don't use anything from here, and it causes target collisions
enable_linux_installer = false
# Electron has its own unsafe-buffers enforcement directories.
clang_unsafe_buffers_paths = "//electron/electron_unsafe_buffers_paths.txt"
# Disable "Save to Drive" feature in PDF viewer
enable_pdf_save_to_drive = false

View File

@@ -1,7 +1,7 @@
import("all.gn")
import("//electron/build/args/all.gn")
is_component_build = false
is_component_ffmpeg = true
is_official_build = true
proprietary_codecs = false
ffmpeg_branding = "Chromium"
enable_dsyms = false
proprietary_codecs = false

View File

@@ -1,14 +1,7 @@
import("all.gn")
import("//electron/build/args/all.gn")
is_component_build = false
is_official_build = true
# This may be guarded behind is_chrome_branded alongside
# proprietary_codecs https://webrtc-review.googlesource.com/c/src/+/36321,
# explicitly override here to build OpenH264 encoder/FFmpeg decoder.
# The initialization of the decoder depends on whether ffmpeg has
# been built with H.264 support.
rtc_use_h264 = proprietary_codecs
# By default, Electron builds ffmpeg with proprietary codecs enabled. In order
# to facilitate users who don't want to ship proprietary codecs in ffmpeg, or
# who have an LGPL requirement to ship ffmpeg as a dynamically linked library,

View File

@@ -1,14 +1,7 @@
import("all.gn")
import("//electron/build/args/all.gn")
is_debug = false
is_component_build = false
is_component_ffmpeg = true
is_official_build = false
dcheck_always_on = true
symbol_level = 1
# This may be guarded behind is_chrome_branded alongside
# proprietary_codecs https://webrtc-review.googlesource.com/c/src/+/36321,
# explicitly override here to build OpenH264 encoder/FFmpeg decoder.
# The initialization of the decoder depends on whether ffmpeg has
# been built with H.264 support.
rtc_use_h264 = proprietary_codecs

37
build/checksum_header.py Normal file
View File

@@ -0,0 +1,37 @@
#!/usr/bin/env python3
import os
import sys
import hashlib
dir_path = os.path.dirname(os.path.realpath(__file__))
TEMPLATE_H = """
#ifndef ELECTRON_SNAPSHOT_CHECKSUM_H_
#define ELECTRON_SNAPSHOT_CHECKSUM_H_
namespace electron::snapshot_checksum {
inline constexpr std::string_view kChecksum = "{checksum}";
} // namespace electron::snapshot_checksum
#endif // ELECTRON_SNAPSHOT_CHECKSUM_H_
"""
def calculate_sha256(filepath):
sha256_hash = hashlib.sha256()
with open(filepath, "rb") as f:
for byte_block in iter(lambda: f.read(4096), b""):
sha256_hash.update(byte_block)
return sha256_hash.hexdigest()
input_file = sys.argv[1]
output_file = sys.argv[2]
checksum = calculate_sha256(input_file)
checksum_h = TEMPLATE_H.replace("{checksum}", checksum)
with open(output_file, 'w') as f:
f.write(checksum_h)

View File

@@ -55,7 +55,6 @@ template("electron_extra_paks") {
"$root_gen_dir/chrome/accessibility_resources.pak",
"$root_gen_dir/chrome/browser_resources.pak",
"$root_gen_dir/chrome/common_resources.pak",
"$root_gen_dir/chrome/dev_ui_browser_resources.pak",
"$root_gen_dir/components/components_resources.pak",
"$root_gen_dir/content/browser/resources/media/media_internals_resources.pak",
"$root_gen_dir/content/browser/tracing/tracing_resources.pak",
@@ -69,7 +68,6 @@ template("electron_extra_paks") {
"$target_gen_dir/electron_resources.pak",
]
deps = [
"//chrome/browser:dev_ui_browser_resources",
"//chrome/browser:resources",
"//chrome/browser/resources/accessibility:resources",
"//chrome/common:resources",
@@ -85,7 +83,7 @@ template("electron_extra_paks") {
"//net:net_resources",
"//third_party/blink/public:devtools_inspector_resources",
"//third_party/blink/public:resources",
"//ui/resources",
"//ui/webui/resources",
]
if (defined(invoker.deps)) {
deps += invoker.deps
@@ -98,7 +96,7 @@ template("electron_extra_paks") {
sources += [
"$root_gen_dir/content/browser/devtools/devtools_resources.pak",
"$root_gen_dir/content/process_resources.pak",
"$root_gen_dir/ui/resources/webui_resources.pak",
"$root_gen_dir/ui/webui/resources/webui_resources.pak",
]
deps += [ "//content/browser/devtools:devtools_resources" ]
if (enable_pdf_viewer) {
@@ -178,7 +176,7 @@ template("electron_paks") {
}
source_patterns = [
"${root_gen_dir}/chrome/chromium_strings_",
"${root_gen_dir}/chrome/branded_strings_",
"${root_gen_dir}/chrome/locale_settings_",
"${root_gen_dir}/chrome/platform_locale_settings_",
"${root_gen_dir}/chrome/generated_resources_",

View File

@@ -2,7 +2,7 @@
<!-- The Resource ids for messages start from 31750 and for includes
it starts from 31950, make sure they don't overlap when the limit
exceeds in //tools/gritsettings/resource_ids -->
<grit latest_public_release="0" current_release="1" output_all_resource_defines="false"
<grit latest_public_release="0" current_release="1"
source_lang_id="en">
<outputs>
<output filename="grit/electron_resources.h" type="rc_header">

Some files were not shown because too many files have changed in this diff Show More