Skip to content

Commit

Permalink
Merge branch 'trunk' into test_cookie
Browse files Browse the repository at this point in the history
  • Loading branch information
diemol authored Dec 27, 2024
2 parents caadc0f + 33c6706 commit 4701cd4
Show file tree
Hide file tree
Showing 318 changed files with 9,808 additions and 8,744 deletions.
9 changes: 8 additions & 1 deletion .bazelrc
Original file line number Diff line number Diff line change
Expand Up @@ -30,10 +30,12 @@ build --tool_java_runtime_version=remotejdk_17
build --javacopt="--release 11"

# Require java dependencies to be used and first-order

build --experimental_strict_java_deps=strict
build --explicit_java_test_deps

# Avoid ErrorProne getting annoyed about "impossible null checks"
build --javacopt="-Xep:ImpossibleNullComparison:OFF"

# Allow spaces in runfile paths
build --nobuild_runfile_links

Expand All @@ -55,6 +57,11 @@ query --@aspect_rules_ts//ts:default_to_tsc_transpiler

build --incompatible_strict_action_env

# Required to get `protobuf` compiling, which is required for `rules_closure`
build --incompatible_enable_cc_toolchain_resolution
build --cxxopt=-std=c++14
build --host_cxxopt=-std=c++14

# For build stamping

build --enable_platform_specific_config
Expand Down
6 changes: 6 additions & 0 deletions .github/workflows/bazel.yml
Original file line number Diff line number Diff line change
Expand Up @@ -82,6 +82,12 @@ jobs:
steps:
- name: Checkout source tree
uses: actions/checkout@v4
- name: Pull latest changes from head ref for PRs
if: contains(github.head_ref, 'renovate/')
run: git pull origin ${{ github.head_ref }}
- name: Pull latest changes from ref for branch pushes
if: contains(github.ref, 'renovate/')
run: git pull origin ${{ github.ref }}
- name: Free space
if: inputs.os != 'windows'
run: ./scripts/github-actions/free-disk-space.sh
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/ci-rbe.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ on:
jobs:
format:
name: Format
if: github.repository_owner == 'seleniumhq'
if: github.repository_owner == 'seleniumhq' && startsWith(github.head_ref, 'renovate/') != true
uses: ./.github/workflows/bazel.yml
with:
name: Check format script run
Expand All @@ -20,7 +20,7 @@ jobs:

test:
name: Test
if: github.repository_owner == 'seleniumhq'
if: github.repository_owner == 'seleniumhq' && startsWith(github.head_ref, 'renovate/') != true
uses: ./.github/workflows/bazel.yml
with:
name: All RBE tests
Expand Down
68 changes: 68 additions & 0 deletions .github/workflows/ci-renovate-rbe.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,68 @@
name: CI - Renovate - RBE

on:
push:
branches:
- renovate/*
workflow_dispatch:

jobs:
pin:
runs-on: ubuntu-latest
if: github.repository_owner == 'seleniumhq'
steps:
- name: Checkout Repository
uses: actions/checkout@v4
- name: java - repin dependencies
if: contains(join(github.event.commits.*.message), '[java]')
run: RULES_JVM_EXTERNAL_REPIN=1 bazel run @maven//:pin
- name: rust - repin dependencies
if: contains(join(github.event.commits.*.message), '[rust]')
run: CARGO_BAZEL_REPIN=true bazel sync --only=crates
- name: js - repin dependencies
if: contains(join(github.event.commits.*.message), '[js]')
run: bazel run -- @pnpm//:pnpm install --dir $PWD --lockfile-only
- name: dotnet - repin dependencies
if: contains(join(github.event.commits.*.message), '[dotnet]')
run: ./dotnet/update-deps.sh
- name: py - repin dependencies
if: contains(join(github.event.commits.*.message), '[py]')
run: bazel run //py:requirements.update
- name: Commit files
run: |
export CHANGES=$(git status -s)
if [ -n "$CHANGES" ]; then
git config --local user.email "[email protected]"
git config --local user.name "Selenium CI Bot"
git add .
git commit -m 'Repin dependencies'
git push
fi
check-format:
needs: pin
name: Check format
if: github.repository_owner == 'seleniumhq'
uses: ./.github/workflows/bazel.yml
with:
name: Check format script run
caching: false
ruby-version: jruby-9.4.8.0
run: ./scripts/github-actions/check-format.sh

test:
name: Test
needs: pin
if: github.repository_owner == 'seleniumhq'
uses: ./.github/workflows/bazel.yml
with:
name: All RBE tests
caching: false
ruby-version: jruby-9.4.8.0
run: ./scripts/github-actions/ci-build.sh

ci-gh:
name: CI - GitHub
needs: pin
if: github.repository_owner == 'seleniumhq'
uses: ./.github/workflows/ci.yml
9 changes: 9 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,14 @@ on:
schedule:
- cron: "0 */12 * * *"
workflow_dispatch:
workflow_call:

