Skip to content

chore!: drop WORKSPACE support from rules_python#3780

Draft
aignas wants to merge 3 commits into
bazel-contrib:mainfrom
aignas:aignas.chore.drop-workspace
Draft

chore!: drop WORKSPACE support from rules_python#3780
aignas wants to merge 3 commits into
bazel-contrib:mainfrom
aignas:aignas.chore.drop-workspace

Conversation

@aignas
Copy link
Copy Markdown
Collaborator

@aignas aignas commented May 16, 2026

All of the bazel versions that we support support bzlmod and the support for
WORKSPACE is being dropped in other rulesets as well. At some point new
versions of our dependencies will make it more and more difficult to carry
support for both, so in order to make the codebase easier to maintain, let's
drop the support.

Regarding whether we should call the next version 2.1 or 3.0, I am not sure.
For bzlmod users nothing is changing, so Semver is respected, whereas for
WORKSPACE users, rules_python cannot be used anymore, it's as if 2.1 no
longer exists for WORKSPACE users, so I think it is fine to call the release
2.1.

Summary:

  • Remove examples.
  • Remove docs.
  • Start dropping symbols and support as well.

Work towards #2950

Copy link
Copy Markdown
Contributor

@gemini-code-assist gemini-code-assist Bot left a comment

Choose a reason for hiding this comment

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

Code Review

This pull request focuses on the deprecation and removal of legacy WORKSPACE support in favor of bzlmod for PyPI dependency management. It includes the deletion of several WORKSPACE files across examples, updates to documentation to reflect the shift, and the removal of WORKSPACE-specific logic and symbols from the core build rules. Additionally, the PR applies minor formatting improvements to various Python scripts throughout the repository. I have no feedback to provide.

@aignas aignas marked this pull request as draft May 16, 2026 06:01
baz import (
baz
)
from foo.bar.baz import baz
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Looks like autoformatting snuck in.

Either wrap in # fmt: off # fmt: on comments, or tell formatter to ignore this file. This one is intentionally asserting some python AST parsing.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants