On 31 Oct, 2012, at 13:38, Daniel Holth <dholth@gmail.com> wrote:
On Wed, Oct 24, 2012 at 7:04 AM, Ronald Oussoren <ronaldoussoren@mac.com> wrote:
On 18 Oct, 2012, at 19:29, Daniel Holth <dholth@gmail.com> wrote:
I'd like to submit the Wheel PEPs 425 (filename metadata), 426 (Metadata 1.3), and 427 (wheel itself) for acceptance. The format has been stable since May and we are preparing a patch to support it in pip, but we need to earn consensus before including it in the most widely used installer.
PEP 425:
* "The version is py_version_nodot. CPython gets away with no dot, but if one is needed the underscore _ is used instead"
I don't particularly like replacing dots by underscores. That needed because you use the dot character in compressed tag sets, but why not use a comma to separate items in the compressed tag set?
* "The platform tag is simply distutils.util.get_platform() with all hyphens - and periods . replaced with underscore _."
Why the replacement? The need for replacement could be avoided by using a different separator between elements of a tag (for example "~" or "+"), and furthermore the platform tag is at a know location, and hence the use of hyphens in the platform tag is harmless (use "python_tag, abi_tag, platform_tag = tag.split('-', 2)" to split the tag into its elements.
* "compressed tag sets"
Using '"," instead of "." to separate elements of the tag set takes away the need to replace dots in tag elements, and seems more natural to me (you'd also use comma to separate the elements when you write them down in prose or python code.
I can't get excited about changing the convention. The hyphen-to-underscore folding and - separated file parts is the same as what setuptools uses. _ folding for . as well in the compat tags? It may not be beautiful but it is very unlikely to cause ambiguity.
Beauty is also important. BTW. Setuptools does not fold '-' to underscore in the tag: xs_image-1.0-py2.7-linux-x86_64.egg This would be "xs_image-1.0-cp27-cp27-linux_x86_64.whl" in your scheme (a binary package for CPython 2.7, platform is Linux x86_64). Replacing characters is especially ugly on OSX, compare "xs_image-1.0-cp27-cp27-macosx_10_3_fat.whl" and "xs_image-1.0-cp27-cp27-macosx-10.3-fat.whl". As I've written before, it is not necessary to replace characters in the platform tag because it is the last part of the filename anyway. Ronald