44# rules_python Changelog
55
66This is a human-friendly changelog in a keepachangelog.com style format.
7- Because this changelog is for end-user consumption of meaningful changes,only
7+ Because this changelog is for end-user consumption of meaningful changes, only
88a summary of a release's changes is described. This means every commit is not
99necessarily mentioned, and internal refactors or code cleanups are omitted
1010unless they're particularly notable.
@@ -52,12 +52,110 @@ Unreleased changes template.
5252
5353{#v0-0-0-changed}
5454### Changed
55+ * (deps) platforms 0.0.4 -> 0.0.11
56+ * (py_wheel) Package ` py_library.pyi_srcs ` (` .pyi ` files) in the wheel.
57+ * (py_package) Package ` py_library.pyi_srcs ` (` .pyi ` files) in ` py_package ` .
58+ * (pypi) Use ` xcrun xcodebuild --showsdks ` to find XCode root.
59+
60+ {#v0-0-0-fixed}
61+ ### Fixed
62+ * (pypi) The ` ppc64le ` is now pointing to the right target in the ` platforms ` package.
63+ * (gazelle) No longer incorrectly merge ` py_binary ` targets during partial updates in
64+ ` file ` generation mode. Fixed in [ #2619 ] ( https://github.com/bazelbuild/rules_python/pull/2619 ) .
65+ * (bzlmod) Running as root is no longer an error. ` ignore_root_user_error=True `
66+ is now the default. Note that running as root may still cause spurious
67+ Bazel cache invalidation
68+ ([ #1169 ] ( https://github.com/bazelbuild/rules_python/issues/1169 ) ).
69+ * (gazelle) Don't collapse depsets to a list or into args when generating the modules mapping file.
70+ Support spilling modules mapping args into a params file.
71+
72+ {#v0-0-0-added}
73+ ### Added
74+ * {obj}` //python/bin:python ` : convenience target for directly running an
75+ interpreter. {obj}` --//python/bin:python_src ` can be used to specify a
76+ binary whose interpreter to use.
77+
78+ {#v0-0-0-removed}
79+ ### Removed
80+ * Nothing removed.
81+
82+ {#v1-2-0}
83+ ## [ 1.2.0] - 2025-02-21
84+
85+ [ 1.2.0 ] : https://github.com/bazelbuild/rules_python/releases/tag/1.2.0
86+
87+ {#v1-2-0-changed}
88+ ### Changed
89+ * (rules) ` py_proto_library ` is deprecated in favour of the
90+ implementation in https://github.com/protocolbuffers/protobuf . It will be
91+ removed in the future release.
92+ * (pypi) {obj}` pip.override ` will now be ignored instead of raising an error,
93+ fixes [ #2550 ] ( https://github.com/bazelbuild/rules_python/issues/2550 ) .
94+ * (rules) deprecation warnings for deprecated symbols have been turned off by
95+ default for now and can be enabled with ` RULES_PYTHON_DEPRECATION_WARNINGS `
96+ env var.
97+ * (pypi) Downgraded versions of packages: ` pip ` from ` 24.3.2 ` to ` 24.0.0 ` and
98+ ` packaging ` from ` 24.2 ` to ` 24.0 ` .
99+
100+ {#v1-2-0-fixed}
101+ ### Fixed
102+ * (rules) ` python_zip_file ` output with ` --bootstrap_impl=script ` works again
103+ ([ #2596 ] ( https://github.com/bazelbuild/rules_python/issues/2596 ) ).
104+ * (docs) Using ` python_version ` attribute for specifying python versions introduced in ` v1.1.0 `
105+ * (gazelle) Providing multiple input requirements files to ` gazelle_python_manifest ` now works correctly.
106+ * (pypi) Handle trailing slashes in pip index URLs in environment variables,
107+ fixes [ #2554 ] ( https://github.com/bazelbuild/rules_python/issues/2554 ) .
108+ * (runfiles) Runfile manifest and repository mapping files are now interpreted
109+ as UTF-8 on all platforms.
110+ * (coverage) Coverage with ` --bootstrap_impl=script ` is fixed
111+ ([ #2572 ] ( https://github.com/bazelbuild/rules_python/issues/2572 ) ).
112+ * (pypi) Non deterministic behaviour in requirement file usage has been fixed
113+ by reverting [ #2514 ] ( https://github.com/bazelbuild/rules_python/pull/2514 ) .
114+ The related issue is [ #908 ] ( https://github.com/bazelbuild/rules_python/issue/908 ) .
115+ * (sphinxdocs) Do not crash when ` tag_class ` does not have a populated ` doc ` value.
116+ Fixes ([ #2579 ] ( https://github.com/bazelbuild/rules_python/issues/2579 ) ).
117+ * (binaries/tests) Fix packaging when using ` --bootstrap_impl=script ` : set
118+ {obj}` --venvs_use_declare_symlink=no ` to have it not create symlinks at
119+ build time (they will be created at runtime instead).
120+ (Fixes [ #2489 ] ( https://github.com/bazelbuild/rules_python/issues/2489 ) )
121+
122+ {#v1-2-0-added}
123+ ### Added
124+ * Nothing added.
125+
126+ {#v1-2-0-removed}
127+ ### Removed
128+ * Nothing removed.
129+
130+ {#v1-1-0}
131+ ## [ 1.1.0] - 2025-01-07
132+
133+ [ 1.1.0 ] : https://github.com/bazelbuild/rules_python/releases/tag/1.1.0
134+
135+ {#v1-1-0-changed}
136+ ### Changed
137+ * (toolchains) 3.13 means 3.13.1 (previously 3.13.0)
55138* Bazel 6 support is dropped and Bazel 7.4.1 is the minimum supported
56139 version, per our Bazel support matrix. Earlier versions are not
57140 tested by CI, so functionality cannot be guaranteed.
58- * Use ` xcrun xcodebuild --showsdks ` to find XCode root
59-
60- {#v0-0-0-fixed}
141+ * ({bzl: obj }` pip.parse ` ) From now we will make fewer calls to indexes when
142+ fetching the metadata from SimpleAPI. The calls will be done in parallel to
143+ each index separately, so the extension evaluation time might slow down if
144+ not using {bzl: obj }` pip.parse.experimental_index_url_overrides ` .
145+ * ({bzl: obj }` pip.parse ` ) Only query SimpleAPI for packages that have
146+ sha values in the ` requirements.txt ` file.
147+ * (rules) The version-aware rules have been folded into the base rules and
148+ the version-aware rules are now simply aliases for the base rules. The
149+ ` python_version ` attribute is still used to specify the Python version.
150+ * (pypi) Updated versions of packages: ` pip ` to 24.3.1 and
151+ ` packaging ` to 24.2.
152+
153+ {#v1-1-0-deprecations}
154+ #### Deprecations
155+ * ` //python/config_settings:transitions.bzl ` and its ` py_binary ` and ` py_test `
156+ wrappers are deprecated. Use the regular rules instead.
157+
158+ {#v1-1-0-fixed}
61159### Fixed
62160* (py_wheel) Use the default shell environment when building wheels to allow
63161 toolchains that search PATH to be used for the wheel builder tool.
@@ -71,10 +169,22 @@ Unreleased changes template.
71169* (pypi) Using {bzl: obj }` pip_parse.experimental_requirement_cycles ` and
72170 {bzl: obj }` pip_parse.use_hub_alias_dependencies ` together now works when
73171 using WORKSPACE files.
172+ * (pypi) The error messages when the wheel distributions do not match anything
173+ are now printing more details and include the currently active flag
174+ values. Fixes [ #2466 ] ( https://github.com/bazelbuild/rules_python/issues/2466 ) .
175+ * (py_proto_library) Fix import paths in Bazel 8.
176+ * (whl_library) Now the changes to the dependencies are correctly tracked when
177+ PyPI packages used in {bzl: obj }` whl_library ` during the ` repository_rule ` phase
178+ change. Fixes [ #2468 ] ( https://github.com/bazelbuild/rules_python/issues/2468 ) .
179+ + (gazelle) Gazelle no longer ignores ` setup.py ` files by default. To restore
180+ this behavior, apply the ` # gazelle:python_ignore_files setup.py ` directive.
181+ * Don't re-fetch whl_library, python_repository, etc. repository rules
182+ whenever ` PATH ` changes. Fixes
183+ [ #2551 ] ( https://github.com/bazelbuild/rules_python/issues/2551 ) .
74184
75185[ pep-695 ] : https://peps.python.org/pep-0695/
76186
77- {#v0-0 -0-added}
187+ {#v1-1 -0-added}
78188### Added
79189* (gazelle) Added ` include_stub_packages ` flag to ` modules_mapping ` . When set to ` True ` , this
80190 automatically includes corresponding stub packages for third-party libraries
@@ -85,8 +195,24 @@ Unreleased changes template.
85195 To select the free-threaded interpreter in the repo phase, please use
86196 the documented [ env] ( /environment-variables.html ) variables.
87197 Fixes [ #2386 ] ( https://github.com/bazelbuild/rules_python/issues/2386 ) .
88-
89- {#v0-0-0-removed}
198+ * (toolchains) Use the latest astrahl-sh toolchain release [ 20241206] for Python versions:
199+ * 3.9.21
200+ * 3.10.16
201+ * 3.11.11
202+ * 3.12.8
203+ * 3.13.1
204+ * (rules) Attributes for type definition files (` .pyi ` files) and type-checking
205+ only dependencies added. See {obj}` py_library.pyi_srcs ` and
206+ ` py_library.pyi_deps ` (and the same named attributes for ` py_binary ` and
207+ ` py_test ` ).
208+ * (pypi) pypi-generated targets set ` pyi_srcs ` to include ` *.pyi ` files.
209+ * (providers) {obj}` PyInfo ` has new fields to aid static analysis tools:
210+ {obj}` direct_original_sources ` , {obj}` direct_pyi_files ` ,
211+ {obj}` transitive_original_sources ` , {obj}` transitive_pyi_files ` .
212+
213+ [ 20241206 ] : https://github.com/astral-sh/python-build-standalone/releases/tag/20241206
214+
215+ {#v1-1-0-removed}
90216### Removed
91217* ` find_requirements ` in ` //python:defs.bzl ` has been removed.
92218
0 commit comments