-
Notifications
You must be signed in to change notification settings - Fork 982
Upgrade from Chromium 137 to Chromium 138 #28944
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Conversation
A Storybook has been deployed to preview UI for the latest push |
Warning You have got a presubmit warning. Please address it if possible.
|
1 similar comment
Warning You have got a presubmit warning. Please address it if possible.
|
Warning You have got a presubmit warning. Please address it if possible.
|
Warning You have got a presubmit warning. Please address it if possible.
|
3d24600
to
865369f
Compare
std::make_unique<permissions::ContentSettingPermissionResolver>( | ||
permissions::RequestType::kWidevine), | ||
false, | ||
web_contents->GetVisibleURL()), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
reported by reviewdog 🐶
[semgrep] GetVisibleURL usages should be vet by the security-team. Most of the time you want the last committed entry/url
Source: https://github.com/brave/security-action/blob/main/assets/semgrep_rules/client/get-visible-entry.yaml
Cc @thypon @diracdeltas @bridiver
std::make_unique<permissions::ContentSettingPermissionResolver>( | ||
permissions::RequestType::kWidevine), | ||
false, | ||
web_contents->GetVisibleURL()), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
reported by reviewdog 🐶
[semgrep] GetVisibleURL usages should be vet by the security-team. Most of the time you want the last committed entry/url
Source: https://github.com/brave/security-action/blob/main/assets/semgrep_rules/client/get-visible-entry.yaml
Cc @thypon @diracdeltas @bridiver
return ProfileManager.getLastUsedRegularProfile(); | ||
} else { | ||
return assertNonNull( | ||
ProfileManager.getLastUsedRegularProfile().getPrimaryOtrProfile(true)); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
reported by reviewdog 🐶
[semgrep] Static methods to access the profile will become a problem when android allows multiple profiles. Also these methods can be dangerous when we need to distinguish between the regular and incognito profile (services factories, etc...)
Source: https://github.com/brave/security-action/blob/main/assets/semgrep_rules/client/android-profile-static.yaml
Cc @bridiver
732e509
to
067fbc8
Compare
This is part of a broader modularisation of the browser, and it should only affect inclusion paths, namespacing, and gn deps. Chromium changes: https://chromium.googlesource.com/chromium/src/+/88975c35e41b18a6a94e5c1093001bb7b9cbbf42 commit 88975c35e41b18a6a94e5c1093001bb7b9cbbf42 Author: Alexis Hetu <[email protected]> Date: Mon May 26 05:43:21 2025 -0700 Move ImportedBookmarkEntry to components/ This CL moves the 2 following files: - imported_bookmark_entry.h - imported_bookmark_entry.cc from "chrome/common/importer/" to "components/user_data_importer/common/". The CL itself is noop, it is only adjusting the code for the file location and namespace changes. Bug: 407587751 Change-Id: I6fa486ff92cdd2d36a3aeb879111d90c518b0974 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6578818 Commit-Queue: Colin Blundell <[email protected]> Reviewed-by: Ken Buchanan <[email protected]> Reviewed-by: Colin Blundell <[email protected]> Auto-Submit: Alexis Hétu <[email protected]> Cr-Commit-Position: refs/heads/main@{#1465477}
Chromium change: https://source.chromium.org/chromium/chromium/src/+/e463135800447a2dbe772ba070e03cef518bee58 commit e463135800447a2dbe772ba070e03cef518bee58 Author: Sylvain Defresne <[email protected]> Date: Thu May 15 00:59:16 2025 -0700 [ios] Use ScopedProfileKeepAliveIOS to manage ProfileIOS lifetime Instead of explicitly calling `UnloadProfile(...)` to unload a profile on `ProfileManagerIOS`, use `ScopedProfileKeepAliveIOS` to manage the lifetime of the objects. This removes the code to manually unload the profiles as it is difficult to have both work together and the manual version can always be emulated by using `ScopedProfileKeepAliveIOS`.
The use of warnings in B🚀 is reserved for things that are truly atypical. With broken patches during 3way merge, a warning is being always issued becuase the main reason for broken patches was not accounted for when checking for unknown reasons for broken patches.
…dBuilderFeedCard.java
This function was removed upstream, so @simonhong reworked our override to account for this. Chromium changes: https://chromium.googlesource.com/chromium/src/+/1b2ba827b56fbf2b0ae7105e96e320b6421915a0 commit 1b2ba827b56fbf2b0ae7105e96e320b6421915a0 Author: Steven Luong <[email protected]> Date: Thu May 1 14:45:59 2025 -0700 [SxS] Loosen coupling between split tab menu and the active tab Currently split tab icons are determined based on the assumption the active tab is in a split. This CL determines which icon to show based on which tab in a split was last active instead of which one is currently active. There are also multiple instances of retrieving the active tab from the tab strip model to get the split id. This CL puts this logic into a single function to remove code duplication and makes it easier to add code to support cases when the menu should be shown but the active tab is not in a split (ex. opening tab context menu on an inactive split tab). Bug: 403350993 Change-Id: I9b212c5a51f1f6099a1a08c203ca4247545e829f Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6498652 Commit-Queue: Steven Luong <[email protected]> Reviewed-by: Alison Gale <[email protected]> Reviewed-by: Eshwar Stalin <[email protected]> Cr-Commit-Position: refs/heads/main@{#1454685}
It was a name overlapping with the one from `obj/third_party/androidx/androidx_credentials_credentials_java/res/drawable/ic_password.xml` Chromium change probably: https://source.chromium.org/chromium/chromium/src/+/dc70a40afac9726a01aa7c5330e0c51c2dc58a4b [DC] Move the DigitalCredentialsCreationDelegateImpl to the public code The androidx library has been released to the public and hence no need to keep it in the internal code. This CL is introducing minor behavioral changes limited to Null checks. The diff between the version in the internal code and this one is in http://go/webdiff#key=iVg4KJsYe0Gu Follow-up CLs will remove the internal pieces. Bug: 415967212 Change-Id: Ief2df4b1654d9d2ea54506d9c846ea02dbbe0597 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6523383
This fixes menu footer buttons. Chromium change: https://source.chromium.org/chromium/chromium/src/+/fa431a3660de796f7aa18130fd8a6da39f1cc1d7 [Icon Button] Migrate app menu icon buttons Migrated the app menu top row icons from ChromeImageButtons to Material Buttons. The highlight (ripple) is now a perfect circle instead of rectangle. Bug: 405189559 Change-Id: I0376bf0ecf7f5b734dad2d7e8c69200834c54248 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6477118
The `update-counter-text` WebUI listener was renamed to `browsing-data-counter-text-update`. We hook into this code to provide the "counter" sublabels for the "Clear Browsing Data on Exit" dialog. Chromium change: https://source.chromium.org/chromium/chromium/src/+/5d91cbf0c11a3757cef76db44c2d29b5ac4a124e commit 5d91cbf0c11a3757cef76db44c2d29b5ac4a124e Author: Zaina Al-Mashni <[email protected]> Date: Fri May 9 14:41:27 2025 -0700 [Settings] Hook the counters with the CBD dialog checkboxes This change uses the ClearBrowsingDataBrowserProxy to trigger the browsing data counters on time period changes and updates each checkbox's subLabel with the result. It also updates the registered advanced and basic counters in the ClearBrowsingDataHandler based on the kDbdRevampDesktop flag status. Screenshot: https://screenshot.googleplex.com/5P8p9uz2LeQUgje Bug: 397187800 Change-Id: If0db18f856a55477fb9563d1dbc3924f750af9d9 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6513117 Reviewed-by: Martin Šrámek <[email protected]> Commit-Queue: Zaina Al-Mashni <[email protected]> Reviewed-by: Rainhard Findling <[email protected]> Cr-Commit-Position: refs/heads/main@{#1458360}
…://settings Now that `EnableCertManagementUIV2` is launched we no longer need to maintain the old override to delete the `chromeCertificates` link. Chromium change: https://source.chromium.org/chromium/chromium/src/+/ed3377471e1c04dcc5cb7047d611f645b831d612 commit ed3377471e1c04dcc5cb7047d611f645b831d612 Author: dpapad <[email protected]> Date: Wed May 21 17:49:52 2025 -0700 Settings: Cleanup dead code after launch of EnableCertManagementUIV2. Bug: 390333881 Change-Id: I375a5617e91ea69652722efa887b0c98770d0ec3 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6568874 Commit-Queue: Matt Mueller <[email protected]> Commit-Queue: Demetrios Papadopoulos <[email protected]> Auto-Submit: Demetrios Papadopoulos <[email protected]> Reviewed-by: Matt Mueller <[email protected]> Cr-Commit-Position: refs/heads/main@{#1463820}
…utton in brave://settings/cookies We no longer show any of the radio buttons on the brave://settings/cookies page, so we can remove this code which was hiding one of the radio button options. Also, hide the "Advanced" header as we currently hide all of the advanced settings so that section is empty. This change happened prior to cr138, but we're cleaning it up here as it was noticed during testing. Chromium change: https://source.chromium.org/chromium/chromium/src/+/d3779b3905edf74c86c1714731574f63c3a2d486 commit d3779b3905edf74c86c1714731574f63c3a2d486 Author: Maggie Jennings <[email protected]> Date: Thu Feb 20 12:42:02 2025 -0800 [CCM] Finalized strings for settings pt.1 - Settings go/ccm-unification-prd Desktop screenshot w/ new content: https://screenshot.googleplex.com/4V4U8LU5th6Mffj Clank screenshot: https://screenshot.googleplex.com/4ACqpQ5H6MWYZ9A Wordflow: https://wordflow.corp.google.com/project/180286/version/115#WORDFLOW_SCREEN_ID=341669 Bug: b:370008370 Change-Id: Idc9854a5d1fc1d38700de380cc7ffb5a46dda942 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6269999 Auto-Submit: Maggie Jennings <[email protected]> Reviewed-by: Fiona Macintosh <[email protected]> Reviewed-by: Michelle Abreo <[email protected]> Commit-Queue: Maggie Jennings <[email protected]> Cr-Commit-Position: refs/heads/main@{#1422735}
Chromium updated some TabStyle method. https://chromium-review.googlesource.com/c/chromium/src/+/6518822
Use SharedPreferencesManager instead to access app-wide SharedPreferences from //src/chrome
Depending on a feature setting, the tab search button is now rehomed to the toolbar so support that. Chromium change: https://source.chromium.org/chromium/chromium/src/+/9cd72e1a9429531600a4ae310fdb6863cb39fe37 commit 9cd72e1a9429531600a4ae310fdb6863cb39fe37 Author: Eshwar Stalin <[email protected]> Date: Thu May 15 08:55:41 2025 -0700 Enable Tab Search Rehoming on ToT Change-Id: Id8a92bbcee8eac7cc328aad488940ff24824b9e9 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6550038 Reviewed-by: Alison Gale <[email protected]> Commit-Queue: Alison Gale <[email protected]> Cr-Commit-Position: refs/heads/main@{#1460759}
This patching is not needed in 138 anymore, as it has landed in upstream. Chromium changes: https://chromium.googlesource.com/chromium/src/+/4b7e1adf413943fc48c8ce865511079fed271cf8 commit 4b7e1adf413943fc48c8ce865511079fed271cf8 Author: Maksim Moskvitin <[email protected]> Date: Fri May 23 06:17:53 2025 -0700 Revert "Sync ProcessorEntity: Upgrade remaining DCHECKs" This reverts commit 6752bab9ae006f82bdd1bf73a475ffffd2fa2d00. Reason for revert: Still crashing on M137 Bug: 408182457, 419310731 Original change's description: > Sync ProcessorEntity: Upgrade remaining DCHECKs > > This CL upgrades most of the remaining DCHECKs in ProcessorEntity to > proper CHECKs, mostly with base::NotFatalUntil::M141. > A few that are obviously-valid don't have NotFatalUntil, and one that > is questionable is just removed. > > Also includes some minor other cleanups, like inlining a one-line > helper method with a single call site. > > Bug: 408182457 > Change-Id: I7e385de3b6d2953ff9cac62f40e3ebb5651219b8 > Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6461075 > Reviewed-by: Maksim Moskvitin <[email protected]> > Commit-Queue: Marc Treib <[email protected]> > Cr-Commit-Position: refs/heads/main@{#1448230} Bug: 408182457 Change-Id: Ib5d538c4ebd2aabb9cb0cd27416fba02187945cc Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6578201 Auto-Submit: Maksim Moskvitin <[email protected]> Commit-Queue: Mikel Astiz <[email protected]> Commit-Queue: Maksim Moskvitin <[email protected]> Reviewed-by: Mikel Astiz <[email protected]> Cr-Commit-Position: refs/heads/main@{#1464694}
base::FilePath path = base::PathService::CheckedGet(chrome::DIR_USER_DATA); | ||
crx_cache_ = base::MakeRefCounted<update_client::CrxCache>( | ||
path.AppendASCII("component_crx_cache")); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Upstream seems to not want to crash here and operates without cache, do we not want to do the same?
base::FilePath path;
bool result = base::PathService::Get(chrome::DIR_USER_DATA, &path);
crx_cache_ = base::MakeRefCounted<update_client::CrxCache>(
result ? std::optional<base::FilePath>(
path.AppendASCII("component_crx_cache"))
: std::nullopt);
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good catch, fixed here 30e15de.
Warning You have got a presubmit warning. Please address it if possible.
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
iOS++
// Replace MaybeStartFetch with an innocuous call, as we don't want to download | ||
// the popular sites | ||
#define MaybeStartFetch(...) sections() | ||
#define BRAVE_MOST_VISITED_SITES_CREATE_POPULAR_SITES_SECTIONS return sections; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not 100% sure, but would it be possible instead of patching to override popular_sites_(...) popular_sites_(nullptr)
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yep, that seems to work, thanks for pointing out that trick again! 37c8a83
crypto::SHA256HashString(decoded_public_key, component_hash_.data(), | ||
component_hash_.size()); | ||
auto decoded_public_key = | ||
base::Base64Decode(kBraveUserAgentExceptionsComponentBase64PublicKey); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this should be an already calculated sha256 hash at compile-time stored in uint8_t[].
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good point, fixed here 4042030.
extensions/BUILD.gn
Outdated
@@ -8,8 +8,7 @@ import("//extensions/buildflags/buildflags.gni") | |||
if (is_android || is_ios) { | |||
source_set("common") { | |||
sources = [ | |||
"//extensions/common/constants.cc", | |||
|
|||
# "//extensions/common/constants.cc", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
shouldn't we add //build:chromeos_buildflags
to deps instead?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
cc: @AlexeyBarabash
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
strings
++
Resolves brave/brave-browser#45859
Submitter Checklist:
QA/Yes
orQA/No
;release-notes/include
orrelease-notes/exclude
;OS/...
) to the associated issuenpm run test -- brave_browser_tests
,npm run test -- brave_unit_tests
wikinpm run presubmit
wiki,npm run gn_check
,npm run tslint
git rebase master
(if needed)Reviewer Checklist:
gn
After-merge Checklist:
changes has landed on
Test Plan: