<html><head><meta http-equiv="Content-Type" content="text/html charset=utf-8"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class=""><br class=""><div><blockquote type="cite" class=""><div class="">On Aug 31, 2017, at 11:41 AM, Chris Barker - NOAA Federal <<a href="mailto:chris.barker@noaa.gov" class="">chris.barker@noaa.gov</a>> wrote:</div><br class="Apple-interchange-newline"><div class=""><div class=""><blockquote type="cite" class="">that neither pip nor the setuptools backend should not change the tags<br class="">it applies to wheels by default).<br class=""></blockquote><br class="">I'm a bit confused -- are we talking about the backwards compatible<br class="">path to the future -- or the end-game?<br class=""><br class="">In short -- I'm sure we'll have to do some hacky stuff to keep<br class="">backwards compatibility, but the end game should be a clean separation<br class="">of concerns :<br class=""><br class="">Pip (or any front end) should never "build a wheel", and it certainly<br class="">shouldn't have to know enough about what's in a wheel to be re-naming<br class="">it for generic python vs cpython.<br class=""><br class="">The package manager should manage the package, not built it, or change it.<br class=""><br class="">Surely the build system should know how to correctly name the wheel it builds.<br class=""><br class="">As to using pip to build wheels -- there is good reason to do that<br class="">now, but in s post PEP 517 world, one would call the build system<br class="">directly to build a wheel-- after all, all pip should be  doing is<br class="">calling the build system anyway.<br class=""><br class=""></div></div></blockquote><br class=""></div><div><br class=""></div><div>Pip purposely overrides what setuptools tags the wheel with in order to make it extremely specific to the Python it is currently being run on. Now, a big part of why it needs to do this, is because a lot of setup.py were not written with wheel in mind, so they produce broken wheels by default.</div><div><br class=""></div><div>One such example is a setup.py that produces a pure Python wheel for PyPy, and a C-extension wheel for Python. If someone installs that project on PyPy first and they only have a sdist available on PyPI, then pip will cache a pure Python wheel for that project, and by default (without this bit to force it) that wheel would be acceptable for CPython too and would have been used instead of building a wheel with a compiled extension for CPython.</div><div class=""><br class=""></div>You could argue that the new crop of build backends should handle this better— and hopefully you’re correct— but I think that the two desires are at odd with one another. Most build backends are going to want to, by default, tag the wheel with as general of a tag as they think will work given the information available to them, whereas with pip’s internal wheel cache, we generally want that wheel to be as specific to the current version of Python as possible.<div class=""><br class=""></div><div class="">Another possible solution is to stop using the wheel tagging format to encode this information for pip’s internal wheel cache and to encode it into the path, so that instead of having PyPy and CPython share a cache directory, they each have their own. That isn’t an unreasonable mechanism for doing that and which one gets used is an implementation detail of pip.<br class=""><div class="">
<div style="color: rgb(0, 0, 0); font-family: Helvetica; font-style: normal; font-variant-ligatures: normal; font-variant-position: normal; font-variant-caps: normal; font-variant-numeric: normal; font-variant-alternates: normal; font-variant-east-asian: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-align: -webkit-auto; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-text-stroke-width: 0px; word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class=""><br class="">—<br class="">Donald Stufft<br class=""></div><div style="color: rgb(0, 0, 0); font-family: Helvetica; font-style: normal; font-variant-ligatures: normal; font-variant-position: normal; font-variant-caps: normal; font-variant-numeric: normal; font-variant-alternates: normal; font-variant-east-asian: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-align: -webkit-auto; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-text-stroke-width: 0px; word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class=""><br class=""></div><br class="Apple-interchange-newline">
</div>
<br class=""></div></body></html>