jobs:
check:
name: Check
if: >
github.repository_owner == 'seleniumhq' &&
(startsWith(github.head_ref, 'renovate/') != true || github.event_name == 'workflow_call')
runs-on: ubuntu-latest
outputs:
targets: ${{ steps.check-targets.outputs.bazel-targets }}
Expand Down Expand Up @@ -44,6 +48,7 @@ jobs:
if: >
github.event_name == 'schedule' ||
github.event_name == 'workflow_dispatch' ||
github.event_name == 'workflow_call' ||
contains(needs.check.outputs.targets, '//dotnet') ||
contains(join(github.event.commits.*.message), '[dotnet]') ||
contains(github.event.pull_request.title, '[dotnet]')
Expand All @@ -55,6 +60,7 @@ jobs:
if: >
github.event_name == 'schedule' ||
github.event_name == 'workflow_dispatch' ||
github.event_name == 'workflow_call' ||
contains(needs.check.outputs.targets, '//java') ||
contains(join(github.event.commits.*.message), '[java]') ||
contains(github.event.pull_request.title, '[java]')
Expand All @@ -66,6 +72,7 @@ jobs:
if: >
github.event_name == 'schedule' ||
github.event_name == 'workflow_dispatch' ||
github.event_name == 'workflow_call' ||
contains(needs.check.outputs.targets, '//py') ||
contains(join(github.event.commits.*.message), '[py]') ||
contains(github.event.pull_request.title, '[py]')
Expand All @@ -77,6 +84,7 @@ jobs:
if: >
github.event_name == 'schedule' ||
github.event_name == 'workflow_dispatch' ||
github.event_name == 'workflow_call' ||
contains(needs.check.outputs.targets, '//rb') ||
contains(join(github.event.commits.*.message), '[rb]') ||
contains(github.event.pull_request.title, '[rb]')
Expand All @@ -90,6 +98,7 @@ jobs:
if: >
github.event_name == 'schedule' ||
github.event_name == 'workflow_dispatch' ||
github.event_name == 'workflow_call' ||
contains(needs.check.outputs.targets, '//rust') ||
contains(join(github.event.commits.*.message), '[rust]') ||
contains(github.event.pull_request.title, '[rust]')
1 change: 0 additions & 1 deletion .skipped-tests
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@
-//java/test/org/openqa/selenium/edge:EdgeDriverFunctionalTest
-//java/test/org/openqa/selenium/edge:EdgeDriverFunctionalTest-edge
-//java/test/org/openqa/selenium/edge:EdgeDriverFunctionalTest-remote
-//java/test/org/openqa/selenium/federatedcredentialmanagement:FederatedCredentialManagementTest
-//java/test/org/openqa/selenium/firefox:FirefoxDriverBuilderTest
-//java/test/org/openqa/selenium/grid/gridui:OverallGridTest
-//java/test/org/openqa/selenium/grid/router:RemoteWebDriverDownloadTest
Expand Down
68 changes: 37 additions & 31 deletions MODULE.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -12,19 +12,19 @@ bazel_dep(name = "contrib_rules_jvm", version = "0.27.0")
bazel_dep(name = "platforms", version = "0.0.10")

# Required for the closure rules
bazel_dep(name = "protobuf", version = "21.7", dev_dependency = True, repo_name = "com_google_protobuf")
bazel_dep(name = "protobuf", version = "29.1", dev_dependency = True, repo_name = "com_google_protobuf")

# Required for rules_rust to import the crates properly
bazel_dep(name = "rules_cc", version = "0.0.9", dev_dependency = True)

bazel_dep(name = "rules_dotnet", version = "0.16.1")
bazel_dep(name = "rules_java", version = "7.11.1")
bazel_dep(name = "rules_jvm_external", version = "6.3")
bazel_dep(name = "rules_jvm_external", version = "6.6")
bazel_dep(name = "rules_nodejs", version = "6.3.0")
bazel_dep(name = "rules_oci", version = "1.7.6")
bazel_dep(name = "rules_pkg", version = "0.10.1")
bazel_dep(name = "rules_python", version = "0.33.0")
bazel_dep(name = "rules_proto", version = "6.0.0")
bazel_dep(name = "rules_proto", version = "6.0.2")
bazel_dep(name = "rules_ruby", version = "0.13.0")

