Make setup.py compatible with older pythons

This caused some annoying downstream failures I'd rather not fix right now.
This commit is contained in:
Shane McDonald
2021-10-05 12:15:59 -04:00
parent fcdda8d7a7
commit f67a2d2f46
2 changed files with 4 additions and 2 deletions

View File

@@ -23,7 +23,8 @@ def use_scm_version():
def get_version_from_file():
if vf := version_file():
vf = version_file()
if vf:
with open(vf, 'r') as file:
return file.read().strip()