Fix Synapse git info missing in version strings (#12973)

This commit is contained in:
David Robertson 2022-06-07 15:24:11 +01:00 committed by GitHub
parent a7e506ddee
commit f30bcbd84a
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
15 changed files with 36 additions and 38 deletions

View file

@ -19,6 +19,7 @@ from typing import Any, Callable, Dict, Generator, Optional
import attr
from frozendict import frozendict
from matrix_common.versionstring import get_distribution_version_string
from twisted.internet import defer, task
from twisted.internet.defer import Deferred
@ -183,3 +184,8 @@ def log_failure(
if not consumeErrors:
return failure
return None
# Version string with git info. Computed here once so that we don't invoke git multiple
# times.
SYNAPSE_VERSION = get_distribution_version_string("matrix-synapse", __file__)