Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
seleniumhq
GitHub Repository: seleniumhq/selenium
Path: blob/trunk/py/pyproject.toml
2864 views
1
[build-system]
2
requires = ["setuptools", "setuptools-rust"]
3
build-backend = "setuptools.build_meta"
4
5
[project]
6
name = "selenium"
7
version = "4.35.0.202507081456"
8
license = { text = "Apache 2.0" }
9
description = "Official Python bindings for Selenium WebDriver."
10
readme = "README.rst"
11
requires-python = "~=3.9"
12
classifiers = [
13
"Development Status :: 5 - Production/Stable",
14
"Intended Audience :: Developers",
15
"Operating System :: POSIX",
16
"Operating System :: Microsoft :: Windows",
17
"Operating System :: MacOS :: MacOS X",
18
"Topic :: Software Development :: Testing",
19
"Topic :: Software Development :: Libraries",
20
"Programming Language :: Python",
21
"Programming Language :: Python :: 3.9",
22
"Programming Language :: Python :: 3.10",
23
"Programming Language :: Python :: 3.11",
24
"Programming Language :: Python :: 3.12",
25
"Programming Language :: Python :: 3.13",
26
]
27
dependencies = [
28
"urllib3[socks]~=2.5.0",
29
"trio~=0.30.0",
30
"trio-websocket~=0.12.2",
31
"certifi>=2025.6.15",
32
"typing_extensions~=4.14.0",
33
"websocket-client~=1.8.0",
34
]
35
36
[project.urls]
37
homepage = "https://www.selenium.dev"
38
source = "https://github.com/SeleniumHQ/selenium/tree/trunk/py"
39
download = "https://pypi.org/project/selenium"
40
changelog = "https://github.com/SeleniumHQ/selenium/blob/trunk/py/CHANGES"
41
documentation = "https://www.selenium.dev/documentation/webdriver"
42
issues = "https://github.com/SeleniumHQ/selenium/issues"
43
44
[tool.setuptools]
45
zip-safe = false
46
47
[tool.setuptools.packages.find]
48
include = ["selenium*"]
49
exclude = ["test*"]
50
namespaces = true
51
# include-package-data is `true` by default in pyproject.toml
52
53
[[tool.setuptools-rust.bins]]
54
target = "selenium.webdriver.common.selenium-manager"
55
56
[tool.setuptools.package-data]
57
"*" = [
58
"*.py",
59
"*.rst",
60
"*.json",
61
"*.xpi",
62
"*.js",
63
"py.typed",
64
"prune*",
65
"selenium.egg-info*",
66
"selenium-manager",
67
"selenium-manager.exe",
68
"CHANGES",
69
"LICENSE"
70
]
71
72
[tool.pytest.ini_options]
73
console_output_style = "progress"
74
faulthandler_timeout = 60
75
log_cli = true
76
trio_mode = true
77
markers = [
78
"xfail_chrome: Tests expected to fail in Chrome",
79
"xfail_edge: Tests expected to fail in Edge",
80
"xfail_firefox: Tests expected to fail in Firefox",
81
"xfail_ie: Tests expected to fail in IE",
82
"xfail_remote: Tests expected to fail with Remote webdriver",
83
"xfail_safari: Tests expected to fail in Safari",
84
"xfail_webkitgtk: Tests expected to fail in WebKitGTK",
85
"xfail_wpewebkit: Tests expected to fail in WPEWebKit",
86
"no_driver_after_test: If there are no drivers after the test it will create a new one."
87
]
88
python_files = ["test_*.py", "*_test.py", "*_tests.py"]
89
testpaths = ["test"]
90
91
# mypy global options
92
[tool.mypy]
93
exclude = "selenium/webdriver/common/devtools"
94
# The aim in future here is we would be able to turn (most) of these flags on, however the typing technical
95
# debt is quite colossal right now. For now we should maybe get everything working with the config here
96
# then look at going after partially or completely untyped defs as a phase-2.
97
files = "selenium"
98
# warn about per-module sections in the config file that do not match any files processed.
99
warn_unused_configs = true
100
# disallows subclassing of typing.Any.
101
disallow_subclassing_any = false
102
# disallow usage of generic types that do not specify explicit type parameters.
103
disallow_any_generics = false
104
# disallow calling functions without type annotations from functions that have type annotations.
105
disallow_untyped_calls = false
106
# disallow defining functions without type annotations or with incomplete annotations.
107
disallow_untyped_defs = false
108
# disallow defining functions with incomplete type annotations.
109
disallow_incomplete_defs = false
110
# type-checks the interior of functions without type annotations.
111
check_untyped_defs = false
112
# reports an error whenever a function with type annotations is decorated with a decorator without annotations.
113
disallow_untyped_decorators = false
114
# changes the treatment of arguments with a default value of None by not implicitly making their type `typing.Optional`.
115
no_implicit_optional = false
116
# warns about casting an expression to it's inferred type.
117
warn_redundant_casts = true
118
# warns about unneeded `# type: ignore` comments.
119
warn_unused_ignores = true
120
# warns when returning a value with typing.Any from a function with a non typing.Any return type.
121
warn_return_any = false
122
# Shows a warning when encountering any code inferred to be unreachable after performing type analysis.
123
warn_unreachable = false
124
125
# mypy module specific options
126
[[tool.mypy.trio_websocket]]
127
# suppress error messages about imports that cannot be resolved.
128
ignore_missing_imports = true
129
130
[[tool.mypy._winreg]]
131
# suppress error messages about imports that cannot be resolved.
132
ignore_missing_imports = true
133
134
[tool.ruff]
135
extend-exclude = [
136
"selenium/webdriver/common/devtools/",
137
"generate.py",
138
]
139
line-length = 120
140
respect-gitignore = true
141
target-version = "py39"
142
143
[tool.ruff.lint]
144
extend-select = ["E4", "E7", "E9", "F", "I", "E501", "RUF022"]
145
fixable = ["ALL"]
146
147
[tool.ruff.format]
148
docstring-code-format = true
149
docstring-code-line-length = 120
150
151