-
Notifications
You must be signed in to change notification settings - Fork 23
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix issue with packaging.parse throwing InvalidVersion in the upgrade…
…_config() function when trying to parse the informational version string VERSION set by bdbag when it is running in a "frozen" (e.g., with cx_Freeze) environment. In such cases, VERSION is set to something like 1.7.1-frozen, which is not PEP-440 compliant. This was not an issue in previous releases due to the fact that the implementation used pkg_resources.parse_version which was not as strict. The code in upgrade_config() has been changed to parse the PEP-440 compliant version returned by packaging.parse rather than use the global string VERSION, which can still be (and is) used elsewhere for purely informational and descriptive purposes. Unfortunately this wasn't caught be unit testing before the release because of the complexity of unit testing pre-built frozen environments. It wasn't until other automation that freezes `bdbag` into a pre-built installable software package generated an installer that was tested manually did it get exposed.
- Loading branch information
Showing
3 changed files
with
20 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters