Description
We are currently using rules_python 1.9.0 for bazel. Upgrading to version 2.0.0 breaks the python build:
ERROR: Skipping '//py:selenium-wheel': error loading package 'py': Label '@@rules_python+//sphinxdocs:sphinx.bzl' is invalid because 'sphinxdocs' is not a package
See: https://github.com/SeleniumHQ/selenium/actions/runs/25072201045/job/73455578520?pr=17403#step:23:28 (from PR #17403)
This happens because we are using @rules_python//sphinxdocs to build our Python API docs. Apparantly, sphinx was never really a supported part of rules_python and just used for internal tooling... and is no longer available in rules_python 2.0.0 (bazel-contrib/rules_python#3705).
I think we need to update ./py/BUILD.bazel to stop loading @rules_python//sphinxdocs:sphinx.bzl because that package no longer exists, and replace it with a py_binary for sphinx-build and a rule that runs sphinx-build directly.
This isn't super high priority, but we are stuck on rules_python 1.9.0 until we fix this, and that prevents us from upgrading to newer Python toolchain versions when they become available.
Reproducible Code
Debugging Logs
ERROR: Skipping '//py:selenium-wheel': error loading package 'py': Label '@@rules_python+//sphinxdocs:sphinx.bzl' is invalid because 'sphinxdocs' is not a package
Description
We are currently using rules_python 1.9.0 for bazel. Upgrading to version 2.0.0 breaks the python build:
See: https://github.com/SeleniumHQ/selenium/actions/runs/25072201045/job/73455578520?pr=17403#step:23:28 (from PR #17403)
This happens because we are using
@rules_python//sphinxdocsto build our Python API docs. Apparantly, sphinx was never really a supported part of rules_python and just used for internal tooling... and is no longer available in rules_python 2.0.0 (bazel-contrib/rules_python#3705).I think we need to update
./py/BUILD.bazelto stop loading@rules_python//sphinxdocs:sphinx.bzlbecause that package no longer exists, and replace it with apy_binaryforsphinx-buildand a rule that runssphinx-builddirectly.This isn't super high priority, but we are stuck on rules_python 1.9.0 until we fix this, and that prevents us from upgrading to newer Python toolchain versions when they become available.
Reproducible Code
Debugging Logs