Skip to content
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 loading version from a file #1359

Merged
merged 1 commit into from May 15, 2018

Conversation

jmbowman
Copy link
Contributor

Proposed resolution for #1358. Adds support for using "file:" to load the package version from a text file. It strips any leading or trailing whitespace, since trailing newlines are pretty likely in such a file.

@warsaw
Copy link
Contributor

warsaw commented May 15, 2018

I haven't tried this on live code, but it looks nice!

@pganssle
Copy link
Member

I think I'm more or less fine with this, except that I think the resulting string should be more constrained.

Per discussion at PyCon sprints, we should just start by validating that it's a valid PEP 440 version, and if people complain about this restriction we can possibly add a mechanism for opting out.

@jmbowman jmbowman force-pushed the jmbowman/version_from_file branch from 7eeaa83 to a960ee1 Compare May 15, 2018 15:15
@jaraco jaraco merged commit e0fd60c into pypa:master May 15, 2018
@jmbowman jmbowman deleted the jmbowman/version_from_file branch May 15, 2018 20:29
jaraco pushed a commit to jaraco/cpython that referenced this pull request Feb 17, 2023
This support was added in (pypa/setuptools#1359), which
was quite a while ago, so I believe it is safe to use this feature now and
expect people to be able to process this metadata format.
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.

None yet

5 participants