File tree Expand file tree Collapse file tree 2 files changed +16
-0
lines changed
src/pip/_internal/operations/build Expand file tree Collapse file tree 2 files changed +16
-0
lines changed Original file line number Diff line number Diff line change
1
+ Deprecate the legacy ``setup.py bdist_wheel `` mechanism. To silence the warning,
2
+ and future-proof their setup, users should enable ``--use-pep517 `` or add a
3
+ ``pyproject.toml `` file to the projects they control.
Original file line number Diff line number Diff line change 3
3
from typing import List , Optional
4
4
5
5
from pip ._internal .cli .spinners import open_spinner
6
+ from pip ._internal .utils .deprecation import deprecated
6
7
from pip ._internal .utils .setuptools_build import make_setuptools_bdist_wheel_args
7
8
from pip ._internal .utils .subprocess import call_subprocess , format_command_args
8
9
@@ -68,6 +69,18 @@ def build_wheel_legacy(
68
69
69
70
Returns path to wheel if successfully built. Otherwise, returns None.
70
71
"""
72
+ deprecated (
73
+ reason = f"Building { name !r} using the legacy setup.py bdist_wheel mechanism." ,
74
+ replacement = (
75
+ "to use the standardized build interface by "
76
+ "setting the `--use-pep517` option, "
77
+ "(possibly combined with `--no-build-isolation`), "
78
+ "or adding a `pyproject.toml` file to the source tree"
79
+ ),
80
+ gone_in = "25.3" ,
81
+ issue = 6334 ,
82
+ )
83
+
71
84
wheel_args = make_setuptools_bdist_wheel_args (
72
85
setup_py_path ,
73
86
global_options = global_options ,
You can’t perform that action at this time.
0 commit comments