From e2f6e147d06cc5c0c7bed83249d3fb0ec3dd27dd Mon Sep 17 00:00:00 2001 From: Simon Stewart Date: Mon, 26 Aug 2024 10:04:44 +0100 Subject: [PATCH 01/55] [bazel] Use the `release` configs for the release tasks (#14423) Rather than passing `--stamp` everywhere, use a proper config so that we can easily add additional flags. I've broken out a `remote_release` config which builds things remotely and then downloads the artifacts given on the command line to the local machine. This only makes sense for targets which we do _not_ `run` (as `run` happens locally, so we'd need to rebuild any artifacts anyway) Co-authored-by: Diego Molina --- .bazelrc | 8 +++++++- Rakefile | 23 ++++++++++++----------- 2 files changed, 19 insertions(+), 12 deletions(-) diff --git a/.bazelrc b/.bazelrc index 281fcd02ad7d50..f0031fc19eab8d 100644 --- a/.bazelrc +++ b/.bazelrc @@ -102,8 +102,14 @@ test --test_timeout=1800 test:node_debug --test_output=streamed --test_strategy=exclusive --test_timeout=9999 --nocache_test_results test:ruby_debug --test_output=streamed --test_env=RUBY_DEBUG_FORK_MODE=parent --run_under="@bundle//bin:rdbg --nonstop --open --command" -build:release --config=remote + build:release --stamp +build:release --compilation_mode=opt + +# As regular `release` but all the build work happens on the RBE +build:remote_release --config=release +build:remote_release --config=remote +build:remote_release --remote_download_toplevel # RBE import %workspace%/.bazelrc.remote diff --git a/Rakefile b/Rakefile index 0dc22a2ebeba19..408c766a1f4feb 100644 --- a/Rakefile +++ b/Rakefile @@ -331,7 +331,7 @@ task ios_driver: [ # ./go java:package['--config=release'] desc 'Create stamped zipped assets for Java for uploading to GitHub' task :'java-release-zip' do - Rake::Task['java:package'].invoke('--stamp') + Rake::Task['java:package'].invoke('--config=remote_release') end task 'release-java': %i[java-release-zip publish-maven] @@ -450,7 +450,7 @@ namespace :node do nightly = args.delete('nightly') Rake::Task['node:version'].invoke('nightly') if nightly - Bazel.execute('run', ['--stamp'], '//javascript/node/selenium-webdriver:selenium-webdriver.publish') + Bazel.execute('run', ['--config=release'], '//javascript/node/selenium-webdriver:selenium-webdriver.publish') end desc 'Release Node npm package' @@ -513,7 +513,7 @@ namespace :py do Rake::Task['py:version'].invoke('nightly') if nightly command = nightly ? '//py:selenium-release-nightly' : '//py:selenium-release' - Bazel.execute('run', ['--stamp'], command) + Bazel.execute('run', ['--config=release'], command) end desc 'generate and copy files required for local development' @@ -680,10 +680,10 @@ namespace :rb do if nightly Bazel.execute('run', [], '//rb:selenium-webdriver-bump-nightly-version') - Bazel.execute('run', ['--stamp'], '//rb:selenium-webdriver-release-nightly') + Bazel.execute('run', ['--config=release'], '//rb:selenium-webdriver-release-nightly') else - Bazel.execute('run', ['--stamp'], '//rb:selenium-webdriver-release') - Bazel.execute('run', ['--stamp'], '//rb:selenium-devtools-release') + Bazel.execute('run', ['--config=release'], '//rb:selenium-webdriver-release') + Bazel.execute('run', ['--config=release'], '//rb:selenium-devtools-release') end end @@ -753,7 +753,7 @@ namespace :dotnet do args = arguments.to_a.compact nightly = args.delete('nightly') Rake::Task['dotnet:version'].invoke('nightly') if nightly - Rake::Task['dotnet:package'].invoke('--stamp') + Rake::Task['dotnet:package'].invoke('--config=remote_release') api_key = ENV.fetch('NUGET_API_KEY', nil) push_destination = 'https://api.nuget.org/v3/index.json' @@ -839,7 +839,7 @@ namespace :java do desc 'Package Java bindings and grid into releasable packages and stage for release' task :package do |_task, arguments| - args = arguments.to_a.compact.empty? ? ['--stamp'] : arguments.to_a.compact + args = arguments.to_a.compact.empty? ? ['--config=release'] : arguments.to_a.compact Bazel.execute('build', args, '//java/src/org/openqa/selenium:client-zip') Bazel.execute('build', args, '//java/src/org/openqa/selenium/grid:server-zip') Bazel.execute('build', args, '//java/src/org/openqa/selenium/grid:executable-grid') @@ -872,9 +872,10 @@ namespace :java do ENV['GPG_SIGN'] = (!nightly).to_s Rake::Task['java:version'].invoke if nightly - Rake::Task['java:package'].invoke('--stamp') - Rake::Task['java:build'].invoke('--stamp') - JAVA_RELEASE_TARGETS.each { |target| Bazel.execute('run', ['--stamp'], target) } + Rake::Task['java:package'].invoke('--config=release') + Rake::Task['java:build'].invoke('--config=release') + # Because we want to `run` things, we can't use the `release` config + JAVA_RELEASE_TARGETS.each { |target| Bazel.execute('run', ['--config=release'], target) } end desc 'Install jars to local m2 directory' From 424fdfab5bde707e7e6dcce695abddfa918b95b9 Mon Sep 17 00:00:00 2001 From: Diego Molina Date: Mon, 26 Aug 2024 14:50:11 +0200 Subject: [PATCH 02/55] Add delete comments workflow (#14439) We are getting spam in the issues' comments. This should get rid of it. --- For more details, open the [Copilot Workspace session](https://copilot-workspace.githubnext.com/SeleniumHQ/selenium?shareId=XXXX-XXXX-XXXX-XXXX). --- delete-comments.yml | 45 +++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 45 insertions(+) create mode 100644 delete-comments.yml diff --git a/delete-comments.yml b/delete-comments.yml new file mode 100644 index 00000000000000..50b2eae5e950bf --- /dev/null +++ b/delete-comments.yml @@ -0,0 +1,45 @@ +name: Delete Comments + +on: + issue_comment: + types: [created] + +permissions: + issues: write + +jobs: + delete_comment: + runs-on: ubuntu-latest + steps: + - name: Check for specific strings in comment + id: check_comment + uses: actions/github-script@v6 + with: + script: | + const comment = context.payload.comment.body; + const triggerStrings = ['www.mediafire.com', 'Download']; + return triggerStrings.some(triggerString => comment.includes(triggerString)); + + - name: Delete comment if it contains any of the specific strings + if: steps.check_comment.outputs.result == 'true' + uses: actions/github-script@v6 + with: + script: | + const commentId = context.payload.comment.id; + await github.issues.deleteComment({ + owner: context.repo.owner, + repo: context.repo.repo, + comment_id: commentId + }); + + - name: Block user if comment contains any of the specific strings + if: steps.check_comment.outputs.result == 'true' + uses: actions/github-script@v6 + with: + script: | + const userId = context.payload.comment.user.id; + await github.users.block({ + owner: context.repo.owner, + repo: context.repo.repo, + user_id: userId + }); From 96fc6ce4ee69f70645414b3be5fbd0d793fe15c3 Mon Sep 17 00:00:00 2001 From: Diego Molina Date: Mon, 26 Aug 2024 16:01:47 +0200 Subject: [PATCH 03/55] Moving workflow file to correct directory --- delete-comments.yml => .github/workflows/delete-comments.yml | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename delete-comments.yml => .github/workflows/delete-comments.yml (100%) diff --git a/delete-comments.yml b/.github/workflows/delete-comments.yml similarity index 100% rename from delete-comments.yml rename to .github/workflows/delete-comments.yml From 3963bb83f27b2bd6c536617fd13daa5d9becb69c Mon Sep 17 00:00:00 2001 From: Diego Molina Date: Mon, 26 Aug 2024 16:22:16 +0200 Subject: [PATCH 04/55] Bumping action version --- .github/workflows/delete-comments.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/delete-comments.yml b/.github/workflows/delete-comments.yml index 50b2eae5e950bf..e5319d07256220 100644 --- a/.github/workflows/delete-comments.yml +++ b/.github/workflows/delete-comments.yml @@ -13,7 +13,7 @@ jobs: steps: - name: Check for specific strings in comment id: check_comment - uses: actions/github-script@v6 + uses: actions/github-script@v7 with: script: | const comment = context.payload.comment.body; @@ -22,7 +22,7 @@ jobs: - name: Delete comment if it contains any of the specific strings if: steps.check_comment.outputs.result == 'true' - uses: actions/github-script@v6 + uses: actions/github-script@v7 with: script: | const commentId = context.payload.comment.id; @@ -34,7 +34,7 @@ jobs: - name: Block user if comment contains any of the specific strings if: steps.check_comment.outputs.result == 'true' - uses: actions/github-script@v6 + uses: actions/github-script@v7 with: script: | const userId = context.payload.comment.user.id; From f0fdb9e5d28c4c2e94e7b30745dca281092d8dac Mon Sep 17 00:00:00 2001 From: Puja Jagani Date: Tue, 27 Aug 2024 11:32:27 +0530 Subject: [PATCH 05/55] [java][js] Fixing prompt/alert related tests if BiDi is enabled --- java/test/org/openqa/selenium/testing/drivers/Browser.java | 5 +++++ .../node/selenium-webdriver/bidi/browsingContextInspector.js | 4 ++-- javascript/node/selenium-webdriver/testing/index.js | 1 + 3 files changed, 8 insertions(+), 2 deletions(-) diff --git a/java/test/org/openqa/selenium/testing/drivers/Browser.java b/java/test/org/openqa/selenium/testing/drivers/Browser.java index 0675dbe04b32bc..9b2ddfb2e5a4de 100644 --- a/java/test/org/openqa/selenium/testing/drivers/Browser.java +++ b/java/test/org/openqa/selenium/testing/drivers/Browser.java @@ -18,6 +18,7 @@ package org.openqa.selenium.testing.drivers; import static org.openqa.selenium.remote.CapabilityType.BROWSER_NAME; +import static org.openqa.selenium.remote.CapabilityType.UNHANDLED_PROMPT_BEHAVIOUR; import java.util.HashMap; import java.util.Map; @@ -61,6 +62,9 @@ public Capabilities getCapabilities() { options.enableBiDi(); + // Reason: https://github.com/SeleniumHQ/selenium/pull/14429#issuecomment-2311614822 + options.setCapability(UNHANDLED_PROMPT_BEHAVIOUR, "ignore"); + return options; } }, @@ -91,6 +95,7 @@ public Capabilities getCapabilities() { options.setExperimentalOption("prefs", prefs); options.enableBiDi(); + options.setCapability(UNHANDLED_PROMPT_BEHAVIOUR, "ignore"); return options; } diff --git a/javascript/node/selenium-webdriver/bidi/browsingContextInspector.js b/javascript/node/selenium-webdriver/bidi/browsingContextInspector.js index b6bcecf70decf2..e4d1725782a828 100644 --- a/javascript/node/selenium-webdriver/bidi/browsingContextInspector.js +++ b/javascript/node/selenium-webdriver/bidi/browsingContextInspector.js @@ -127,10 +127,10 @@ class BrowsingContextInspector { let response = null if ('navigation' in params) { response = new NavigationInfo(params.context, params.navigation, params.timestamp, params.url) - } else if ('type' in params) { - response = new UserPromptOpened(params.context, params.type, params.message) } else if ('accepted' in params) { response = new UserPromptClosed(params.context, params.accepted, params.userText) + } else if ('type' in params) { + response = new UserPromptOpened(params.context, params.type, params.message) } else { response = new BrowsingContextInfo(params.context, params.url, params.children, params.parent) } diff --git a/javascript/node/selenium-webdriver/testing/index.js b/javascript/node/selenium-webdriver/testing/index.js index c96f18d453592a..d48bb4affd9f8c 100644 --- a/javascript/node/selenium-webdriver/testing/index.js +++ b/javascript/node/selenium-webdriver/testing/index.js @@ -346,6 +346,7 @@ class Environment { // Enable BiDi for supporting browsers. if (browser.name === Browser.FIREFOX || browser.name === Browser.CHROME || browser.name === Browser.EDGE) { builder.setCapability('webSocketUrl', true) + builder.setCapability('unhandledPromptBehavior', 'ignore') } if (typeof urlOrServer === 'string') { From 44cf4a43fdd7e65e0c2554aa032c7e9c19f68e80 Mon Sep 17 00:00:00 2001 From: Puja Jagani Date: Tue, 27 Aug 2024 11:57:01 +0530 Subject: [PATCH 06/55] [java] Hacky fix for the Chrome keyboard input test --- .../openqa/selenium/bidi/input/DefaultKeyboardTest.java | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/java/test/org/openqa/selenium/bidi/input/DefaultKeyboardTest.java b/java/test/org/openqa/selenium/bidi/input/DefaultKeyboardTest.java index dbab8ada2fbd47..a712881a18f7ff 100644 --- a/java/test/org/openqa/selenium/bidi/input/DefaultKeyboardTest.java +++ b/java/test/org/openqa/selenium/bidi/input/DefaultKeyboardTest.java @@ -201,7 +201,7 @@ void canGenerateKeyboardShortcuts() { @NotYetImplemented( value = EDGE, reason = "https://github.com/GoogleChromeLabs/chromium-bidi/issues/2321") - public void testSelectionSelectBySymbol() { + public void testSelectionSelectBySymbol() throws InterruptedException { driver.get(appServer.whereIs("single_text_input.html")); WebElement input = driver.findElement(By.id("textInput")); @@ -209,6 +209,11 @@ public void testSelectionSelectBySymbol() { inputModule.perform( windowHandle, getBuilder(driver).click(input).sendKeys("abc def").getSequences()); + // TODO: The wait until condition does not wait for the attribute. + // Hence this is required. + // Not an ideal fix but it needs to be triaged further. + Thread.sleep(5000); + shortWait.until(ExpectedConditions.attributeToBe(input, "value", "abc def")); inputModule.perform( From f9b043e2871ac3fe3a498c7ee9c0d3a6a56ff3e5 Mon Sep 17 00:00:00 2001 From: Puja Jagani Date: Tue, 27 Aug 2024 12:54:57 +0530 Subject: [PATCH 07/55] [java] Enable tests in Edge --- .../org/openqa/selenium/bidi/input/DefaultKeyboardTest.java | 3 --- 1 file changed, 3 deletions(-) diff --git a/java/test/org/openqa/selenium/bidi/input/DefaultKeyboardTest.java b/java/test/org/openqa/selenium/bidi/input/DefaultKeyboardTest.java index a712881a18f7ff..47c15536581b9a 100644 --- a/java/test/org/openqa/selenium/bidi/input/DefaultKeyboardTest.java +++ b/java/test/org/openqa/selenium/bidi/input/DefaultKeyboardTest.java @@ -198,9 +198,6 @@ void canGenerateKeyboardShortcuts() { } @Test - @NotYetImplemented( - value = EDGE, - reason = "https://github.com/GoogleChromeLabs/chromium-bidi/issues/2321") public void testSelectionSelectBySymbol() throws InterruptedException { driver.get(appServer.whereIs("single_text_input.html")); From f4518b89563fc83afdc16f49455731987dfbafce Mon Sep 17 00:00:00 2001 From: Puja Jagani Date: Tue, 27 Aug 2024 13:37:33 +0530 Subject: [PATCH 08/55] [py] Add unhandled prompt behavior to 'ignore' option if BiDi is enabled (#14440) --- py/conftest.py | 1 + 1 file changed, 1 insertion(+) diff --git a/py/conftest.py b/py/conftest.py index f2189b6fa5dd87..d5bf9aca8c1ea4 100644 --- a/py/conftest.py +++ b/py/conftest.py @@ -215,6 +215,7 @@ def get_options(driver_class, config): options = getattr(webdriver, f"{driver_class}Options")() options.web_socket_url = True + options.unhandled_prompt_behavior = "ignore" return options From 88f00af2fd5bd61a5bd347df1aaa5b4fcc7b48dc Mon Sep 17 00:00:00 2001 From: Puja Jagani Date: Tue, 27 Aug 2024 14:19:30 +0530 Subject: [PATCH 09/55] [java] Enable navigation event test in Chrome and Edge --- .../bidi/browsingcontext/BrowsingContextInspectorTest.java | 2 -- 1 file changed, 2 deletions(-) diff --git a/java/test/org/openqa/selenium/bidi/browsingcontext/BrowsingContextInspectorTest.java b/java/test/org/openqa/selenium/bidi/browsingcontext/BrowsingContextInspectorTest.java index 548aa1ded5e8b1..16256f9ad5a4d2 100644 --- a/java/test/org/openqa/selenium/bidi/browsingcontext/BrowsingContextInspectorTest.java +++ b/java/test/org/openqa/selenium/bidi/browsingcontext/BrowsingContextInspectorTest.java @@ -139,8 +139,6 @@ void canListenToBrowsingContextLoadedEvent() } @Test - @NotYetImplemented(CHROME) - @NotYetImplemented(EDGE) void canListenToNavigationStartedEvent() throws ExecutionException, InterruptedException, TimeoutException { try (BrowsingContextInspector inspector = new BrowsingContextInspector(driver)) { From 85f589e5cec8dfac7ea697acc82fb37a8db07699 Mon Sep 17 00:00:00 2001 From: Puja Jagani Date: Tue, 27 Aug 2024 16:31:09 +0530 Subject: [PATCH 10/55] [dotnet] Disable setting 'websocketurl' capability for Chrome tests --- dotnet/test/common/BUILD.bazel | 2 +- dotnet/test/common/Environment/DriverFactory.cs | 7 ++++++- .../bidi/browsingcontext/BrowsingContextInspectorTest.java | 1 - 3 files changed, 7 insertions(+), 3 deletions(-) diff --git a/dotnet/test/common/BUILD.bazel b/dotnet/test/common/BUILD.bazel index 4c152aadf03c42..231781fd6d5ecb 100644 --- a/dotnet/test/common/BUILD.bazel +++ b/dotnet/test/common/BUILD.bazel @@ -65,7 +65,7 @@ csharp_library( dotnet_nunit_test_suite( name = "AllTests", - size = "large", + size = "small", srcs = glob([ "**/*Test.cs", "**/*Tests.cs", diff --git a/dotnet/test/common/Environment/DriverFactory.cs b/dotnet/test/common/Environment/DriverFactory.cs index 448dfc61d1a98a..8ce615235dc7db 100644 --- a/dotnet/test/common/Environment/DriverFactory.cs +++ b/dotnet/test/common/Environment/DriverFactory.cs @@ -67,7 +67,12 @@ public IWebDriver CreateDriverWithOptions(Type driverType, DriverOptions driverO { browser = Browser.Chrome; options = GetDriverOptions(driverType, driverOptions); - options.UseWebSocketUrl = true; + // Disabling this since we do not have any BiDi tests currently. + //options.UseWebSocketUrl = true; + + // If BiDi is enabled above then the undhandler prompt behaviour needs to set accordingly. + // Reasoning : https://github.com/SeleniumHQ/selenium/pull/14429#issuecomment-2311614822 + //options.UnhandledPromptBehavior = UnhandledPromptBehavior.Ignore; var chromeOptions = (ChromeOptions)options; chromeOptions.AddArguments("--no-sandbox", "--disable-dev-shm-usage"); diff --git a/java/test/org/openqa/selenium/bidi/browsingcontext/BrowsingContextInspectorTest.java b/java/test/org/openqa/selenium/bidi/browsingcontext/BrowsingContextInspectorTest.java index 16256f9ad5a4d2..a92110c96eb151 100644 --- a/java/test/org/openqa/selenium/bidi/browsingcontext/BrowsingContextInspectorTest.java +++ b/java/test/org/openqa/selenium/bidi/browsingcontext/BrowsingContextInspectorTest.java @@ -34,7 +34,6 @@ import org.openqa.selenium.environment.webserver.AppServer; import org.openqa.selenium.environment.webserver.NettyAppServer; import org.openqa.selenium.testing.JupiterTestBase; -import org.openqa.selenium.testing.NotYetImplemented; class BrowsingContextInspectorTest extends JupiterTestBase { From cdc57b28e8759307476ab6ddd3492c50d7b75825 Mon Sep 17 00:00:00 2001 From: Dominic Evans <8060970+dnwe@users.noreply.github.com> Date: Wed, 28 Aug 2024 09:13:58 +0100 Subject: [PATCH 11/55] chore(ci): correct github-script API calls (#14442) * chore(ci): correct github-script API calls Since V5 of github-script the Octokit context available via `github` no longer has REST methods directly on it, they were moved to `github.rest.*` instead. Update the references in delete-comments.yml job to match. Signed-off-by: Dominic Evans * fix(ci): remove 'Download' from delete-comments This is too generic a word and frequently matches against comments that don't need to be deleted, nor should the user be blocked as the current workflow will do. Signed-off-by: Dominic Evans * fix(ci): correct block user task The existing code was calling the individual "block a user" REST endpoint with incorrect parameters and never would have worked. Update it to (presumably achieve the desired outcome) block the user from the owning organisation instead. Signed-off-by: Dominic Evans --------- Signed-off-by: Dominic Evans --- .github/workflows/delete-comments.yml | 15 +++++++-------- 1 file changed, 7 insertions(+), 8 deletions(-) diff --git a/.github/workflows/delete-comments.yml b/.github/workflows/delete-comments.yml index e5319d07256220..d766665ced333e 100644 --- a/.github/workflows/delete-comments.yml +++ b/.github/workflows/delete-comments.yml @@ -17,7 +17,7 @@ jobs: with: script: | const comment = context.payload.comment.body; - const triggerStrings = ['www.mediafire.com', 'Download']; + const triggerStrings = ['www.mediafire.com']; return triggerStrings.some(triggerString => comment.includes(triggerString)); - name: Delete comment if it contains any of the specific strings @@ -26,20 +26,19 @@ jobs: with: script: | const commentId = context.payload.comment.id; - await github.issues.deleteComment({ + await github.rest.issues.deleteComment({ owner: context.repo.owner, repo: context.repo.repo, comment_id: commentId }); - - name: Block user if comment contains any of the specific strings + - name: Block user from the org if their comment contained any of the banned strings if: steps.check_comment.outputs.result == 'true' uses: actions/github-script@v7 with: script: | - const userId = context.payload.comment.user.id; - await github.users.block({ - owner: context.repo.owner, - repo: context.repo.repo, - user_id: userId + const username = context.payload.comment.user.login + await github.rest.orgs.blockUser({ + org: context.repo.owner, + username: username }); From a056044d9c20c174e5c04804eb30a446132be60a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Boni=20Garc=C3=ADa?= Date: Wed, 28 Aug 2024 11:16:32 +0200 Subject: [PATCH 12/55] [rust] Include arguments for skipping drivers and browsers in path (#14444) * [rust] Include arguments for skipping drivers and browsers in path * [rust] Update skip logic with the current codebase --------- Co-authored-by: Diego Molina --- rust/src/config.rs | 4 +++ rust/src/lib.rs | 82 +++++++++++++++++++++++++++++++++------------- rust/src/main.rs | 10 ++++++ 3 files changed, 74 insertions(+), 22 deletions(-) diff --git a/rust/src/config.rs b/rust/src/config.rs index a3a2699bee6f14..1b940fcbfa7279 100644 --- a/rust/src/config.rs +++ b/rust/src/config.rs @@ -58,6 +58,8 @@ pub struct ManagerConfig { pub language_binding: String, pub selenium_version: String, pub avoid_stats: bool, + pub skip_driver_in_path: bool, + pub skip_browser_in_path: bool, } impl ManagerConfig { @@ -117,6 +119,8 @@ impl ManagerConfig { language_binding: StringKey(vec!["language-binding"], "").get_value(), selenium_version: StringKey(vec!["selenium-version"], "").get_value(), avoid_stats: BooleanKey("avoid-stats", false).get_value(), + skip_driver_in_path: BooleanKey("skip-driver-in-path", false).get_value(), + skip_browser_in_path: BooleanKey("skip-browser-in-path", false).get_value(), } } } diff --git a/rust/src/lib.rs b/rust/src/lib.rs index d7a0fc0878951f..ab5c01b10a21eb 100644 --- a/rust/src/lib.rs +++ b/rust/src/lib.rs @@ -386,7 +386,16 @@ pub trait SeleniumManager { // Check browser in PATH let browser_in_path = self.find_browser_in_path(); if let Some(path) = &browser_in_path { - self.set_browser_path(path_to_string(path)); + if self.is_skip_browser_in_path() { + self.get_logger().debug(format!( + "Skipping {} in path: {}", + self.get_browser_name(), + path.display() + )); + return None; + } else { + self.set_browser_path(path_to_string(path)); + } } browser_in_path } @@ -756,32 +765,41 @@ pub trait SeleniumManager { // Use driver in PATH when the user has not specified any browser version if use_driver_in_path { - let version = driver_in_path_version.unwrap(); let path = driver_in_path.unwrap(); - let major_version = self.get_major_version(&version)?; - // Display warning if the discovered driver version is not the same as the driver in PATH - if !self.get_driver_version().is_empty() - && (self.is_firefox() && !version.eq(self.get_driver_version())) - || (!self.is_firefox() && !major_version.eq(&self.get_major_browser_version())) - { - self.get_logger().warn(format!( - "The {} version ({}) detected in PATH at {} might not be compatible with \ - the detected {} version ({}); currently, {} {} is recommended for {} {}.*, \ - so it is advised to delete the driver in PATH and retry", - self.get_driver_name(), - &version, - path, - self.get_browser_name(), - self.get_browser_version(), + if self.is_skip_driver_in_path() { + self.get_logger().debug(format!( + "Skipping {} in path: {}", self.get_driver_name(), - self.get_driver_version(), - self.get_browser_name(), - self.get_major_browser_version() + path )); + } else { + let version = driver_in_path_version.unwrap(); + let major_version = self.get_major_version(&version)?; + + // Display warning if the discovered driver version is not the same as the driver in PATH + if !self.get_driver_version().is_empty() + && (self.is_firefox() && !version.eq(self.get_driver_version())) + || (!self.is_firefox() && !major_version.eq(&self.get_major_browser_version())) + { + self.get_logger().warn(format!( + "The {} version ({}) detected in PATH at {} might not be compatible with \ + the detected {} version ({}); currently, {} {} is recommended for {} {}.*, \ + so it is advised to delete the driver in PATH and retry", + self.get_driver_name(), + &version, + path, + self.get_browser_name(), + self.get_browser_version(), + self.get_driver_name(), + self.get_driver_version(), + self.get_browser_name(), + self.get_major_browser_version() + )); + } + self.set_driver_version(version.to_string()); + return Ok(PathBuf::from(path)); } - self.set_driver_version(version.to_string()); - return Ok(PathBuf::from(path)); } // If driver was not in the PATH, try to find it in the cache @@ -1413,6 +1431,26 @@ pub trait SeleniumManager { } } + fn is_skip_driver_in_path(&self) -> bool { + self.get_config().skip_driver_in_path + } + + fn set_skip_driver_in_path(&mut self, skip_driver_in_path: bool) { + if skip_driver_in_path { + self.get_config_mut().skip_driver_in_path = true; + } + } + + fn is_skip_browser_in_path(&self) -> bool { + self.get_config().skip_browser_in_path + } + + fn set_skip_browser_in_path(&mut self, skip_browser_in_path: bool) { + if skip_browser_in_path { + self.get_config_mut().skip_browser_in_path = true; + } + } + fn get_cache_path(&self) -> Result, Error> { let path = Path::new(&self.get_config().cache_path); match create_path_if_not_exists(path) { diff --git a/rust/src/main.rs b/rust/src/main.rs index 5b42caa1e77df3..3e53a7a8da012a 100644 --- a/rust/src/main.rs +++ b/rust/src/main.rs @@ -147,6 +147,14 @@ struct Cli { /// Avoid sends usage statistics to plausible.io #[clap(long)] avoid_stats: bool, + + /// Not using drivers found in the PATH + #[clap(long)] + skip_driver_in_path: bool, + + /// Not using browsers found in the PATH + #[clap(long)] + skip_browser_in_path: bool, } fn main() { @@ -218,6 +226,8 @@ fn main() { let selenium_version = sm_version.strip_prefix(SM_BETA_LABEL).unwrap_or(sm_version); selenium_manager.set_selenium_version(selenium_version.to_string()); selenium_manager.set_avoid_stats(cli.avoid_stats); + selenium_manager.set_skip_driver_in_path(cli.skip_driver_in_path); + selenium_manager.set_skip_browser_in_path(cli.skip_browser_in_path); if cli.clear_cache || BooleanKey("clear-cache", false).get_value() { clear_cache(selenium_manager.get_logger(), &cache_path); From 748ffc9bc3cf40211b27d1b27e238b26aae93f46 Mon Sep 17 00:00:00 2001 From: Diego Molina Date: Wed, 28 Aug 2024 12:24:37 +0200 Subject: [PATCH 13/55] Release 4.24.0 (#14429) * update Rust version to 0.4.24 * Rust Changelog * Update pinned browser versions * Update supported versions for Chrome DevTools * Update selenium manager version * Update authors file * FIX CHANGELOGS BEFORE MERGING! Update versions and change logs to release Selenium 4.24.0 * [java] Bumping Java deps * Fix changelogs * Running format script * Updating pinned browsers * Updating pinned browsers * Enabling tests in .NET * Setting flag to disable search engine choice * Updating gem checksums * Running format script * Running format script --------- Co-authored-by: Selenium CI Bot Co-authored-by: Puja Jagani --- AUTHORS | 26 +- MODULE.bazel | 124 +++--- Rakefile | 2 +- .../chromium/{v125 => v128}/BUILD.bazel | 0 .../{v125 => v128}/browser_protocol.pdl | 372 ++++++++++++++++-- .../chromium/{v125 => v128}/js_protocol.pdl | 0 common/repositories.bzl | 58 +-- common/selenium_manager.bzl | 12 +- dotnet/CHANGELOG | 7 +- dotnet/selenium-dotnet-version.bzl | 4 +- .../src/webdriver/DevTools/DevToolsDomains.cs | 2 +- .../V125Domains.cs => v128/V128Domains.cs} | 22 +- .../V128JavaScript.cs} | 16 +- .../{v125/V125Log.cs => v128/V128Log.cs} | 14 +- .../V125Network.cs => v128/V128Network.cs} | 24 +- .../V125Target.cs => v128/V128Target.cs} | 14 +- dotnet/src/webdriver/WebDriver.csproj | 2 +- .../StableChannelChromeDriver.cs | 2 +- .../common/DevTools/DevToolsConsoleTest.cs | 3 +- .../test/common/DevTools/DevToolsLogTest.cs | 2 +- .../common/DevTools/DevToolsNetworkTest.cs | 3 +- .../DevTools/DevToolsPerformanceTest.cs | 3 +- .../common/DevTools/DevToolsProfilerTest.cs | 3 +- .../common/DevTools/DevToolsSecurityTest.cs | 3 +- .../test/common/DevTools/DevToolsTabsTest.cs | 3 +- .../common/DevTools/DevToolsTargetTest.cs | 5 +- java/CHANGELOG | 16 + java/maven_install.json | 303 +++++++------- .../devtools/{v125 => v128}/BUILD.bazel | 2 +- .../v128CdpInfo.java} | 8 +- .../v128Domains.java} | 26 +- .../v125Events.java => v128/v128Events.java} | 18 +- .../v128Javascript.java} | 14 +- .../{v125/v125Log.java => v128/v128Log.java} | 10 +- .../v128Network.java} | 20 +- .../v125Target.java => v128/v128Target.java} | 24 +- .../org/openqa/selenium/devtools/versions.bzl | 2 +- .../remote/http/jdk/JdkHttpClient.java | 2 +- .../selenium/testing/drivers/Browser.java | 6 +- java/version.bzl | 2 +- .../node/selenium-webdriver/BUILD.bazel | 4 +- javascript/node/selenium-webdriver/CHANGES.md | 12 + .../node/selenium-webdriver/package.json | 2 +- package-lock.json | 2 +- py/BUILD.bazel | 4 +- py/CHANGES | 7 + py/docs/source/conf.py | 2 +- py/selenium/webdriver/__init__.py | 2 +- py/setup.py | 2 +- rb/CHANGES | 7 + rb/Gemfile.lock | 35 +- rb/lib/selenium/devtools/BUILD.bazel | 2 +- rb/lib/selenium/devtools/version.rb | 2 +- rb/lib/selenium/webdriver/version.rb | 2 +- rust/BUILD.bazel | 2 +- rust/CHANGELOG.md | 6 + rust/Cargo.Bazel.lock | 10 +- rust/Cargo.lock | 2 +- rust/Cargo.toml | 2 +- 59 files changed, 813 insertions(+), 473 deletions(-) rename common/devtools/chromium/{v125 => v128}/BUILD.bazel (100%) rename common/devtools/chromium/{v125 => v128}/browser_protocol.pdl (96%) rename common/devtools/chromium/{v125 => v128}/js_protocol.pdl (100%) rename dotnet/src/webdriver/DevTools/{v125/V125Domains.cs => v128/V128Domains.cs} (78%) rename dotnet/src/webdriver/DevTools/{v125/V125JavaScript.cs => v128/V128JavaScript.cs} (94%) rename dotnet/src/webdriver/DevTools/{v125/V125Log.cs => v128/V128Log.cs} (88%) rename dotnet/src/webdriver/DevTools/{v125/V125Network.cs => v128/V128Network.cs} (95%) rename dotnet/src/webdriver/DevTools/{v125/V125Target.cs => v128/V128Target.cs} (94%) rename java/src/org/openqa/selenium/devtools/{v125 => v128}/BUILD.bazel (98%) rename java/src/org/openqa/selenium/devtools/{v125/v125CdpInfo.java => v128/v128CdpInfo.java} (86%) rename java/src/org/openqa/selenium/devtools/{v125/v125Domains.java => v128/v128Domains.java} (77%) rename java/src/org/openqa/selenium/devtools/{v125/v125Events.java => v128/v128Events.java} (86%) rename java/src/org/openqa/selenium/devtools/{v125/v125Javascript.java => v128/v128Javascript.java} (85%) rename java/src/org/openqa/selenium/devtools/{v125/v125Log.java => v128/v128Log.java} (89%) rename java/src/org/openqa/selenium/devtools/{v125/v125Network.java => v128/v128Network.java} (92%) rename java/src/org/openqa/selenium/devtools/{v125/v125Target.java => v128/v128Target.java} (83%) diff --git a/AUTHORS b/AUTHORS index 11a8283f1f12cb..de3df458c77395 100644 --- a/AUTHORS +++ b/AUTHORS @@ -23,6 +23,7 @@ Ahmed Ashour AJ Ajay Kemparaj Akhil Lb +Ákos Lukács Akuli Al Sutton Alan Baird @@ -71,6 +72,7 @@ Andrei Solntsev Andrey Botalov Andrii Rohovets Andy Duncan +Angie Jones anonymous_sdet Anthony Sottile Anton Usmansky @@ -135,6 +137,7 @@ Carlos Ortega Carlos Villela Carson McDonald ce86f3bb9faf71e <118820152+ce86f3bb9faf71e@users.noreply.github.com> +Cédric Boutillier Cervac Petru cezarelnazli ch-saeki <31008335+ch-saeki@users.noreply.github.com> @@ -146,6 +149,7 @@ Chirag Jayswal chris Chris Block Chris Gamache +Chris Gossett <54162250+cgossett@users.noreply.github.com> Chris Martin Chris Mohr Chris Stringer @@ -170,7 +174,6 @@ Coty Rosenblath Craig Nishina CsolG customcommander -Cédric Boutillier Dakkaron Damien Allison Damir @@ -222,6 +225,7 @@ Diego Fernández Santos Diego Molina Dima Kovalenko Dima Veselov +Diogo Teles Sant'Anna Dmitriy Sintsov Dmitry Dubenets Dmitry Tokarev @@ -263,6 +267,7 @@ Eric Plaster Erik Beans Erik E. Beerepoot Erik Kuefler +Étienne Barrié Evan Sangaline Evgeniy Roldukhin EwaMarek @@ -274,10 +279,10 @@ Florian LOPES Florian Mutter <32459530+florianmutter@users.noreply.github.com> Florian Zipperle Francis Bergin -Franz Liedke François Freitag François JACQUES François Reynaud +Franz Liedke Frederik Carlier Fredrik Wollsén freynaud @@ -420,6 +425,7 @@ Jim van Musscher jkbzh <3439365+jkbzh@users.noreply.github.com> jkohls jmuramatsu +João Luca Ripardo Joaquín Romero jochenberger Joe Bandenburg @@ -451,12 +457,12 @@ Jonathan Lipps Jonathon Kereliuk Jongkuen Hong Jordan Mace +Jörg Sautter josephg Josh Goldberg Joshua Bruning Joshua Fehler Joshua Grant -João Luca Ripardo JT Archie jugglinmike Julian Didier @@ -471,7 +477,6 @@ Justin Tulloss Justine Tunney justinwoolley@gmail.com jwoolley <19597672+jwoolley@users.noreply.github.com> -Jörg Sautter Kamen Litchev Karl Kuehn Karl-Philipp Richter @@ -525,10 +530,10 @@ Lucas Diniz Lucas Tierney Luis Correia Luis Pflamminger +Lukáš Linhart Luke Hill Luke Inman-Semerau lukec -Lukáš Linhart Lyudmil Latinov Machinexa2 <60662297+machinexa2@users.noreply.github.com> Maciej Pakulski @@ -607,6 +612,7 @@ ming Mirko Nasato mitchloudenbeck Miten Chauhan +mk868 mkvetko MMK-IBSEN <124664589+MMK-IBSEN@users.noreply.github.com> Mohab Mohie @@ -621,6 +627,7 @@ mpurland mtrea <32470080+mtrea@users.noreply.github.com> Mubariz Hajimuradov Muhammad Hammad <33136628+mhnaeem@users.noreply.github.com> +MustafaAgamy Muthu Kannan MWschutte <72599545+MWschutte@users.noreply.github.com> myslak71 @@ -629,6 +636,7 @@ Nathan Isom native-api Naveen <172697+naveensrinivasan@users.noreply.github.com> Naveen Singh <36371707+Naveen3Singh@users.noreply.github.com> +Navin Chandra <98466550+navin772@users.noreply.github.com> Neil Carvalho Nelson Sproul Nick Crews @@ -671,6 +679,7 @@ Patrick Lightbody Paul G Webster Paul Hammant Pavel Lobashov +Pavel Sobolev Perryn Fowler Pete Johns Peter Hedenskog @@ -774,6 +783,7 @@ Shishu Raj Pandey Shreyan Avigyan <74560907+shreyanavigyan@users.noreply.github.com> Shubham Singh <41840111+singh811@users.noreply.github.com> Shuhai Shen +Simon Benzer <69980130+shbenzer@users.noreply.github.com> Simon K Simon Perepelitsa Simon Stewart @@ -805,9 +815,9 @@ take0x <89313929+take0x@users.noreply.github.com> Takeshi Kishi Takuho NAKANO Takuma Chiba +Tamás Buka Tamas Utasi <3823780+utamas@users.noreply.github.com> Tamsil Sajid Amani -Tamás Buka Tatsuya Hoshino Terence Haddock thecr8tr @@ -850,6 +860,7 @@ Ulf Adams Ulrich Buchgraber User253489 V24 <55334829+umarfarouk98@users.noreply.github.com> +Václav Votípka Valery Yatsynovich Varun Menon varunsurapaneni <67070327+varunsurapaneni@users.noreply.github.com> @@ -874,7 +885,6 @@ Vladimir Támara Patiño VladimirPodolyan <36446855+VladimirPodolyan@users.noreply.github.com> Vladislav Velichko <111522705+vlad8x8@users.noreply.github.com> Vyvyan Codd -Václav Votípka Werner Robitza wiggin15 wildloop @@ -896,6 +906,4 @@ Zhuo Peng Ziyu Zoltar - Knower of All zsong -Ákos Lukács -Étienne Barrié 保木本将之 diff --git a/MODULE.bazel b/MODULE.bazel index 53241498eb988e..7ee21c50a99dbe 100644 --- a/MODULE.bazel +++ b/MODULE.bazel @@ -173,37 +173,37 @@ maven.install( "com.github.spotbugs:spotbugs:4.8.6", "com.github.stephenc.jcip:jcip-annotations:1.0-1", "com.google.code.gson:gson:2.11.0", - "com.google.guava:guava:33.2.1-jre", + "com.google.guava:guava:33.3.0-jre", "com.google.auto:auto-common:1.2.2", "com.google.auto.service:auto-service:1.1.1", "com.google.auto.service:auto-service-annotations:1.1.1", - "com.google.googlejavaformat:google-java-format:jar:1.22.0", + "com.google.googlejavaformat:google-java-format:jar:1.23.0", "com.graphql-java:graphql-java:20.2", "com.graphql-java:java-dataloader:3.2.0", "dev.failsafe:failsafe:3.3.2", - "io.grpc:grpc-context:1.65.1", - "io.lettuce:lettuce-core:6.3.2.RELEASE", - "io.netty:netty-buffer:4.1.111.Final", - "io.netty:netty-codec-http:4.1.111.Final", - "io.netty:netty-codec-http2:4.1.111.Final", - "io.netty:netty-common:4.1.111.Final", - "io.netty:netty-handler:4.1.111.Final", - "io.netty:netty-handler-proxy:4.1.111.Final", - "io.netty:netty-transport:4.1.111.Final", - "io.opentelemetry:opentelemetry-api:1.40.0", - "io.opentelemetry:opentelemetry-context:1.40.0", - "io.opentelemetry:opentelemetry-exporter-logging:1.40.0", - "io.opentelemetry:opentelemetry-sdk:1.40.0", - "io.opentelemetry:opentelemetry-sdk-common:1.40.0", - "io.opentelemetry:opentelemetry-sdk-extension-autoconfigure:1.40.0", - "io.opentelemetry:opentelemetry-sdk-extension-autoconfigure-spi:1.40.0", - "io.opentelemetry:opentelemetry-sdk-testing:1.40.0", - "io.opentelemetry:opentelemetry-sdk-trace:1.40.0", + "io.grpc:grpc-context:1.66.0", + "io.lettuce:lettuce-core:6.4.0.RELEASE", + "io.netty:netty-buffer:4.1.112.Final", + "io.netty:netty-codec-http:4.1.112.Final", + "io.netty:netty-codec-http2:4.1.112.Final", + "io.netty:netty-common:4.1.112.Final", + "io.netty:netty-handler:4.1.112.Final", + "io.netty:netty-handler-proxy:4.1.112.Final", + "io.netty:netty-transport:4.1.112.Final", + "io.opentelemetry:opentelemetry-api:1.41.0", + "io.opentelemetry:opentelemetry-context:1.41.0", + "io.opentelemetry:opentelemetry-exporter-logging:1.41.0", + "io.opentelemetry:opentelemetry-sdk:1.41.0", + "io.opentelemetry:opentelemetry-sdk-common:1.41.0", + "io.opentelemetry:opentelemetry-sdk-extension-autoconfigure:1.41.0", + "io.opentelemetry:opentelemetry-sdk-extension-autoconfigure-spi:1.41.0", + "io.opentelemetry:opentelemetry-sdk-testing:1.41.0", + "io.opentelemetry:opentelemetry-sdk-trace:1.41.0", "io.opentelemetry.semconv:opentelemetry-semconv:1.25.0-alpha", "io.ous:jtoml:2.0.0", "it.ozimov:embedded-redis:0.7.3", - "net.bytebuddy:byte-buddy:1.14.18", - "org.htmlunit:htmlunit-core-js:4.3.0", + "net.bytebuddy:byte-buddy:1.15.0", + "org.htmlunit:htmlunit-core-js:4.4.0", "org.apache.commons:commons-exec:1.4.0", "org.apache.logging.log4j:log4j-core:2.23.1", "org.assertj:assertj-core:3.26.3", @@ -211,17 +211,17 @@ maven.install( "org.eclipse.mylyn.github:org.eclipse.egit.github.core:2.1.5", "org.hsqldb:hsqldb:2.7.3", "org.jspecify:jspecify:1.0.0", - "org.junit.jupiter:junit-jupiter-api:5.10.3", - "org.junit.jupiter:junit-jupiter-engine:5.10.3", - "org.junit.jupiter:junit-jupiter-params:5.10.3", - "org.junit.platform:junit-platform-launcher:1.10.3", - "org.junit.platform:junit-platform-reporting:1.10.3", - "org.junit.platform:junit-platform-commons:1.10.3", - "org.junit.platform:junit-platform-engine:1.10.3", + "org.junit.jupiter:junit-jupiter-api:5.11.0", + "org.junit.jupiter:junit-jupiter-engine:5.11.0", + "org.junit.jupiter:junit-jupiter-params:5.11.0", + "org.junit.platform:junit-platform-launcher:1.11.0", + "org.junit.platform:junit-platform-reporting:1.11.0", + "org.junit.platform:junit-platform-commons:1.11.0", + "org.junit.platform:junit-platform-engine:1.11.0", "org.mockito:mockito-core:5.12.0", - "org.redisson:redisson:3.33.0", - "org.slf4j:slf4j-api:2.0.13", - "org.slf4j:slf4j-jdk14:2.0.13", + "org.redisson:redisson:3.35.0", + "org.slf4j:slf4j-api:2.0.16", + "org.slf4j:slf4j-jdk14:2.0.16", "org.zeromq:jeromq:0.6.0", ], excluded_artifacts = [ @@ -258,19 +258,13 @@ ruby.bundle_fetch( "//:rb/selenium-webdriver.gemspec", ], gem_checksums = { - "abbrev-0.1.2": "ad1b4eaaaed4cb722d5684d63949e4bde1d34f2a95e20db93aecfe7cbac74242", - "activesupport-7.1.3.2": "ad8445b7ae4a6d3acc5f88c8c5f437eb0b54062032aaf44856c7b6d3855b8b2e", - "addressable-2.8.6": "798f6af3556641a7619bad1dce04cdb6eb44b0216a991b0396ea7339276f2b47", - "activesupport-7.1.3.4": "455bbc43d82e5ba20daa25f0888b80c9f7e2d80ca0cc96cea3e6acfec3e40309", + "activesupport-7.2.1": "7557fa077a592a4f36f7ddacf4d9d71c34aff69ed20236b8a61c22d567da8c24", "addressable-2.8.7": "462986537cf3735ab5f3c0f557f14155d778f4b43ea4f485a9deb9c8f7c58232", "ast-2.4.2": "1e280232e6a33754cde542bc5ef85520b74db2aac73ec14acef453784447cc12", "base64-0.2.0": "0f25e9b21a02a0cc0cea8ef92b2041035d39350946e8789c562b2d1a3da01507", - "bigdecimal-3.1.7": "e799b369a0005fc6d62eed7ef19139ac9bc319cc51470c637b9dcdf593600133", - "bigdecimal-3.1.7-java": "955f5c7aa90136874b494655e42ed70d81382abb0f49f1b42f374a1660e33c63", - "concurrent-ruby-1.2.3": "82fdd3f8a0816e28d513e637bb2b90a45d7b982bdf4f3a0511722d2e495801e2", "bigdecimal-3.1.8": "a89467ed5a44f8ae01824af49cbc575871fa078332e8f77ea425725c1ffe27be", "bigdecimal-3.1.8-java": "b9e94c14623fff8575f17a10320852219bbba92ecff4977571503d942687326e", - "concurrent-ruby-1.3.3": "4f9cd28965c4dcf83ffd3ea7304f9323277be8525819cb18a3b61edcb56a7c6a", + "concurrent-ruby-1.3.4": "d4aa926339b0a86b5b5054a0a8c580163e6f5dcbdfd0f4bb916b1a2570731c32", "connection_pool-2.4.1": "0f40cf997091f1f04ff66da67eabd61a9fe0d4928b9a3645228532512fab62f4", "crack-1.0.0": "c83aefdb428cdc7b66c7f287e488c796f055c0839e6e545fec2c7047743c4a49", "csv-3.3.0": "0bbd1defdc31134abefed027a639b3723c2753862150f4c3ee61cab71b20d67d", @@ -278,20 +272,15 @@ ruby.bundle_fetch( "debug-1.9.2": "48e026c0852c7a10c60263e2e527968308958e266231e36d64e3efcabec7e7fc", "diff-lcs-1.5.1": "273223dfb40685548436d32b4733aa67351769c7dea621da7d9dd4813e63ddfe", "drb-2.2.1": "e9d472bf785f558b96b25358bae115646da0dbfd45107ad858b0bc0d935cb340", - "ffi-1.16.3": "6d3242ff10c87271b0675c58d68d3f10148fabc2ad6da52a18123f06078871fb", - "ffi-1.16.3-java": "6f107fcd7c96f9c96f7e57db749b99502cc2f65665f7b2241d087a8f8c01d42c", - "ffi-1.16.3-x64-mingw32": "6ec709011e3955e97033fa77907a8ab89a9150137d4c45c82c77399b909c9259", "ffi-1.17.0": "51630e43425078311c056ca75f961bb3bda1641ab36e44ad4c455e0b0e4a231c", "ffi-1.17.0-java": "f65f022616970fcde83fe176393eb873a7b959ef2703f94931cf0af6ab55ec7a", "ffi-1.17.0-x86_64-darwin": "fdcd48c69db3303ef95aec5c64d6275fcf9878a02c0bec0afddc506ceca0f56b", "fileutils-1.7.2": "36a0fb324218263e52b486ad7408e9a295378fe8edc9fd343709e523c0980631", "git-1.19.1": "b0a422d9f6517353c48a330d6114de4db9e0c82dbe7202964a1d9f1fbc827d70", - "hashdiff-1.1.0": "b5465f0e7375f1ee883f53a766ece4dbc764b7674a7c5ffd76e79b2f5f6fc9c9", - "i18n-1.14.4": "c7deedead0866ea9102975a4eab7968f53de50793a0c211a37808f75dd187551", + "hashdiff-1.1.1": "c7966316726e0ceefe9f5c6aef107ebc3ccfef8b6db55fe3934f046b2cf0936a", "i18n-1.14.5": "26dcbc05e364b57e27ab430148b3377bc413987d34cc042336271d8f42e9d1b9", "io-console-0.7.2": "f0dccff252f877a4f60d04a4dc6b442b185ebffb4b320ab69212a92b48a7a221", "io-console-0.7.2-java": "73aa382f8832b116613ceaf57b8ff5bf73dfedcaf39f0aa5420e10f63a4543ed", - "irb-1.12.0": "07634937fbb7d28d07e46da50d0aa43b4d2f7258174d08de4e32dfb57c10539d", "irb-1.14.0": "53d805013bbd194874b8c13a56aca6aebcd11dd79166d88724f8a434fedde615", "jar-dependencies-0.4.1": "b2df2f1ecbff15334ce20ea7fdd5b8d8161faab67761ff72c7647d728e40d387", "json-2.7.2": "1898b5cbc81cd36c0fd4d0b7ad2682c39fb07c5ff682fc6265f678f550d4982c", @@ -299,18 +288,11 @@ ruby.bundle_fetch( "language_server-protocol-3.17.0.3": "3d5c58c02f44a20d972957a9febe386d7e7468ab3900ce6bd2b563dd910c6b3f", "listen-3.9.0": "db9e4424e0e5834480385197c139cb6b0ae0ef28cc13310cfd1ca78377d59c67", "logger-1.6.0": "0ab7c120262dd8de2a18cb8d377f1f318cbe98535160a508af9e7710ff43ef3e", - "minitest-5.22.3": "ea84676290cb5e2b4f31f25751af6050aa90d3e43e4337141c3e3e839611981e", - "minitest-5.24.1": "31ec31ac9088d9e21fcc5a5487912234de83966f24368241b2bef03d7012464a", - "mutex_m-0.2.0": "b6ef0c6c842ede846f2ec0ade9e266b1a9dac0bc151682b04835e8ebd54840d5", - "parallel-1.24.0": "5bf38efb9b37865f8e93d7a762727f8c5fc5deb19949f4040c76481d5eee9397", - "parser-3.3.0.5": "7748313e505ca87045dc0465c776c802043f777581796eb79b1654c5d19d2687", - "parallel-1.25.1": "12e089b9aa36ea2343f6e93f18cfcebd031798253db8260590d26a7f70b1ab90", - "parser-3.3.4.0": "8d247769c3873fe92201d591a7463384022a1a25e214853df5d6806623179e82", + "minitest-5.25.1": "3db6795a80634def1cf86fda79d2d83b59b25ce5e186fa675f73c565589d2ad8", + "parallel-1.26.3": "d86babb7a2b814be9f4b81587bf0b6ce2da7d45969fab24d8ae4bf2bb4d4c7ef", + "parser-3.3.4.2": "71efa8690c2a1ff8937258ff5713add4894dcea8b4ba19055692e28a2469c9e6", "psych-5.1.2": "337322f58fc2bf24827d2b9bd5ab595f6a72971867d151bb39980060ea40a368", "psych-5.1.2-java": "1dd68dc609eddbc884e6892e11da942e16f7256bd30ebde9d35449d43043a6fe", - "public_suffix-5.0.5": "72c340218bb384610536919988705cc29e09749c0021fd7005f715c7e5dfc493", - "racc-1.7.3": "b785ab8a30ec43bce073c51dbbe791fd27000f68d1c996c95da98bf685316905", - "racc-1.7.3-java": "b2ad737e788cfa083263ce7c9290644bb0f2c691908249eb4f6eb48ed2815dbf", "public_suffix-6.0.1": "61d44e1cab5cbbbe5b31068481cf16976dd0dc1b6b07bd95617ef8c5e3e00c6f", "racc-1.8.1": "4a7f6929691dbec8b5209a0b373bc2614882b55fc5d2e447a21aaa691303d62f", "racc-1.8.1-java": "54f2e6d1e1b91c154013277d986f52a90e5ececbe91465d29172e49342732b98", @@ -318,35 +300,20 @@ ruby.bundle_fetch( "rainbow-3.1.1": "039491aa3a89f42efa1d6dec2fc4e62ede96eb6acd95e52f1ad581182b79bc6a", "rake-13.2.1": "46cb38dae65d7d74b6020a4ac9d48afed8eb8149c040eccf0523bec91907059d", "rb-fsevent-0.11.2": "43900b972e7301d6570f64b850a5aa67833ee7d87b458ee92805d56b7318aefe", - "rb-inotify-0.10.1": "050062d4f31d307cca52c3f6a7f4b946df8de25fc4bd373e1a5142e41034a7ca", - "rbs-3.4.4": "1376d2604a00832641bb47521595e63a1c0d1cc241ded383ba48ddb4396de5a8", "rb-inotify-0.11.1": "a0a700441239b0ff18eb65e3866236cd78613d6b9f78fea1f9ac47a85e47be6e", - "rbs-3.5.2": "ac4a0ff5de832402fc30324028e00c3e8914af3de0abcba7a5cf21d38602f3bb", + "rbs-3.5.3": "f262eea0db1e40eaa154266096b1a4272bc965a81d78acb0e54b58b4dc11f052", "rchardet-1.8.0": "693acd5253d5ade81a51940697955f6dd4bb2f0d245bda76a8e23deec70a52c7", - "rdoc-6.6.3.1": "39f7b749229ab5ad9d21c81586151c1dd7a549fa8be4070ee09b524f9c656345", - "regexp_parser-2.9.0": "81a00ba141cec0d4b4bf58cb80cd9193e5180836d3fa6ef623f7886d3ba8bdd9", - "reline-0.5.3": "2c46747a1dfd03e100f0666d8a374cf2930c3e734298af9b39e5fe8d35b42035", - "rexml-3.2.6": "e0669a2d4e9f109951cb1fde723d8acd285425d81594a2ea929304af50282816", "rdoc-6.7.0": "b17d5f0f57b0853d7b880d4360a32c7caf8dbb81f8503a36426df809e617f379", "regexp_parser-2.9.2": "5a27e767ad634f8a4b544520d5cd28a0db7aa1198a5d7c9d7e11d7b3d9066446", "reline-0.5.9": "5d2dd7ed0fd078e79a05e4eaa47dc91b8dacec7358e9e1dd6d9c4636cff7d378", - "rexml-3.3.2": "4513686f858d0ff2e5a412d734c8a192e16cb1df4cb2063f56b72a8ad4c5257f", + "rexml-3.3.6": "7af0459d108dfd6ffa7d38c67c8464e200f5c9d476d4c6a3d1899e92808d63c6", "rspec-3.13.0": "d490914ac1d5a5a64a0e1400c1d54ddd2a501324d703b8cfe83f458337bab993", "rspec-core-3.13.0": "557792b4e88da883d580342b263d9652b6a10a12d5bda9ef967b01a48f15454c", - "rspec-expectations-3.13.0": "621d48c62262f955421eaa418130744760802cad47e781df70dba4d9f897102e", - "rspec-mocks-3.13.0": "735a891215758d77cdb5f4721fffc21078793959d1f0ee4a961874311d9b7f66", - "rspec-expectations-3.13.1": "814cf8dadc797b00be55a84d7bc390c082735e5c914e62cbe8d0e19774b74200", + "rspec-expectations-3.13.2": "565fb94ab39923c0fe6a16cfc9570d1821b741917a50800373fcbbb752c7a45a", "rspec-mocks-3.13.1": "087189899c337937bcf1d66a50dc3fc999ac88335bbeba4d385c2a38c87d7b38", "rspec-support-3.13.1": "48877d4f15b772b7538f3693c22225f2eda490ba65a0515c4e7cf6f2f17de70f", - "rubocop-1.63.3": "17a31f16658f2fbb20bc7bcb4a841a06f7368da4f3be8a50365ad61e658d5f44", - "rubocop-ast-1.31.2": "7c206fb094553779923eca862aceece3913ce384f1bf85730208228e884578ec", - "rubocop-capybara-2.20.0": "2a6844b942921f230ee3ab8c94fe77f41a9406096a140245270c0e11624bb938", - "rubocop-factory_bot-2.25.1": "62751bde7af789878b8a31cbd2a82e69515ce7b23a2ad1820cb0fcc3e0150134", - "rubocop-performance-1.21.0": "ec54fa8991c2d538af7bc958361d63bdb3df2e53032da393e9903ea5e4f74a9a", - "rubocop-rspec-2.29.1": "534ee81a3006e7379ec6203687ef7c06ca1d137b7d6d67c2777b680b1ce82e13", - "rubocop-rspec_rails-2.28.3": "9769f2077cca8af2269193ba0450e0317ae1827a132c19149fdbeecaaca32818", - "rubocop-1.65.0": "624316407a3f8e3999c6f75c528471ed3d4513ca39cec3bede1964c69630e4a1", - "rubocop-ast-1.31.3": "1b07d618d8776993ec6053a706d1c09f0bf15139fd69415924656cbff07e7818", + "rubocop-1.65.1": "3a239b71fcfdeb32c654f4b48c2e6aeb4f77b128e348fa9442184f207e70718d", + "rubocop-ast-1.32.1": "6a86ce3b7aa8ff8b600396d8f75ef5f85873b94bf0a1ae11607c19e65ced79c1", "rubocop-capybara-2.21.0": "5d264efdd8b6c7081a3d4889decf1451a1cfaaec204d81534e236bc825b280ab", "rubocop-factory_bot-2.26.1": "8de13cd4edcee5ca800f255188167ecef8dbfc3d1fae9f15734e9d2e755392aa", "rubocop-performance-1.21.1": "5cf20002a544275ad6aa99abca4b945d2a2ed71be925c38fe83700360ed8734e", @@ -357,19 +324,16 @@ ruby.bundle_fetch( "rubyzip-2.3.2": "3f57e3935dc2255c414484fbf8d673b4909d8a6a57007ed754dde39342d2373f", "securerandom-0.3.1": "98f0450c0ea46d2f9a4b6db4f391dbd83dc08049592eada155739f40e0341bde", "steep-1.5.3": "7c6302a4d5932d0a46176ebc79766e52b853c223a85525aa2f8911e345123b85", - "stringio-3.1.0": "c1f6263ae03a15025e51194ab19b06b15e06adcaaedb7f5f6c06ab60f5d67718", "stringio-3.1.1": "53456e14175c594e0e8eb2206a1be33f3974d4fe21c131e628908b05c8c2ae1e", "strscan-3.1.0": "01b8a81d214fbf7b5308c6fb51b5972bbfc4a6aa1f166fd3618ba97e0fcd5555", "strscan-3.1.0-java": "8645aa76e017e21764c6df572d2d79fcc1672284014f5bdbd806278cdbcd11b0", "terminal-table-3.0.2": "f951b6af5f3e00203fb290a669e0a85c5dd5b051b3b023392ccfd67ba5abae91", "tzinfo-2.0.6": "8daf828cc77bcf7d63b0e3bdb6caa47e2272dcfaf4fbfe46f8c3a9df087a829b", "unicode-display_width-2.5.0": "7e7681dcade1add70cb9fda20dd77f300b8587c81ebbd165d14fd93144ff0ab4", - "webmock-3.23.0": "100787435c1f556129a238c11cc7cbee38cb9c2864709c6a0dcdcf822545f31f", "webmock-3.23.1": "0fa738c0767d1c4ec8cc57f6b21998f0c238c8a5b32450df1c847f2767140d95", "webrick-1.8.1": "19411ec6912911fd3df13559110127ea2badd0c035f7762873f58afc803e158f", - "websocket-1.2.10": "2cc1a4a79b6e63637b326b4273e46adcddf7871caa5dc5711f2ca4061a629fa8", - "yard-0.9.36": "5505736c1b00c926f71053a606ab75f02070c5960d0778b901fe9d8b0a470be4", "websocket-1.2.11": "b7e7a74e2410b5e85c25858b26b3322f29161e300935f70a0e0d3c35e0462737", + "yard-0.9.36": "5505736c1b00c926f71053a606ab75f02070c5960d0778b901fe9d8b0a470be4", }, gemfile = "//:rb/Gemfile", gemfile_lock = "//:rb/Gemfile.lock", diff --git a/Rakefile b/Rakefile index 408c766a1f4feb..a1b77c50b28b30 100644 --- a/Rakefile +++ b/Rakefile @@ -97,7 +97,7 @@ task '//java/test/org/openqa/selenium/environment/webserver:webserver:uber' => [ JAVA_RELEASE_TARGETS = %w[ //java/src/org/openqa/selenium/chrome:chrome.publish //java/src/org/openqa/selenium/chromium:chromium.publish - //java/src/org/openqa/selenium/devtools/v125:v125.publish + //java/src/org/openqa/selenium/devtools/v128:v128.publish //java/src/org/openqa/selenium/devtools/v126:v126.publish //java/src/org/openqa/selenium/devtools/v127:v127.publish //java/src/org/openqa/selenium/devtools/v85:v85.publish diff --git a/common/devtools/chromium/v125/BUILD.bazel b/common/devtools/chromium/v128/BUILD.bazel similarity index 100% rename from common/devtools/chromium/v125/BUILD.bazel rename to common/devtools/chromium/v128/BUILD.bazel diff --git a/common/devtools/chromium/v125/browser_protocol.pdl b/common/devtools/chromium/v128/browser_protocol.pdl similarity index 96% rename from common/devtools/chromium/v125/browser_protocol.pdl rename to common/devtools/chromium/v128/browser_protocol.pdl index 162eeacc25478d..ce45403da9045d 100644 --- a/common/devtools/chromium/v125/browser_protocol.pdl +++ b/common/devtools/chromium/v128/browser_protocol.pdl @@ -156,6 +156,7 @@ experimental domain Accessibility flowto labelledby owns + url # A node in the accessibility tree. type AXNode extends object @@ -622,6 +623,8 @@ experimental domain Audits CoopSandboxedIFrameCannotNavigateToCoopPage CorpNotSameOrigin CorpNotSameOriginAfterDefaultedToSameOriginByCoep + CorpNotSameOriginAfterDefaultedToSameOriginByDip + CorpNotSameOriginAfterDefaultedToSameOriginByCoepAndDip CorpNotSameSite # Details for a request that has been blocked with the BLOCKED_BY_RESPONSE @@ -741,6 +744,32 @@ experimental domain Audits NoRegisterOsSourceHeader NoRegisterOsTriggerHeader + type SharedDictionaryError extends string + enum + UseErrorCrossOriginNoCorsRequest + UseErrorDictionaryLoadFailure + UseErrorMatchingDictionaryNotUsed + UseErrorUnexpectedContentDictionaryHeader + WriteErrorCossOriginNoCorsRequest + WriteErrorDisallowedBySettings + WriteErrorExpiredResponse + WriteErrorFeatureDisabled + WriteErrorInsufficientResources + WriteErrorInvalidMatchField + WriteErrorInvalidStructuredHeader + WriteErrorNavigationRequest + WriteErrorNoMatchField + WriteErrorNonListMatchDestField + WriteErrorNonSecureContext + WriteErrorNonStringIdField + WriteErrorNonStringInMatchDestList + WriteErrorNonStringMatchField + WriteErrorNonTokenTypeField + WriteErrorRequestAborted + WriteErrorShuttingDown + WriteErrorTooLongIdField + WriteErrorUnsupportedType + # Details for issues around "Attribution Reporting API" usage. # Explainer: https://github.com/WICG/attribution-reporting-api type AttributionReportingIssueDetails extends object @@ -767,9 +796,13 @@ experimental domain Audits string url optional SourceCodeLocation location + type SharedDictionaryIssueDetails extends object + properties + SharedDictionaryError sharedDictionaryError + AffectedRequest request + type GenericIssueErrorType extends string enum - CrossOriginPortalPostMessageError FormLabelForNameError FormDuplicateIdForInputError FormInputWithNoLabelError @@ -818,6 +851,9 @@ experimental domain Audits type CookieDeprecationMetadataIssueDetails extends object properties array of string allowedSites + number optOutPercentage + boolean isOptOutTopLevel + CookieOperation operation type ClientHintIssueReason extends string enum @@ -855,7 +891,9 @@ experimental domain Audits ClientMetadataNoResponse ClientMetadataInvalidResponse ClientMetadataInvalidContentType + IdpNotPotentiallyTrustworthy DisabledInSettings + DisabledInFlags ErrorFetchingSignin InvalidSigninResponse AccountsHttpNotFound @@ -878,6 +916,9 @@ experimental domain Audits NotSignedInWithIdp MissingTransientUserActivation ReplacedByButtonMode + InvalidFieldsSpecified + RelyingPartyOriginIsOpaque + TypeNotMatching type FederatedAuthUserInfoRequestIssueDetails extends object properties @@ -972,6 +1013,7 @@ experimental domain Audits StylesheetLoadingIssue FederatedAuthUserInfoRequestIssue PropertyRuleIssue + SharedDictionaryIssue # This struct holds a list of optional fields with additional information # specific to the kind of issue. When adding a new issue code, please also @@ -998,6 +1040,7 @@ experimental domain Audits optional StylesheetLoadingIssueDetails stylesheetLoadingIssueDetails optional PropertyRuleIssueDetails propertyRuleIssueDetails optional FederatedAuthUserInfoRequestIssueDetails federatedAuthUserInfoRequestIssueDetails + optional SharedDictionaryIssueDetails sharedDictionaryIssueDetails # A unique id for a DevTools inspector issue. Allows other entities (e.g. # exceptions, CDP message, console messages, etc.) to reference an issue. @@ -1059,6 +1102,21 @@ experimental domain Audits parameters InspectorIssue issue +# Defines commands and events for browser extensions. Available if the client +# is connected using the --remote-debugging-pipe flag and +# the --enable-unsafe-extension-debugging flag is set. +experimental domain Extensions + # Installs an unpacked extension from the filesystem similar to + # --load-extension CLI flags. Returns extension ID once the extension + # has been installed. + command loadUnpacked + parameters + # Absolute file path. + string path + returns + # Extension id. + string id + # Defines commands and events for Autofill. experimental domain Autofill type CreditCard extends object @@ -1311,6 +1369,8 @@ domain Browser optional boolean userVisibleOnly # For "clipboard" permission, may specify allowWithoutSanitization. optional boolean allowWithoutSanitization + # For "fullscreen" permission, must specify allowWithoutGesture:true. + optional boolean allowWithoutGesture # For "camera" permission, may specify panTiltZoom. optional boolean panTiltZoom @@ -1970,6 +2030,7 @@ experimental domain CSS StyleSheetOrigin origin # Associated style declaration. CSSStyle style + boolean active # CSS keyframes rule representation. type CSSKeyframesRule extends object @@ -2145,8 +2206,11 @@ experimental domain CSS optional array of CSSKeyframesRule cssKeyframesRules # A list of CSS position fallbacks matching this node. deprecated optional array of CSSPositionFallbackRule cssPositionFallbackRules - # A list of CSS @position-try rules matching this node, based on the position-try-options property. + # A list of CSS @position-try rules matching this node, based on the position-try-fallbacks property. optional array of CSSPositionTryRule cssPositionTryRules + # Index of the active fallback in the applied position-try-fallback property, + # will not be set if there is no active position-try fallback. + optional integer activePositionFallbackIndex # A list of CSS at-property rules matching this node. optional array of CSSPropertyRule cssPropertyRules # A list of CSS property registrations matching this node. @@ -2578,13 +2642,14 @@ domain DOM marker backdrop selection + search-text target-text spelling-error grammar-error highlight first-line-inherited scroll-marker - scroll-markers + scroll-marker-group scrollbar scrollbar-thumb scrollbar-button @@ -3084,6 +3149,20 @@ domain DOM # NodeIds of top layer elements array of NodeId nodeIds + # Returns the NodeId of the matched element according to certain relations. + experimental command getElementByRelation + parameters + # Id of the node from which to query the relation. + NodeId nodeId + # Type of relation to get. + enum relation + # Get the popover target for a given element. In this case, this given + # element can only be an HTMLFormControlElement (,