File tree 3 files changed +15
-5
lines changed 3 files changed +15
-5
lines changed Original file line number Diff line number Diff line change
1
+ Deprecate installation with 'setup.py install' when the 'wheel' package is absent for
2
+ source distributions without 'pyproject.toml'.
Original file line number Diff line number Diff line change @@ -811,6 +811,18 @@ def install(
811
811
install_options = list (install_options ) + self .install_options
812
812
813
813
try :
814
+ if self .legacy_install_reason == 8559 :
815
+ deprecated (
816
+ reason = (
817
+ f"{ self .name } is being installed using the legacy "
818
+ f"'setup.py install' method, because it does not have a "
819
+ f"'pyproject.toml' and the 'wheel' package "
820
+ f"is not installed."
821
+ ),
822
+ replacement = "to enable the '--use-pep517' option" ,
823
+ gone_in = None ,
824
+ issue = 8559 ,
825
+ )
814
826
success = install_legacy (
815
827
install_options = install_options ,
816
828
global_options = global_options ,
Original file line number Diff line number Diff line change @@ -86,11 +86,7 @@ def _should_build(
86
86
87
87
if not is_wheel_installed ():
88
88
# we don't build legacy requirements if wheel is not installed
89
- logger .info (
90
- "Using legacy 'setup.py install' for %s, "
91
- "since package 'wheel' is not installed." ,
92
- req .name ,
93
- )
89
+ req .legacy_install_reason = 8559
94
90
return False
95
91
96
92
return True
You can’t perform that action at this time.
0 commit comments