linter = use_extension("@apple_rules_lint//lint:extensions.bzl", "linter")
Expand Down Expand Up @@ -169,7 +169,7 @@ maven.install(
name = "maven",
artifacts = [
"com.beust:jcommander:1.82",
"com.github.javaparser:javaparser-core:3.26.2",
"com.github.javaparser:javaparser-core:3.26.3",
"com.github.spotbugs:spotbugs:4.8.6",
"com.github.stephenc.jcip:jcip-annotations:1.0-1",
"com.google.code.gson:gson:2.11.0",
Expand All @@ -181,48 +181,53 @@ maven.install(
"com.graphql-java:graphql-java:22.3",
"dev.failsafe:failsafe:3.3.2",
"io.grpc:grpc-context:1.68.1",
"io.lettuce:lettuce-core:6.5.0.RELEASE",
"io.netty:netty-buffer:4.1.115.Final",
"io.netty:netty-codec-http:4.1.115.Final",
"io.netty:netty-codec-http2:4.1.115.Final",
"io.netty:netty-common:4.1.115.Final",
"io.netty:netty-handler:4.1.115.Final",
"io.netty:netty-handler-proxy:4.1.115.Final",
"io.netty:netty-transport:4.1.115.Final",
"io.opentelemetry:opentelemetry-api:1.44.1",
"io.opentelemetry:opentelemetry-context:1.44.1",
"io.opentelemetry:opentelemetry-exporter-logging:1.44.1",
"io.opentelemetry:opentelemetry-sdk:1.44.1",
"io.opentelemetry:opentelemetry-sdk-common:1.44.1",
"io.opentelemetry:opentelemetry-sdk-extension-autoconfigure:1.44.1",
"io.opentelemetry:opentelemetry-sdk-extension-autoconfigure-spi:1.44.1",
"io.opentelemetry:opentelemetry-sdk-testing:1.44.1",
"io.opentelemetry:opentelemetry-sdk-trace:1.44.1",
"io.opentelemetry.semconv:opentelemetry-semconv:1.25.0-alpha",
"io.lettuce:lettuce-core:6.5.1.RELEASE",
"io.netty:netty-buffer",
"io.netty:netty-codec-http",
"io.netty:netty-codec-http2",
"io.netty:netty-common",
"io.netty:netty-handler",
"io.netty:netty-handler-proxy",
"io.netty:netty-transport",
"io.opentelemetry:opentelemetry-api",
"io.opentelemetry:opentelemetry-context",
"io.opentelemetry:opentelemetry-exporter-logging",
"io.opentelemetry:opentelemetry-sdk",
"io.opentelemetry:opentelemetry-sdk-common",
"io.opentelemetry:opentelemetry-sdk-extension-autoconfigure",
"io.opentelemetry:opentelemetry-sdk-extension-autoconfigure-spi",
"io.opentelemetry:opentelemetry-sdk-testing",
"io.opentelemetry:opentelemetry-sdk-trace",
"io.opentelemetry.semconv:opentelemetry-semconv:1.28.0-alpha",
"it.ozimov:embedded-redis:0.7.3",
"net.bytebuddy:byte-buddy:1.15.10",
"net.bytebuddy:byte-buddy:1.15.11",
"org.htmlunit:htmlunit-core-js:4.6.0",
"org.apache.commons:commons-exec:1.4.0",
"org.apache.logging.log4j:log4j-core:2.24.1",
"org.apache.logging.log4j:log4j-core:2.24.3",
"org.assertj:assertj-core:3.26.3",
"org.bouncycastle:bcpkix-jdk18on:1.79",
"org.eclipse.mylyn.github:org.eclipse.egit.github.core:2.1.5",
"org.hsqldb:hsqldb:2.7.4",
"org.jspecify:jspecify:1.0.0",
"org.junit.jupiter:junit-jupiter-api:5.11.3",
"org.junit.jupiter:junit-jupiter-engine:5.11.3",
"org.junit.jupiter:junit-jupiter-params:5.11.3",
"org.junit.platform:junit-platform-launcher:1.11.3",
"org.junit.platform:junit-platform-reporting:1.11.3",
"org.junit.platform:junit-platform-commons:1.11.3",
"org.junit.platform:junit-platform-engine:1.11.3",
"org.junit.jupiter:junit-jupiter-api",
"org.junit.jupiter:junit-jupiter-engine",
"org.junit.jupiter:junit-jupiter-params",
"org.junit.platform:junit-platform-launcher",
"org.junit.platform:junit-platform-reporting",
"org.junit.platform:junit-platform-commons",
"org.junit.platform:junit-platform-engine",
"org.mockito:mockito-core:5.14.2",
"org.redisson:redisson:3.39.0",
"org.slf4j:slf4j-api:2.0.16",
"org.slf4j:slf4j-jdk14:2.0.16",
"org.tomlj:tomlj:1.1.1",
"org.zeromq:jeromq:0.6.0",
],
boms = [
"io.opentelemetry:opentelemetry-bom:1.44.1",
"io.netty:netty-bom:4.1.115.Final",
"org.junit:junit-bom:5.11.3",
],
excluded_artifacts = [
"org.hamcrest:hamcrest-all", # Replaced by hamcrest 2
"org.hamcrest:hamcrest-core",
Expand All @@ -235,6 +240,7 @@ maven.install(
repositories = [
"https://repo1.maven.org/maven2",
],
resolver = "maven",
strict_visibility = True,
)
use_repo(maven, "maven", "unpinned_maven")
Expand Down
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
# Selenium

[![CI](https://github.com/SeleniumHQ/selenium/actions/workflows/ci.yml/badge.svg?branch=trunk&event=schedule)](https://github.com/SeleniumHQ/selenium/actions/workflows/ci.yml)
[![CI - RBE](https://github.com/SeleniumHQ/selenium/actions/workflows/ci-rbe.yml/badge.svg?branch=trunk&event=schedule)](https://github.com/SeleniumHQ/selenium/actions/workflows/ci-rbe.yml)
[![Releases downloads](https://img.shields.io/github/downloads/SeleniumHQ/selenium/total.svg)](https://github.com/SeleniumHQ/selenium/releases)

<a href="https://selenium.dev"><img src="common/images/selenium_logo_mark_green.svg" width="180" alt="Selenium Logo"/></a>
Expand Down
5 changes: 1 addition & 4 deletions Rakefile
Original file line number Diff line number Diff line change
Expand Up @@ -585,8 +585,7 @@ namespace :py do
nightly = ".#{Time.now.strftime('%Y%m%d%H%M')}"
new_version = updated_version(old_version, arguments[:version], nightly)

['py/setup.py',
'py/pyproject.toml',
['py/pyproject.toml',
'py/BUILD.bazel',
'py/selenium/__init__.py',
'py/selenium/webdriver/__init__.py',
Expand Down Expand Up @@ -1048,7 +1047,6 @@ namespace :all do
'py/selenium/webdriver/__init__.py',
'py/selenium/__init__.py',
'py/BUILD.bazel',
'py/setup.py',
'rb/lib/selenium/webdriver/version.rb',
'rb/Gemfile.lock'])

Expand Down Expand Up @@ -1110,7 +1108,6 @@ namespace :all do
'py/selenium/webdriver/__init__.py',
'py/BUILD.bazel',
'py/CHANGES',
'py/setup.py',
'rb/lib/selenium/webdriver/version.rb',
'rb/CHANGES',
'rb/Gemfile.lock',
Expand Down
17 changes: 4 additions & 13 deletions WORKSPACE
Original file line number Diff line number Diff line change
Expand Up @@ -6,17 +6,8 @@ load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive")

http_archive(
name = "io_bazel_rules_closure",
patch_args = [
"-p1",
],
patches = [
"//javascript:rules_closure_shell.patch",
],
sha256 = "d66deed38a0bb20581c15664f0ab62270af5940786855c7adc3087b27168b529",
strip_prefix = "rules_closure-0.11.0",
urls = [
"https://github.com/bazelbuild/rules_closure/archive/0.11.0.tar.gz",
],
strip_prefix = "rules_closure-0.12.0",
url = "https://github.com/bazelbuild/rules_closure/archive/refs/tags/0.12.0.tar.gz",
)

load("@io_bazel_rules_closure//closure:repositories.bzl", "rules_closure_dependencies", "rules_closure_toolchains")
Expand All @@ -34,8 +25,8 @@ rules_closure_toolchains()

http_archive(
name = "rules_rust",
integrity = "sha256-Zx3bP+Xrz53TTQUeynNS+68z+lO/Ye7Qt1pMNIKeVIA=",
urls = ["https://github.com/bazelbuild/rules_rust/releases/download/0.52.2/rules_rust-v0.52.2.tar.gz"],
integrity = "sha256-eEXiHXSGUH6qD1bdI5KXZ/B04m0wIUeoyM7pmujzbbQ=",
urls = ["https://github.com/bazelbuild/rules_rust/releases/download/0.55.5/rules_rust-0.55.5.tar.gz"],
)

load("@rules_rust//rust:repositories.bzl", "rules_rust_dependencies", "rust_register_toolchains")
Expand Down
Loading

0 comments on commit 4701cd4

Please sign in to comment.