0.25.0
Using Bzlmod with Bazel 6
NOTE: bzlmod support is still beta. APIs subject to change.
Add to your MODULE.bazel
file:
bazel_dep(name = "rules_python", version = "0.25.0")
pip = use_extension("@rules_python//python/extensions:pip.bzl", "pip")
pip.parse(
name = "pip",
requirements_lock = "//:requirements_lock.txt",
)
use_repo(pip, "pip")
Using WORKSPACE
Paste this snippet into your WORKSPACE
file:
load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive")
http_archive(
name = "rules_python",
sha256 = "5868e73107a8e85d8f323806e60cad7283f34b32163ea6ff1020cf27abef6036",
strip_prefix = "rules_python-0.25.0",
url = "https://github.com/bazelbuild/rules_python/releases/download/0.25.0/rules_python-0.25.0.tar.gz",
)
load("@rules_python//python:repositories.bzl", "py_repositories")
py_repositories()
Gazelle plugin
Paste this snippet into your WORKSPACE
file:
load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive")
http_archive(
name = "rules_python_gazelle_plugin",
sha256 = "5868e73107a8e85d8f323806e60cad7283f34b32163ea6ff1020cf27abef6036",
strip_prefix = "rules_python-0.25.0/gazelle",
url = "https://github.com/bazelbuild/rules_python/releases/download/0.25.0/rules_python-0.25.0.tar.gz",
)
# To compile the rules_python gazelle extension from source,
# we must fetch some third-party go dependencies that it uses.
load("@rules_python_gazelle_plugin//:deps.bzl", _py_gazelle_deps = "gazelle_deps")
_py_gazelle_deps()
What's Changed
- docs: Use correct pip extension path in generated release notes by @rickeylev in #1310
- doc: correct name of rules_python in bzlmod support doc by @aignas in #1317
- test: Remove testonly=True from test toolchain implementations by @rickeylev in #1327
- cleanup: Add placeholder comment to defs.bzl to make patching loads easier by @rickeylev in #1319
- fix(multi-versions): correctly default 'main' arg for transition rules by @aignas in #1316
- refactor: have a single function for normalized PyPI package names by @aignas in #1329
- refactor: add a version label function for consistent labels by @aignas in #1328
- docs: Updating README by @chrislovecnm in #1282
- revert(bzlmod)!: allow bzlmod pip.parse to implicitly use default python version by @chrislovecnm in #1341
- feat: stop generating imports when not necessary by @linzhp in #1335
- fix: Don't require default Python version for pip hubs by @rickeylev in #1344
- docs: Better explain when and how to use toolchains for bzlmod by @rickeylev in #1349
- refactor(whl_library): move bazel file generation to Starlark by @aignas in #1336
- feat: add a tool to update internal dependencies by @aignas in #1321
- refactor: support rendering pkg aliases without whl_library_alias by @aignas in #1346
- Feat: Using repo-relative labels by @chrislovecnm in #1367
- feat: Add s390x release by @namrata-ibm in #1352
- feat: Improve exec error handling by @chrislovecnm in #1368
- feat: Update MINOR_MAPPING to latest version by @namrata-ibm in #1370
- feat: add CHANGELOG to make summarizing releases easier. by @rickeylev in #1382
- docs: add update changelog as part of pull request instructions by @rickeylev in #1384
- tests: Expose test's fake_header.h so py_cc_toolchain tests can use it. by @rickeylev in #1388
- Update changelog for 0.25.0 by @rickeylev in #1389
New Contributors
- @namrata-ibm made their first contribution in #1352
Full Changelog: 0.24.0...0.25.0