diff --git a/modules/statics.py b/modules/statics.py index d18d2e6..39a4ccb 100644 --- a/modules/statics.py +++ b/modules/statics.py @@ -72,8 +72,11 @@ def splash_logo() -> str: version = VERSION if "GITHUB" in version: - last_commit = subprocess.check_output(["git", "rev-parse", "HEAD"]).decode("utf-8").strip() - version = f"git-{last_commit[:7]}" + try: + last_commit = subprocess.check_output(["git", "rev-parse", "HEAD"]).decode("utf-8").strip() + version = f"git-{last_commit[:7]}" + except subprocess.SubprocessError: + version = "git-unknown-commit" return f""" {ASCII_ART} Version {version}, Python {sys.version}