Skip to content

Fix old pkg_resources egg version normalization.#227

Closed
mikekap wants to merge 1 commit intopex-tool:masterfrom
mikekap:fix-versions
Closed

Fix old pkg_resources egg version normalization.#227
mikekap wants to merge 1 commit intopex-tool:masterfrom
mikekap:fix-versions

Conversation

@mikekap
Copy link
Contributor

@mikekap mikekap commented Apr 7, 2016

Before recent releases of setuptools, version numbers in egg filenames were mangled. safe_version handles this correctly in modern setuptools and should work on older setuptools as well.

Closes #226.

Before recent releases of setuptools, the version numbers in eggs were mangled. `safe_version` handles this correctly in modern `setuptools` and should work on older setuptools as well.

Closes pex-tool#226.
@ewang ewang mentioned this pull request Apr 20, 2016
@jsirois
Copy link
Member

jsirois commented Apr 20, 2016

The function at least goes back ~forever So LGTM:

jsirois@gill ~/dev/pypa/setuptools (master) $ git log -S"def safe_version"
commit 0c9e886999bb42cf825054778b1664e41f8164b4
Author: PJ Eby <distutils-sig@python.org>
Date:   Sun Jun 5 18:59:37 2005 +0000

    Add "safe_name" and "safe_version" functions to allow sanitizing of
    distribution names and versions in arbitrary packages that might be built
    using EasyInstall.

    --HG--
    branch : setuptools
    extra : convert_revision : svn%3A6015fed2-1504-0410-9fe1-9d1591cc4771/sandbox/trunk/setuptools%4041040

@jsirois
Copy link
Member

jsirois commented Apr 20, 2016

Thanks @mikekap and sorry for the delay reviewing this. Patched into master @ 4966afa

@jsirois jsirois closed this Apr 20, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants