Skip to content

Commit 18a69cf

Browse files
authored
Merge branch 'trunk' into py_webdriver_wait_custom_msg
2 parents af49b06 + e3a6119 commit 18a69cf

File tree

157 files changed

+3733
-1777
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

157 files changed

+3733
-1777
lines changed

.github/workflows/ci-grid-ui.yml

Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,38 @@
1+
name: CI - Grid UI
2+
3+
on:
4+
pull_request:
5+
paths:
6+
- 'javascript/grid-ui/**'
7+
push:
8+
branches:
9+
- trunk
10+
paths:
11+
- 'javascript/grid-ui/**'
12+
workflow_dispatch:
13+
workflow_call:
14+
15+
jobs:
16+
grid-ui-tests:
17+
runs-on: ubuntu-latest
18+
name: Grid UI Component Tests
19+
steps:
20+
- name: Checkout source tree
21+
uses: actions/checkout@v4
22+
with:
23+
fetch-depth: 50
24+
25+
- name: Setup Node.js
26+
uses: actions/setup-node@v4
27+
with:
28+
node-version: '18'
29+
cache: 'npm'
30+
cache-dependency-path: 'javascript/grid-ui/package.json'
31+
32+
- name: Install dependencies
33+
working-directory: javascript/grid-ui
34+
run: npm install
35+
36+
- name: Run component tests
37+
working-directory: javascript/grid-ui
38+
run: npm test

.github/workflows/ci-python.yml

Lines changed: 2 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -27,34 +27,12 @@ jobs:
2727
- name: Install dependencies
2828
run: |
2929
python -m pip install --upgrade pip
30-
pip install tox==4.6.4
30+
pip install tox==4.25.0
3131
- name: Test with tox
3232
run: tox -c py/tox.ini
3333
env:
3434
TOXENV: docs
3535

36-
lint:
37-
name: Lint
38-
needs: build
39-
runs-on: ubuntu-latest
40-
steps:
41-
- name: Checkout source tree
42-
uses: actions/checkout@v4
43-
- name: Set up Python 3.9
44-
uses: actions/setup-python@v4
45-
with:
46-
python-version: 3.9
47-
- name: Install dependencies
48-
run: |
49-
python -m pip install --upgrade pip
50-
pip install tox==4.6.4
51-
- name: Test with tox
52-
run: tox -c py/tox.ini
53-
env:
54-
# If this fails, it will exit. Local work should be using `tox -e linting` prior to committing.
55-
# the linting-ci recipe exists solely for CI and will not attempt to rewrite any files in-place etc.
56-
TOXENV: linting-ci
57-
5836
mypy:
5937
name: Mypy
6038
needs: build
@@ -69,7 +47,7 @@ jobs:
6947
- name: Install dependencies
7048
run: |
7149
python -m pip install --upgrade pip
72-
pip install tox==4.6.4
50+
pip install tox==4.25.0
7351
- name: Test with tox
7452
run: |
7553
tox -c py/tox.ini -- --cobertura-xml-report ci || true

MODULE.bazel

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,11 @@
11
module(name = "selenium")
22

33
bazel_dep(name = "apple_rules_lint", version = "0.4.0")
4+
bazel_dep(name = "aspect_rules_lint", version = "1.4.2")
45
bazel_dep(name = "aspect_bazel_lib", version = "2.13.0")
56
bazel_dep(name = "aspect_rules_esbuild", version = "0.21.0")
6-
bazel_dep(name = "aspect_rules_js", version = "2.1.3")
7-
bazel_dep(name = "aspect_rules_ts", version = "3.4.0")
7+
bazel_dep(name = "aspect_rules_js", version = "2.3.7")
8+
bazel_dep(name = "aspect_rules_ts", version = "3.6.0")
89
bazel_dep(name = "bazel_features", version = "1.23.0")
910
bazel_dep(name = "bazel_skylib", version = "1.7.1")
1011
bazel_dep(name = "buildifier_prebuilt", version = "6.4.0")

README.md

Lines changed: 3 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -217,21 +217,11 @@ To automatically update and pin new dependencies, run:
217217

218218
### Python
219219

220-
#### Linting
220+
#### Linting and Formatting
221221

222222
We follow the [PEP8 Style Guide for Python Code](https://peps.python.org/pep-0008) (except we use a 120 character line length).
223-
This is checked and enforced with several linting tools, including
224-
[black](https://pypi.org/project/black),
225-
[docformatter](https://pypi.org/project/docformatter),
226-
[flake8](https://flake8.pycqa.org),
227-
and [isort](https://pycqa.github.io/isort).
228-
229-
To run all of the linting tools:
230-
```shell
231-
./go py:lint
232-
```
233-
234-
You need `tox` installed to run the linting tools (`pip install tox`).
223+
This is checked and enforced with [ruff](https://docs.astral.sh/ruff/), a linting/formatting tool.
224+
There is also an auto-formatting script that can be run: `./scripts/format.sh`
235225

236226
#### Local Installation
237227

Rakefile

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -669,11 +669,6 @@ namespace :py do
669669
@git.add(conf)
670670
end
671671

672-
desc 'Update Python Syntax'
673-
task :lint do
674-
sh 'tox -c py/tox.ini -e linting'
675-
end
676-
677672
namespace :test do
678673
desc 'Python unit tests'
679674
task :unit do
@@ -1165,7 +1160,6 @@ namespace :all do
11651160
task :lint do
11661161
ext = /mswin|msys|mingw|cygwin|bccwin|wince|emc/.match?(RbConfig::CONFIG['host_os']) ? 'ps1' : 'sh'
11671162
sh "./scripts/format.#{ext}", verbose: true
1168-
Rake::Task['py:lint'].invoke
11691163
end
11701164

11711165
# Example: `./go all:prepare 4.31.0 early-stable`

common/devtools/convert_protocol_to_json.py

Lines changed: 16 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -10,13 +10,20 @@
1010

1111
import pdl
1212

13+
1314
def main(argv):
14-
parser = argparse.ArgumentParser(description=(
15-
"Converts from .pdl to .json by invoking the pdl Python module."))
16-
parser.add_argument('--map_binary_to_string', type=bool,
17-
help=('If set, binary in the .pdl is mapped to a '
18-
'string in .json. Client code will have to '
19-
'base64 decode the string to get the payload.'))
15+
parser = argparse.ArgumentParser(
16+
description=("Converts from .pdl to .json by invoking the pdl Python module.")
17+
)
18+
parser.add_argument(
19+
"--map_binary_to_string",
20+
type=bool,
21+
help=(
22+
"If set, binary in the .pdl is mapped to a "
23+
"string in .json. Client code will have to "
24+
"base64 decode the string to get the payload."
25+
),
26+
)
2027
parser.add_argument("pdl_file", help="The .pdl input file to parse.")
2128
parser.add_argument("json_file", help="The .json output file write.")
2229
args = parser.parse_args(argv)
@@ -26,10 +33,10 @@ def main(argv):
2633
protocol = pdl.loads(pdl_string, file_name, args.map_binary_to_string)
2734
input_file.close()
2835

29-
output_file = open(os.path.normpath(args.json_file), 'w')
30-
json.dump(protocol, output_file, indent=4, separators=(',', ': '))
36+
output_file = open(os.path.normpath(args.json_file), "w")
37+
json.dump(protocol, output_file, indent=4, separators=(",", ": "))
3138
output_file.close()
3239

3340

34-
if __name__ == '__main__':
41+
if __name__ == "__main__":
3542
sys.exit(main(sys.argv[1:]))

0 commit comments

Comments
 (0)