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

pip, wheel, setuptools: Make wheels available in SAGE_SPKG_WHEELS #31045

Closed
mkoeppe opened this issue Dec 12, 2020 · 15 comments
Closed

pip, wheel, setuptools: Make wheels available in SAGE_SPKG_WHEELS #31045

mkoeppe opened this issue Dec 12, 2020 · 15 comments

Comments

@mkoeppe
Copy link
Member

mkoeppe commented Dec 12, 2020

From #30913:

Currently, pip, wheel, and setuptools are installed without making wheels available in SAGE_SPKG_WHEELS.

In this ticket, we make wheels available in SAGE_SPKG_WHEELS. For the case of setuptools, we create a new spkg setuptools_wheel that takes care of it (it depends on wheel).

This is so that after installation, we have a complete set of wheels for all Python packages installed by the Sage distribution. This allows users to create a venv by installing a compatible set of wheels (whose compiled extensions use the configured libraries in SAGE_LOCAL and the system). The most robust way of doing so is by disabling the use of PyPI (pip install --no-index) so that no incompatible wheels can leak in. (This can be tested using #30913.)

As PEP 517 packages (packages with a pyproject.toml, such as pplpy) are built using build isolation (without access to already installed packages), they need access to their build system packages such as wheel and setuptools. When use of PyPI is disabled, this relies on distributions (either source or wheel) to be available otherwise. On this ticket, we make them available as wheels. (We make pip available as a wheel for completeness.)

CC: @videlec @tobiasdiez @jhpalmieri @kliem

Component: build

Author: Matthias Koeppe

Branch/Commit: 1d19802

Reviewer: John Palmieri

Issue created by migration from https://trac.sagemath.org/ticket/31045

@mkoeppe mkoeppe added this to the sage-9.3 milestone Dec 12, 2020
@mkoeppe

This comment has been minimized.

@mkoeppe
Copy link
Member Author

mkoeppe commented Jan 23, 2021

@mkoeppe

This comment has been minimized.

@mkoeppe
Copy link
Member Author

mkoeppe commented Jan 23, 2021

Author: Matthias Koeppe

@mkoeppe
Copy link
Member Author

mkoeppe commented Jan 23, 2021

New commits:

1d19802Build and store wheels for setuptools, pip, wheel

@mkoeppe
Copy link
Member Author

mkoeppe commented Jan 23, 2021

Commit: 1d19802

@mkoeppe mkoeppe changed the title pip, wheel, setuptools: Make wheels or source archives available in SAGE_SPKG_WHEELS pip, wheel, setuptools: Make wheels available in SAGE_SPKG_WHEELS Jan 23, 2021
@tobiasdiez
Copy link
Contributor

comment:4

Just out of interest, what is the use case behind "when we don't allow use of PyPI.", i.e. why would you want to do this?

@mkoeppe
Copy link
Member Author

mkoeppe commented Jan 23, 2021

comment:5

Mainly it's a way to guarantee a fully functional build using only the given version constraints (in install-requires and pyprojects.toml).

@mkoeppe
Copy link
Member Author

mkoeppe commented Feb 2, 2021

comment:6

Critical for completing the goal of user-defined venvs in Sage 9.3.

@mkoeppe

This comment has been minimized.

@mkoeppe
Copy link
Member Author

mkoeppe commented Feb 24, 2021

comment:9

Expanded the description, needs review

@jhpalmieri
Copy link
Member

Reviewer: John Palmieri

@jhpalmieri
Copy link
Member

comment:10

This looks okay to me.

@mkoeppe
Copy link
Member Author

mkoeppe commented Feb 26, 2021

comment:11

Thank you!

@vbraun
Copy link
Member

vbraun commented Mar 7, 2021

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants