2
0
mirror of https://github.com/frappe/bench.git synced 2025-02-13 16:28:32 +00:00

Merge pull request #1401 from frappe/p517

fix: install wheel in venv
This commit is contained in:
Ankush Menat 2022-12-12 13:26:10 +05:30 committed by GitHub
commit 2d0ba72ae3
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -361,6 +361,7 @@ class BenchSetup(Base):
self.run(f"{venv} env", cwd=self.bench.name)
self.pip()
self.wheel()
if os.path.exists(frappe):
self.run(
@ -398,6 +399,19 @@ class BenchSetup(Base):
f"{self.bench.python} -m pip install {quiet_flag} --upgrade pip", cwd=self.bench.name
)
@step(title="Installing wheel", success="Installed wheel")
def wheel(self, verbose=False):
"""Wheel is required for building old setup.py packages.
ref: https://github.com/pypa/pip/issues/8559"""
import bench.cli
verbose = bench.cli.verbose or verbose
quiet_flag = "" if verbose else "--quiet"
return self.run(
f"{self.bench.python} -m pip install {quiet_flag} wheel", cwd=self.bench.name
)
def logging(self):
from bench.utils import setup_logging