Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 9 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,15 @@ END_UNRELEASED_TEMPLATE

{#v0-0-0-changed}
### Changed
* **DEPRECATED: implicit zipapp support**
* Implicit zipapp output of `py_binary`/`py_test` has been deprecated and
replaced by separate {obj}`py_zipapp_binary` and {obj}`py_zipapp_test`
rules. See
[#3567](https://github.com/bazel-contrib/rules_python/issues/3567)
for a detailed migration guide.
* (toolchains) stop exposing config settings in python toolchain alias repos.
Please consider depending on the flags defined in
`//python/config_setting/...` and the `@platforms` package instead.
* (binaries/tests) The `PYTHONBREAKPOINT` environment variable is automatically inherited
* (binaries/tests) The {obj}`stamp` attribute now transitions the Bazel builtin
{obj}`--stamp` flag.
Expand Down
15 changes: 15 additions & 0 deletions python/private/py_executable.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -379,6 +379,21 @@ def _create_executable(
# When --build_python_zip is enabled, then the zip file becomes
# one of the default outputs.
if build_zip_enabled:
# buildifier: disable=print
print(
"""
======================================================================
WARNING: Target: {}
The `--build_python_zip` flag and implicit zipapp output of `py_binary`
and `py_test` is deprecated and will be removed in a future release.
Switch to `py_zipapp_binary` or `py_zipapp_test`. For migration
instructions and guide, see:

https://github.com/bazel-contrib/rules_python/issues/3567
======================================================================
""".rstrip().format(ctx.label),
)

extra_default_outputs.append(zip_file)

# The logic here is a bit convoluted. Essentially, there are 3 types of
Expand Down