Releases: aspect-build/rules_py
v1.7.2
Using Bzlmod with Bazel 6:
Add to your MODULE.bazel file:
bazel_dep(name = "aspect_rules_py", version = "1.7.2")And also register a Python toolchain, see rules_python. For example:
python = use_extension("@rules_python//python/extensions:python.bzl", "python")
python.toolchain(
python_version = "3.13",
)Using WORKSPACE
load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive")
http_archive(
name = "aspect_rules_py",
sha256 = "4552ca9663d7cc8771b4669fd18779f8ce3cb99bae265e443f0330f3d1be4f3d",
strip_prefix = "rules_py-1.7.2",
url = "https://github.com/aspect-build/rules_py/releases/download/v1.7.2/rules_py-v1.7.2.tar.gz",
)
load("@aspect_rules_py//py:repositories.bzl", "rules_py_dependencies")
rules_py_dependencies()
load("@aspect_rules_py//py:toolchains.bzl", "rules_py_toolchains")
rules_py_toolchains()
# "Installation" for rules_python
load("@rules_python//python:repositories.bzl", "py_repositories", "python_register_toolchains")
python_register_toolchains(
name = "python_toolchain",
python_version = "3.9",
)
py_repositories()What's Changed
- fix(uv): Venv config conditions to public by @arrdem in #749
- fix: add tar.bzl as dep since its needed sdist_build by @thesayyn in #751
Full Changelog: v1.7.1...v1.7.2
v1.7.1
Using Bzlmod with Bazel 6:
Add to your MODULE.bazel file:
bazel_dep(name = "aspect_rules_py", version = "1.7.1")And also register a Python toolchain, see rules_python. For example:
python = use_extension("@rules_python//python/extensions:python.bzl", "python")
python.toolchain(
python_version = "3.13",
)Using WORKSPACE
load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive")
http_archive(
name = "aspect_rules_py",
sha256 = "37f00178e42ce1afa73ecbebf3300c9dbb2285178d9eb3b5722f798a07c7a279",
strip_prefix = "rules_py-1.7.1",
url = "https://github.com/aspect-build/rules_py/releases/download/v1.7.1/rules_py-v1.7.1.tar.gz",
)
load("@aspect_rules_py//py:repositories.bzl", "rules_py_dependencies")
rules_py_dependencies()
load("@aspect_rules_py//py:toolchains.bzl", "rules_py_toolchains")
rules_py_toolchains()
# "Installation" for rules_python
load("@rules_python//python:repositories.bzl", "py_repositories", "python_register_toolchains")
python_register_toolchains(
name = "python_toolchain",
python_version = "3.9",
)
py_repositories()What's Changed
- chore(deps): update ubuntu:latest docker digest to c35e29c by @renovate[bot] in #717
- uv/host: Strip stdout of sw_vers on MacOS by @zsol in #719
- chore(deps): update container_structure_test digest to 63ee63e by @renovate[bot] in #716
- Some lockfile cleanup by @dzbarsky in #724
- chore(deps): update bazel-contrib/.github action to v7.2.3 by @renovate[bot] in #728
- chore(deps): update dependency bazel_lib to v3.0.0 by @renovate[bot] in #729
- Remove usage of deprecated ctx.build_file_path by @dzbarsky in #726
- Generate fewer targets for platform constraints by @dzbarsky in #727
- Cleanup more config_setting_group usage by @dzbarsky in #732
- fix(uv): Inline semver load by @arrdem in #735
- fix(uv): Correct repo metadata usage & support pre-Bazel 8 by @arrdem in #736
- chore: Upgrade tools_telemetry by @arrdem in #712
- chore(deps): update dependency bzip2 to v1.0.8.bcr.3 by @renovate[bot] in #733
- chore(deps): update dependency googleapis to v0.0.0-20251127-8cd3749f by @renovate[bot] in #734
- fix(uv): Ensure normalization of build dep names by @arrdem in #742
- fix(bazel9): CcInfo needs to come from rules_cc by @arrdem in #746
- fix: unblock bcr by @thesayyn in #747
New Contributors
Full Changelog: v1.7.0...v1.7.1
v1.7.0
Using Bzlmod with Bazel 6:
Add to your MODULE.bazel file:
bazel_dep(name = "aspect_rules_py", version = "1.7.0")And also register a Python toolchain, see rules_python. For example:
python = use_extension("@rules_python//python/extensions:python.bzl", "python")
python.toolchain(
python_version = "3.13",
)Using WORKSPACE
load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive")
http_archive(
name = "aspect_rules_py",
sha256 = "080a083244bb5307407e8099aabb1e0b8254d3af14c4c662a3841fcce05387f6",
strip_prefix = "rules_py-1.7.0",
url = "https://github.com/aspect-build/rules_py/releases/download/v1.7.0/rules_py-v1.7.0.tar.gz",
)
load("@aspect_rules_py//py:repositories.bzl", "rules_py_dependencies")
rules_py_dependencies()
load("@aspect_rules_py//py:toolchains.bzl", "rules_py_toolchains")
rules_py_toolchains()
# "Installation" for rules_python
load("@rules_python//python:repositories.bzl", "py_repositories", "python_register_toolchains")
python_register_toolchains(
name = "python_toolchain",
python_version = "3.9",
)
py_repositories()v1.6.6
Using Bzlmod with Bazel 6:
Add to your MODULE.bazel file:
bazel_dep(name = "aspect_rules_py", version = "1.6.6")And also register a Python toolchain, see rules_python. For example:
# Minimum version needs:
# feat: add interpreter_version_info to py_runtime by @mattem in #1671
bazel_dep(name = "rules_python", version = "0.29.0", dev_dependency = True)
python = use_extension("@rules_python//python/extensions:python.bzl", "python")
python.toolchain(
configure_coverage_tool = True,
python_version = "3.11",
)Using WORKSPACE
load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive")
http_archive(
name = "aspect_rules_py",
sha256 = "54ce31edca66e48bf4d683904940b40c1977b14e0b3393f4caf06d2c19230b8a",
strip_prefix = "rules_py-1.6.6",
url = "https://github.com/aspect-build/rules_py/releases/download/v1.6.6/rules_py-v1.6.6.tar.gz",
)
# Fetches the rules_py dependencies.
# If you want to have a different version of some dependency,
# you should fetch it *before* calling this.
# Alternatively, you can skip calling this function, so long as you've
# already fetched all the dependencies.
load("@aspect_rules_py//py:repositories.bzl", "rules_py_dependencies")
rules_py_dependencies()
load("@aspect_rules_py//py:toolchains.bzl", "rules_py_toolchains")
rules_py_toolchains()
# "Installation" for rules_python
load("@rules_python//python:repositories.bzl", "py_repositories", "python_register_toolchains")
python_register_toolchains(
name = "python_toolchain",
python_version = "3.9",
)
py_repositories()What's Changed
- chore: switch to bzl_library that checks docs by @alexeagle in #655
- tweak(py_venv): Don't modifying shell flags in
activateby @jgsogo in #669 - chore: remove generated docs by @alexeagle in #673
- feat: publish stardocs on releases by @alexeagle in #672
- fix(ci): Allow cancelling slow pre-commit job by @arrdem in #674
- chore(ci): Move subrepo e2e tests to workflows by @arrdem in #675
New Contributors
Full Changelog: v1.6.5...v1.6.6
v1.6.5
Using Bzlmod with Bazel 6:
Add to your MODULE.bazel file:
bazel_dep(name = "aspect_rules_py", version = "1.6.5")And also register a Python toolchain, see rules_python. For example:
# Minimum version needs:
# feat: add interpreter_version_info to py_runtime by @mattem in #1671
bazel_dep(name = "rules_python", version = "0.29.0", dev_dependency = True)
python = use_extension("@rules_python//python/extensions:python.bzl", "python")
python.toolchain(
configure_coverage_tool = True,
python_version = "3.11",
)Using WORKSPACE
load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive")
http_archive(
name = "aspect_rules_py",
sha256 = "6aabfc2c2f3b6a8ad80e4dfc251cfae872417134c1982396b1fce77dc518a62c",
strip_prefix = "rules_py-1.6.5",
url = "https://github.com/aspect-build/rules_py/releases/download/v1.6.5/rules_py-v1.6.5.tar.gz",
)
# Fetches the rules_py dependencies.
# If you want to have a different version of some dependency,
# you should fetch it *before* calling this.
# Alternatively, you can skip calling this function, so long as you've
# already fetched all the dependencies.
load("@aspect_rules_py//py:repositories.bzl", "rules_py_dependencies")
rules_py_dependencies()
load("@aspect_rules_py//py:toolchains.bzl", "rules_py_toolchains")
rules_py_toolchains()
# "Installation" for rules_python
load("@rules_python//python:repositories.bzl", "py_repositories", "python_register_toolchains")
python_register_toolchains(
name = "python_toolchain",
python_version = "3.9",
)
py_repositories()What's Changed
- chore: Support --incompatible_disable_native_repo_rules by @arrdem in #659
- chore: remove BCR homepage, as we now use the BCR UI itself by @alexeagle in #660
- chore(deps): update ubuntu:latest docker digest to 66460d5 by @renovate[bot] in #663
- chore: Add tests covering the version transition by @arrdem in #661
- fix(venv): Don't use dirs as the interpreter by @arrdem in #665
- chore(deps): Bump tools_telemetry by @arrdem in #667
- fix(py_venv): Partially resolve PYTHONHOME by @arrdem in #668
Full Changelog: v1.6.4...v1.6.5
v1.6.4
Using Bzlmod with Bazel 6:
Add to your MODULE.bazel file:
bazel_dep(name = "aspect_rules_py", version = "1.6.4")And also register a Python toolchain, see rules_python. For example:
# Minimum version needs:
# feat: add interpreter_version_info to py_runtime by @mattem in #1671
bazel_dep(name = "rules_python", version = "0.29.0", dev_dependency = True)
python = use_extension("@rules_python//python/extensions:python.bzl", "python")
python.toolchain(
configure_coverage_tool = True,
python_version = "3.11",
)Using WORKSPACE
load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive")
http_archive(
name = "aspect_rules_py",
sha256 = "6db8959662f743d9c31b6ed4c71df5b6d047407007c5256e70d56105ff487ff9",
strip_prefix = "rules_py-1.6.4",
url = "https://github.com/aspect-build/rules_py/releases/download/v1.6.4/rules_py-v1.6.4.tar.gz",
)
# Fetches the rules_py dependencies.
# If you want to have a different version of some dependency,
# you should fetch it *before* calling this.
# Alternatively, you can skip calling this function, so long as you've
# already fetched all the dependencies.
load("@aspect_rules_py//py:repositories.bzl", "rules_py_dependencies")
rules_py_dependencies()
load("@aspect_rules_py//py:toolchains.bzl", "rules_py_toolchains")
rules_py_toolchains()
# "Installation" for rules_python
load("@rules_python//python:repositories.bzl", "py_repositories", "python_register_toolchains")
python_register_toolchains(
name = "python_toolchain",
python_version = "3.9",
)
py_repositories()What's Changed
- fix: don't use version 0.0.0 by @alexeagle in #626
- feat(py_venv): activate-less interpreter by @arrdem in #629
- fix(pytest): Correct starlark deps by @mgred in #637
- feat(py_venv): Replace untennable copying with symlinks by @arrdem in #644
- Fix bug in
py_venvwhen using non runfiles python interpreter by @kriscfoster in #653 - Implement env/env_inherit semantics for py_venv_binary/py_venv_test by @plobsing in #616
- chore(rules_rust): Use compile_data by @arrdem in #656
- chore(py_venv): Cherry pick in tests from #635 by @arrdem in #657
- chore(ci): Automate pre-commit runs by @arrdem in #585
- fix(py_venv): Carefully resolve executable name to identify runfiles by @arrdem in #654
- feat(pex): support building PEX archives to inherit from the sys.path by @plobsing in #619
- fix(module): Avoid subrepo use by @arrdem in #658
New Contributors
- @mgred made their first contribution in #637
- @kriscfoster made their first contribution in #653
Full Changelog: v1.6.3...v1.6.4
v1.6.4-rc2
Using Bzlmod with Bazel 6:
Add to your MODULE.bazel file:
bazel_dep(name = "aspect_rules_py", version = "1.6.4-rc2")And also register a Python toolchain, see rules_python. For example:
# Minimum version needs:
# feat: add interpreter_version_info to py_runtime by @mattem in #1671
bazel_dep(name = "rules_python", version = "0.29.0", dev_dependency = True)
python = use_extension("@rules_python//python/extensions:python.bzl", "python")
python.toolchain(
configure_coverage_tool = True,
python_version = "3.11",
)Using WORKSPACE
load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive")
http_archive(
name = "aspect_rules_py",
sha256 = "b34cb7579470e2440cdbff63f19402fc5dcc86b29469b4e22d8f36a81ffd96b2",
strip_prefix = "rules_py-1.6.4-rc2",
url = "https://github.com/aspect-build/rules_py/releases/download/v1.6.4-rc2/rules_py-v1.6.4-rc2.tar.gz",
)
# Fetches the rules_py dependencies.
# If you want to have a different version of some dependency,
# you should fetch it *before* calling this.
# Alternatively, you can skip calling this function, so long as you've
# already fetched all the dependencies.
load("@aspect_rules_py//py:repositories.bzl", "rules_py_dependencies")
rules_py_dependencies()
load("@aspect_rules_py//py:toolchains.bzl", "rules_py_toolchains")
rules_py_toolchains()
# "Installation" for rules_python
load("@rules_python//python:repositories.bzl", "py_repositories", "python_register_toolchains")
python_register_toolchains(
name = "python_toolchain",
python_version = "3.9",
)
py_repositories()What's Changed
- fix: don't use version 0.0.0 by @alexeagle in #626
- feat(py_venv): activate-less interpreter by @arrdem in #629
- fix(pytest): Correct starlark deps by @mgred in #637
- fix(py_venv): Switch to symlinks for huge efficiency improvements
New Contributors
Full Changelog: v1.6.3...v1.6.4-rc2
v1.6.4-rc1
Using Bzlmod with Bazel 6:
Add to your MODULE.bazel file:
bazel_dep(name = "aspect_rules_py", version = "1.6.4-rc1")And also register a Python toolchain, see rules_python. For example:
# Minimum version needs:
# feat: add interpreter_version_info to py_runtime by @mattem in #1671
bazel_dep(name = "rules_python", version = "0.29.0", dev_dependency = True)
python = use_extension("@rules_python//python/extensions:python.bzl", "python")
python.toolchain(
configure_coverage_tool = True,
python_version = "3.11",
)Using WORKSPACE
load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive")
http_archive(
name = "aspect_rules_py",
sha256 = "e04710b92be447e1e66550baace85dbbef685c274c6286e9b69c9a6c59690288",
strip_prefix = "rules_py-1.6.4-rc1",
url = "https://github.com/aspect-build/rules_py/releases/download/v1.6.4-rc1/rules_py-v1.6.4-rc1.tar.gz",
)
# Fetches the rules_py dependencies.
# If you want to have a different version of some dependency,
# you should fetch it *before* calling this.
# Alternatively, you can skip calling this function, so long as you've
# already fetched all the dependencies.
load("@aspect_rules_py//py:repositories.bzl", "rules_py_dependencies")
rules_py_dependencies()
load("@aspect_rules_py//py:toolchains.bzl", "rules_py_toolchains")
rules_py_toolchains()
# "Installation" for rules_python
load("@rules_python//python:repositories.bzl", "py_repositories", "python_register_toolchains")
python_register_toolchains(
name = "python_toolchain",
python_version = "3.9",
)
py_repositories()What's Changed
- fix: don't use version 0.0.0 by @alexeagle in #626
- feat(py_venv): activate-less interpreter by @arrdem in #629
Full Changelog: v1.6.3...v1.6.4-rc1
v1.6.3
Using Bzlmod with Bazel 6:
Add to your MODULE.bazel file:
bazel_dep(name = "aspect_rules_py", version = "1.6.3")And also register a Python toolchain, see rules_python. For example:
# Minimum version needs:
# feat: add interpreter_version_info to py_runtime by @mattem in #1671
bazel_dep(name = "rules_python", version = "0.29.0", dev_dependency = True)
python = use_extension("@rules_python//python/extensions:python.bzl", "python")
python.toolchain(
configure_coverage_tool = True,
python_version = "3.11",
)Using WORKSPACE
load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive")
http_archive(
name = "aspect_rules_py",
sha256 = "c0bdd4a562a40b1931a373dfa3999e8aafdb2cfc25dcd641934a9164f3cd3431",
strip_prefix = "rules_py-1.6.3",
url = "https://github.com/aspect-build/rules_py/releases/download/v1.6.3/rules_py-v1.6.3.tar.gz",
)
# Fetches the rules_py dependencies.
# If you want to have a different version of some dependency,
# you should fetch it *before* calling this.
# Alternatively, you can skip calling this function, so long as you've
# already fetched all the dependencies.
load("@aspect_rules_py//py:repositories.bzl", "rules_py_dependencies")
rules_py_dependencies()
load("@aspect_rules_py//py:toolchains.bzl", "rules_py_toolchains")
rules_py_toolchains()
# "Installation" for rules_python
load("@rules_python//python:repositories.bzl", "py_repositories", "python_register_toolchains")
python_register_toolchains(
name = "python_toolchain",
python_version = "3.9",
)
py_repositories()What's Changed
- fix(pypex): spill to a param file for PyPex when necessary by @plobsing in #617
- chore(deps): Bump tools_telemetry by @arrdem in #624
New Contributors
Full Changelog: v1.6.2...v1.6.3
v1.6.2
Using Bzlmod with Bazel 6:
Add to your MODULE.bazel file:
bazel_dep(name = "aspect_rules_py", version = "1.6.2")And also register a Python toolchain, see rules_python. For example:
# Minimum version needs:
# feat: add interpreter_version_info to py_runtime by @mattem in #1671
bazel_dep(name = "rules_python", version = "0.29.0", dev_dependency = True)
python = use_extension("@rules_python//python/extensions:python.bzl", "python")
python.toolchain(
configure_coverage_tool = True,
python_version = "3.11",
)Using WORKSPACE
load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive")
http_archive(
name = "aspect_rules_py",
sha256 = "48a64cabfda973015e9bc3874c1296fd89320088fe3b706aefffbeafdd95953b",
strip_prefix = "rules_py-1.6.2",
url = "https://github.com/aspect-build/rules_py/releases/download/v1.6.2/rules_py-v1.6.2.tar.gz",
)
# Fetches the rules_py dependencies.
# If you want to have a different version of some dependency,
# you should fetch it *before* calling this.
# Alternatively, you can skip calling this function, so long as you've
# already fetched all the dependencies.
load("@aspect_rules_py//py:repositories.bzl", "rules_py_dependencies")
rules_py_dependencies()
load("@aspect_rules_py//py:toolchains.bzl", "rules_py_toolchains")
rules_py_toolchains()
# "Installation" for rules_python
load("@rules_python//python:repositories.bzl", "py_repositories", "python_register_toolchains")
python_register_toolchains(
name = "python_toolchain",
python_version = "3.9",
)
py_repositories()What's Changed
- fix(venv_link): Correct name argument by @arrdem in #601
- Add language regarding telemetry to the README by @arrdem in #614
- Fix debug logging in release by @arrdem in #613
- chore(deps): Bump tools_telemetry by @arrdem in #623
Full Changelog: v1.6.1...v1.6.2