-
-
Notifications
You must be signed in to change notification settings - Fork 90
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
Support for wheel 0.41.3 #207
Comments
Out of curiosity, is pinning to an older version causing any hardship for you? I'm just trying to understand the end-user impact of pinning versions in |
I'm packaging |
Bleh. Feel free to submit a PR that removes the version pinning from |
Comment from @rgommers on discuss.python.org:
|
I'm definitely not wrong there. Pins you see may be "doesn't work at all, hence we must pin", or "could leave this out on distros, but too unsafe to do for sdist uploaded to PyPI", or "pin is necessary for wheel builds due to some reason". The Regarding this issue, I don't have all the context but it seems similar. |
No, I'm not referring to other Python projects that use Similar pinning for build deps is rare and I think I'm not arguing about runtime pinning here. That's okay (even often overkill) and I understand why you want strict runtime pinning.
Likely I lack some knowledge here, but I do not understand why an end user would want to build sdist for anything serious. The sdist is created by the project and uploaded at PyPI for download. End user should just download the sdist (and create wheel from it, if he needs/wants). Overly strict pinning (to rule out versions that are not released yet) is preparation for incompatibility that you anticipate (or better: expect to happen soon) but such incompatibility may never materialize. |
That's not really how it works. When you type
What I wrote above is exactly why that pin was there. |
I think you wrote same as me just using different words :-).
Sure, yes. But you would have similar (or possibly even more serious) problem when you pin extensively. For example, when your pinned dependency have critical issue (e.g. security vulnerability). In any case, this is your project and I do not want to push you to do anything you do not want to do with it. I just reported something I think is a problem (even minor) and it is up to you how you'll deal with it. I can happily live with my patch for |
In general, pinning because of "guaranteed 100% reproducibility" is out of place in pyproject.toml -- which was not designed for it at all -- modulo "we are doing it anyway because it's not clear how to get cibuildwheel to build PyPI wheels with the ABI we want unless we pin it in pyproject.toml", which is understandable albeit still not technically correct. The numpy pin on setuptools was, in fact, correct -- because it defined an actual restriction that really existed. If numpy knows that it cannot and will not build with newer setuptools, there is nothing to discuss, because the version bound correctly communicates to end users (including both Pinning the version of wheel is not like this. The expectation is that new versions of wheel fix bugs, not add them, and it has no track record of making backwards-incompatible changes that require new sdist releases of downstream projects using wheel (either to adapt to the At worst, wheel releases a buggy version -- everyone reports bugs in it, and wheel fixes the bug and releases yet another version, one which fixes the bug, and then balance and harmony is restored to the world and everything works again -- still without pinning. The end result of including pinning in pyproject.toml is that downstream distributors are educated to believe that upstream cannot be trusted. Instead, they build with:
This does NOT mean that pinning is ignored. It means that the entire build-system.requires table is ignored. Here, too, balance and harmony is restored to the world. Effectively, we return to the pre-pep517 state of affairs, where builders were expected to manually handcraft a suitable build environment and if they failed, they got to keep both pieces. All that changed is that now instead of running |
Sadly, the current pinning approach is broken -- as all such attempts in pyproject.toml are inevitably doomed to be broken. The cffi dependency is pinned, but the environment is not actually reproducible -- because instead of freezing the environment with The correct solution here is to pass |
@eli-schwartz the I've been using this approach for over two years now: pypa/build#292 (comment). @indygreg I'm reading your last blog post now and see that you mentioned pip-tools. At the time of writing, there was a PR open implementing precisely what you wanted. I merged it 2 days after you post :) It took 13 months of reviews and the docs are here https://pip-tools.rtfd.io/#maximizing-reproducibility. Note that it's not yet released, though — it's only available in the main branch of pip-tools. But TL;DR — it produces a constraint file derived from what's in the I also have hints regarding other parts of your article, but this issue is probably not the right place to discuss that :) |
@eli-schwartz re:cibuildwheel -- see pypa/cibuildwheel#1666 / pypa/cibuildwheel#1683 / pypa/cibuildwheel#1675 for some of the related improvement efforts. Also see my ramblings regarding pinning differing env contexts: jazzband/pip-tools#1326 (comment) |
@mtelka @indygreg on a related note, |
@webknjaz thanks for clarifying! I knew that somewhere in this design space, constraints files were the right answer... but since I'm more accustomed to the distro tooling, we don't do pinning so I don't regularly do this and clearly misremembered it a bit. Also: thank you for (helping to) maintain pip-tools and bring a bit of sanity to the python packaging ecosystem. :) It is an absolutely fantastic project. |
Commit f90e2bb changed the |
@indygreg In fact, it moved into |
Partially. The issue was not really about whether it is a constraint vs a specific version. The real issue was that specific versions include "upper bound" constraints (as well as lower bound constraints); this adds a challenge to downstream redistributors who updated their setuptools version. Several upper bound constraints were removed in that commit, but one remains:
Redistributors may or may not be using --build-option, but if they are then they are dealing with it at scale across many packages, not specific to zstandard.
Granted if the goal is recursively pinning all packages that should be installed into an isolated build venv, then listing wheel would indeed be intentional... |
@eli-schwartz using the feature of pip-tools that I mentioned earlier, it's still possible to retrieve such additional/transitive deps for PEP 517 build env. |
I'll remove As for I want to use But days after that ordeal, setuptools broke I'm not sure how to even implement dynamic build backend features any more in a PEP 517 / |
It is a transitive dependency of setuptools. Since we gave up trying to have deterministic build environments, it doesn't serve much value. And it may make the lives of downstream packagers harder. So just remove it. Part of #207.
I think preferably you'd tell cibuildwheel to use |
zstandard 0.22.0
pinswheel
to0.41.2
, butwheel 0.41.3
is already out. Building withwheel==0.41.3
works well. Please update dependencies. Thank you.The text was updated successfully, but these errors were encountered: