Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use pep 503 compatible wheels index for builds #618

Merged
merged 1 commit into from
Sep 30, 2023
Merged
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
2 changes: 1 addition & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ RUN \
&& pip3 install --no-cache-dir \
-r /usr/src/requirements.txt \
-r /usr/src/requirements_${CPYTHON_ABI}.txt \
--find-links "https://wheels.home-assistant.io/musllinux/" \
--extra-index-url "https://wheels.home-assistant.io/musllinux-index/" \
&& rm -rf /usr/src/*

# Install auditwheel
Expand Down
2 changes: 1 addition & 1 deletion builder/infra.py
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ def create_wheels_folder(base_folder: Path) -> Path:

def create_wheels_index(base_index: str) -> str:
"""Create wheels specific URL."""
return f"{base_index}/{_MUSLLINUX}/"
return f"{base_index}/{_MUSLLINUX}-index/"


def create_package_map(packages: List[str]) -> Dict[str, AwesomeVersion]:
Expand Down
8 changes: 4 additions & 4 deletions builder/pip.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ def build_wheels_package(
constraint_cmd = f"--constraint {constraint}" if constraint else ""

run_command(
f'pip3 wheel --disable-pip-version-check --progress-bar off --no-clean --no-binary "{skip_binary}" --wheel-dir {output} --find-links {index} {constraint_cmd} "{package}"',
f'pip3 wheel --disable-pip-version-check --progress-bar off --no-clean --no-binary "{skip_binary}" --wheel-dir {output} --extra-index-url {index} {constraint_cmd} "{package}"',
env=build_env,
timeout=timeout,
)
Expand Down Expand Up @@ -54,7 +54,7 @@ def build_wheels_requirement(
legacy_cmd = "--use-deprecated=legacy-resolver" if legacy else ""

run_command(
f'pip3 wheel --disable-pip-version-check --progress-bar off {legacy_cmd} --no-clean --no-binary "{skip_binary}" --wheel-dir {output} --find-links {index} {constraint_cmd} --requirement {requirement}',
f'pip3 wheel --disable-pip-version-check --progress-bar off {legacy_cmd} --no-clean --no-binary "{skip_binary}" --wheel-dir {output} --extra-index-url {index} {constraint_cmd} --requirement {requirement}',
env=build_env,
timeout=timeout,
)
Expand All @@ -72,7 +72,7 @@ def build_wheels_local(
build_env["MAKEFLAGS"] = f"-j{cpu}"

run_command(
f"pip3 wheel --disable-pip-version-check --progress-bar off --no-clean --wheel-dir {output} --find-links {index} .",
f"pip3 wheel --disable-pip-version-check --progress-bar off --no-clean --wheel-dir {output} --extra-index-url {index} .",
env=build_env,
)

Expand Down Expand Up @@ -123,5 +123,5 @@ def install_pips(index: str, pips: str) -> None:
packages = " ".join(pips.split(";"))

run_command(
f"pip install --disable-pip-version-check --progress-bar off --upgrade --no-cache-dir --prefer-binary --find-links {index} {packages}",
f"pip install --disable-pip-version-check --progress-bar off --upgrade --no-cache-dir --prefer-binary --extra-index-url {index} {packages}",
)