> the version constraints of the packages that happen to be build dependencies of the Sage library (enumerated in https://github.com/sagemath/sage/blob/develop/bootstrap#L36) are set in https://github.com/sagemath/sage/blob/develop/src/pyproject.toml#L3Right (adhering to the standard of modern python libs)> The tighter version constraints are needed by the Sage distributionThen please specify these version constraints in sage distribution and not in sage-lib (eg by providing a version_constraint.txt file that is compatible with the version constraints of sage-lib and the tighter constraints set by other packages).
> The tighter version constraints are needed by the Sage distributionThen please specify these version constraints in sage distribution and not in sage-lib (eg by providing a version_constraint.txt file that is compatible with the version constraints of sage-lib and the tighter constraints set by other packages).
People interested in maintaining sagelib should only care about the version constraint in the pyproject.toml file (e.g. if they decide that a new feature of numpy is needed, then the version constraint of numpy should be changed accordingly).
I don't think *you* would need to maintain that set. It would just be something to maintained.
Why would one want to specify a more narrow version range?
The cython constraint in scipy is for build-time. Sagelib only cares about the fact that scipy is installed in the same venv, not how you install or build it. In fact, pip uses build isolation by default, or you may install scipy using the prebuilt wheel from pypi, or you use conda. In neither of these cases, would sagelib ever even see the cython used to build scipy. It's a sage-the-distro specific problem, since this distribution insists that you need to be able to compile sagelib with the same cython version as scipy.
Moreover, there is actually a very simple way to specify a different constraint for sage-the-distro: just remove the auto-gen of the version-requirements file, and provide an own one for sage-the-distro.
Moreover, there is actually a very simple way to specify a different constraint for sage-the-distro: just remove the auto-gen of the version-requirements file, and provide an own one for sage-the-distro.That way was discussed in https://github.com/sagemath/sage/pull/37902#discussion_r1744898150.
I've set the PR back to needs work since the version constraints in pyproject.toml for cython and numpy are not needed in my testing, definitely not for sage-the-lib but apparently not even for sage-the-distro (at least I didn't get any build errors without them).
The PR does not include any explanation as to why the changes to pyproject.toml are necessary, nor does it provide any guidance on how to test them. I used the standard configure process (now also with the system-site-packages switch) followed by make, both with and without these changes, and observed no visible differences. Could you please clarify how to observe the impact of the 'numpy >=1.22.4' constraint? Additionally, the comment preceding it is quite confusing, especially since this file actually lists "numpy>=2.0.0rc1,<2.3".
If the only apparent effect of these constraints is related to the system-site-package feature, I would appreciate feedback from the developers working on this feature (Dima?, Michael?) regarding how to specify these constraints now that sage-lib defines its own constraints in pyproject.toml.
To avoid further delaying the package upgrades in this PR, I am okay with reverting the changes to pyproject.toml for now and revisiting them once the discussion is concluded.
The PR does not include any explanation as to why the changes to pyproject.toml are necessary, nor does it provide any guidance on how to test them.
I used the standard configure process (now also with the system-site-packages switch) followed by make, both with and without these changes, and observed no visible differences. Could you please clarify how to observe the impact of the 'numpy >=1.22.4' constraint? Additionally, the comment preceding it is quite confusing, especially since this file actually lists "numpy>=2.0.0rc1,<2.3".
If the only apparent effect of these constraints is related to the system-site-package feature,
I would appreciate feedback from the developers working on this feature (Dima?, Michael?) regarding how to specify these constraints now that sage-lib defines its own constraints in pyproject.toml.
To avoid further delaying the package upgrades in this PR, I am okay with reverting the changes to pyproject.toml for now and revisiting them once the discussion is concluded.
On Sun, 2024-09-22 at 20:05 -0700, 'Tobia...@gmx.de' via sage-devel
wrote:
> Matthias claims these
> are needed for the system-site-package feature.
--enable-system-site-packages doesn't care about pyproject.toml
the
version_requirements.txt for the sage distribution should contain the
version requirements for the sage distribution. That's what they're
for