Coverage for /pythoncovmergedfiles/medio/medio/usr/local/lib/python3.11/site-packages/nameparser/_version.py: 75%

Shortcuts on this page

r m x   toggle line displays

j k   next/prev highlighted chunk

0   (zero) top of page

1   (one) first highlighted chunk

4 statements  

1#: Release version parts (major, minor, micro). VERSION stays a pure 

2#: numeric tuple so `nameparser.VERSION >= (2, 0, 0)` keeps working; the 

3#: pre-release segment lives separately. 

4#: 

5#: Bumped when a cycle OPENS, not when it ships, so the tree says what 

6#: it is building. Note the cost of the tuple being purely numeric: it 

7#: cannot carry the dev marker, so `VERSION >= (2, 4, 0)` is already 

8#: true here while 2.4.0 is unreleased. Compare `__version__` instead 

9#: where that distinction matters. 

10VERSION = (2, 4, 0) 

11#: PEP 440 pre-release/dev segment appended to the numeric version, or 

12#: "" for a final release. Joined WITHOUT a dot ("2.0.0rc1", not 

13#: "2.0.0.rc1"); setuptools reads __version__ as the package version. 

14#: 

15#: "dev" through the cycle, cleared at release. It normalizes to 

16#: 2.4.0.dev0, which sorts above 2.3.0 and BELOW 2.4.0, so an install 

17#: from master can never masquerade as the release it precedes. 

18PRE_RELEASE = "dev" 

19__version__ = ".".join(map(str, VERSION)) + PRE_RELEASE