returnn.__setup__
#
Used by setup.py.
- returnn.__setup__.parse_pkg_info(fn)[source]#
- Parameters:
fn (str) –
- Returns:
dict with info written by distutils. e.g.
res["Version"]
is the version.- Return type:
dict[str,str]
- returnn.__setup__.git_head_version(git_dir='/home/docs/checkouts/readthedocs.org/user_builds/returnn/checkouts/latest', long=False)[source]#
- Parameters:
git_dir (str) –
long (bool) – see
get_version_str()
- Return type:
str
- returnn.__setup__.get_version_str(verbose=False, verbose_error=False, fallback=None, long=False)[source]#
- Parameters:
verbose (bool) – print exactly how we end up with some version
verbose_error (bool) – print only any potential errors
fallback (str|None) –
long (bool) –
False: Always distutils.version.StrictVersion compatible. just like “1.20190202.154527”. True: Will also add the revision string, like “1.20180724.141845+git.7865d01”.
The format might change in the future. We will keep it SemVer compatible. I.e. the string before the “+” will be the short version. We always make sure that there is a “+” in the string.
- Return type:
str