Skip to content
Open
Show file tree
Hide file tree
Changes from 7 commits
Commits
Show all changes
57 commits
Select commit Hold shift + click to select a range
04b389f
[java][bidi] Add BiDi code generator
pujagani Jul 14, 2026
733f0d8
Fixing CI. Fixing bugs to match the low-level contract
pujagani Jul 22, 2026
95e1e95
Address comments
pujagani Jul 22, 2026
e1c3689
Address comments
pujagani Jul 22, 2026
fad9cde
Fix tests
pujagani Jul 22, 2026
a2fa95c
Address comments
pujagani Jul 22, 2026
7e5e00c
Ensure Javadoc is there
pujagani Jul 29, 2026
e21617c
[build] Merge vendor cddl files into shared BiDi schema and implement…
titusfortner Jul 29, 2026
fc654de
[grid] honor client-advertised se:remoteUrl for reachable BiDi/CDP/VN…
titusfortner Jul 29, 2026
618f12b
[rb] tolerate and warn on missing required inbound BiDi fields, with …
titusfortner Jul 29, 2026
06be624
[build] reconcile API-compatibility invariant with the deprecation po…
titusfortner Jul 29, 2026
8daa0d1
[java][js][rb] remove deprecated FTP proxy support (#17846)
titusfortner Jul 30, 2026
bf18c11
[rust] locate Chrome and Edge in known install directories (#17838)
titusfortner Jul 30, 2026
144db0c
[dotnet][py][rb] prevent CDP access with Firefox (#17849)
titusfortner Jul 31, 2026
7cd29f9
[rb] test matchers assert log entries by id and optional messages and…
titusfortner Jul 31, 2026
2762f55
[rb] ensure ruby tests are properly linted (#17850)
titusfortner Jul 31, 2026
f47fbb6
[bidi] Correct float/enum type fidelity in the shared schema and vali…
titusfortner Jul 31, 2026
6d75941
[bidi] mark BiDi types extensible per spec and update Ruby handling (…
titusfortner Aug 1, 2026
83f26a2
[rb] add browser_family test guard and use it for chromium/safari fam…
titusfortner Aug 1, 2026
9912e65
[dotnet] [bidi] Don't warn if there are no subscribers (#17857)
nvborisenko Aug 2, 2026
89ad5bb
[rb] raise typed WebDriver errors for BiDi from a generated error-cod…
titusfortner Aug 2, 2026
47edefb
[grid] Store Dynamic Grid videos in a per-session subfolder via SE_VI…
VietND96 Aug 2, 2026
e107560
[grid] inherit the Node Pod container securityContext for Dynamic Gri…
VietND96 Aug 2, 2026
4c6f3a5
[rb] allow pending test guards to require matching provided exception…
titusfortner Aug 2, 2026
de243e1
[build] update rerun with debug so console sees all test output
titusfortner Aug 3, 2026
812df70
[build] failing .NET integration tests need to rerun with debug
titusfortner Aug 3, 2026
10eeb94
[dotnet][java][py][rb] pass --enable-chrome-logs unless CHROME_LOG_FI…
titusfortner Aug 3, 2026
0ad0c51
[rb] support custom vendor specific capabilities in options classes (…
titusfortner Aug 3, 2026
e0658c9
[rb] validate BiDi outbound ref fields against their declared type (#…
titusfortner Aug 3, 2026
014d72b
[rb] fix tests and custom matchers to work with SE_DEBUG (#17863)
titusfortner Aug 3, 2026
094f26f
[build] derive per-type inbound/outbound directionality in the shared…
titusfortner Aug 3, 2026
92223f9
[build] Automated Browser Version Update (#17839)
selenium-ci Aug 3, 2026
5b1cde1
[rb] generate BiDi domain type accessors and union variant factories …
titusfortner Aug 3, 2026
5ae1a8e
[build] update node versioning for testing and publishing (#17866)
titusfortner Aug 3, 2026
d9b3424
[build] Automated Browser Version Update (#17868)
selenium-ci Aug 4, 2026
778cc7a
[py] accept By in find_element/find_elements type hints (#17870)
titusfortner Aug 4, 2026
a421014
[build] update CDP from daily pin browser workflow (#17872)
titusfortner Aug 4, 2026
7e1c3fd
[build] re-lock Gemfile after CDP update
titusfortner Aug 4, 2026
88e2d0c
[js] Wait for async BiDi events and window resize in flaky tests (#17…
titusfortner Aug 5, 2026
05a002e
[dotnet] fix flaky cancellation test to accept OperationCanceledExcep…
titusfortner Aug 5, 2026
960abd2
[dotnet][java][js][rb] deprecate invalid Firefox profile code (#17871)
titusfortner Aug 5, 2026
a25afbb
[build] Automated Browser Version Update with CDP (#17873)
selenium-ci Aug 5, 2026
4376465
[build] patch rules_ruby to emit Windows batch launchers with CRLF
titusfortner Aug 5, 2026
4efbdf0
[grid] Dynamic K8s video always use the per-session subfolder; remove…
VietND96 Aug 5, 2026
b9d61b7
[rust] Prevent empty driver version from being cached in metadata (#1…
MathiasPaulenko Aug 5, 2026
62b6294
[dotnet] support SE_*DRIVER environment variables to set driver locat…
titusfortner Aug 5, 2026
4f1e333
[dotnet] [bidi] Make BiDi transport factories composable (#17877)
nvborisenko Aug 5, 2026
d879eda
[java] Fix By.className()/By.id() misescaping non-ASCII leading digit…
diemol Aug 6, 2026
06a692e
[py] fix no_proxy matching so empty entries and substrings do not byp…
navin772 Aug 7, 2026
9810406
[java][bidi] Add BiDi code generator
pujagani Jul 14, 2026
be81a6a
Fixing CI. Fixing bugs to match the low-level contract
pujagani Jul 22, 2026
2c82de3
Address comments
pujagani Jul 22, 2026
4139a8e
Address comments
pujagani Jul 22, 2026
cf5b6c7
Fix tests
pujagani Jul 22, 2026
2395d06
Address comments
pujagani Jul 22, 2026
fe68da5
Ensure Javadoc is there
pujagani Jul 29, 2026
c72ff7f
Merge branch 'java-bidi-codegen' of https://github.com/pujagani/selen…
pujagani Aug 7, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions java/spotbugs-excludes.xml
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,11 @@
<Bug pattern="EQ_CHECK_FOR_OPERAND_NOT_COMPATIBLE_WITH_THIS"/>
</Match>

<Match>
<Class name="org.openqa.selenium.bidi.protocol.script.EvaluateResultException"/>
<Bug pattern="NM_CLASS_NOT_EXCEPTION"/>
</Match>

<Match>
<Class name="org.openqa.selenium.build.Build"/>
<Bug pattern="NP_NULL_ON_SOME_PATH_FROM_RETURN_VALUE"/>
Expand Down
50 changes: 48 additions & 2 deletions java/src/org/openqa/selenium/bidi/BUILD.bazel
Original file line number Diff line number Diff line change
@@ -1,9 +1,13 @@
load("//java:defs.bzl", "java_library")
load("//java:defs.bzl", "java_binary", "java_library")

AUGMENTER_SRCS = [
"BiDiProvider.java",
]

GENERATOR_SRCS = [
"BiDiGenerator.java",
]

java_library(
name = "augmenter",
srcs = AUGMENTER_SRCS,
Expand All @@ -26,7 +30,7 @@ java_library(
[
"*.java",
],
exclude = AUGMENTER_SRCS,
exclude = AUGMENTER_SRCS + GENERATOR_SRCS,
),
visibility = [
"//java/src/org/openqa/selenium/bidi:__subpackages__",
Expand All @@ -42,3 +46,45 @@ java_library(
"@maven//:org_jspecify_jspecify",
],
)

java_binary(
name = "bidi-client-generator",
srcs = GENERATOR_SRCS,
main_class = "org.openqa.selenium.bidi.BiDiGenerator",
deps = [
"//java/src/org/openqa/selenium/json",
],
)

genrule(

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Remediation recommended

1. Unquoted genrule arguments 🐞 Bug ☼ Reliability

The new :generate-bidi genrule builds a shell command without quoting the tool path, schema path, or
output path, so the action can fail when any of those paths contain spaces or shell-special
characters. This makes BiDi generation brittle and can break Bazel builds depending on
workspace/execroot location.
Agent Prompt
### Issue description
The `genrule(name = "generate-bidi")` command concatenates `$(execpath ...)`, `$(location ...)`, and `$@` into a shell command without quoting. If any expanded path contains whitespace or shell-special characters, the generator will receive split/incorrect arguments and the build will fail.

### Issue Context
This genrule is new in this PR and is used to generate `bidi-generated.srcjar` during the build.

### Fix Focus Areas
- java/src/org/openqa/selenium/bidi/BUILD.bazel[59-65]

### Suggested fix
Update `cmd` to quote each argument as a single shell token, e.g.:

```bzl
cmd = "\"$(execpath :bidi-client-generator)\" \"$(location //javascript/selenium-webdriver:create-bidi-src_schema)\" \"$@\"",
```

(or equivalent quoting per the repo’s Bazel shell conventions), so paths with spaces are handled correctly.

β“˜ Copy this prompt and use it to remediate the issue with your preferred AI generation tools

name = "generate-bidi",
srcs = ["//javascript/selenium-webdriver:create-bidi-src_schema"],
outs = ["bidi-generated.srcjar"],
cmd = "$(execpath :bidi-client-generator) $(location //javascript/selenium-webdriver:create-bidi-src_schema) $@",
tools = [":bidi-client-generator"],
)

# Autogen, not checked in: the build compiles :generate-bidi's srcjar directly, nothing is
# hand-edited, every build ships fresh output. The cross-binding BiDi codegen decisions doc (G1)
# calls checking-in-while-unproven the general recommendation, but also names this exact shape β€”
# build-time generation straight into bazel-out β€” as the end state, and notes selenium-devtools/CDP
# in this repo already works this way. Matching that existing, already-de-risked precedent avoids
# standing up a separate checked-in + verify-test workflow (with its own CI-coverage question to
# resolve first) just for BiDi. Trade-off accepted knowingly: less reviewable diff surface while the
# generator is still new.
java_library(
name = "bidi-generated",
srcs = [":generate-bidi"],
visibility = [
"//java/src/org/openqa/selenium/bidi:__subpackages__",
"//java/src/org/openqa/selenium/remote:__pkg__",
"//java/test/org/openqa/selenium/bidi:__subpackages__",
"//java/test/org/openqa/selenium/grid:__subpackages__",
],
deps = [
":bidi",
"//java/src/org/openqa/selenium:core",
"//java/src/org/openqa/selenium/json",
"@maven//:org_jspecify_jspecify",
],
)
Loading
Loading