summary refs log tree commit diff
path: root/synapse/_scripts/update_synapse_database.py
diff options
context:
space:
mode:
authorDavid Robertson <davidr@element.io>2022-06-07 15:24:11 +0100
committerGitHub <noreply@github.com>2022-06-07 15:24:11 +0100
commitf30bcbd84a651de59777b2a749850f6ca56ce3f0 (patch)
tree8a66fdf82df9a061ca9664b214d23145ee178e1b /synapse/_scripts/update_synapse_database.py
parentReduce amount of state we pull out when attempting to send catchup PDUs. (#12... (diff)
downloadsynapse-f30bcbd84a651de59777b2a749850f6ca56ce3f0.tar.xz
Fix Synapse git info missing in version strings (#12973)
Diffstat (limited to 'synapse/_scripts/update_synapse_database.py')
-rwxr-xr-xsynapse/_scripts/update_synapse_database.py5
1 files changed, 2 insertions, 3 deletions
diff --git a/synapse/_scripts/update_synapse_database.py b/synapse/_scripts/update_synapse_database.py
index c443522c05..b4aeae6dd5 100755
--- a/synapse/_scripts/update_synapse_database.py
+++ b/synapse/_scripts/update_synapse_database.py
@@ -19,7 +19,6 @@ import sys
 from typing import cast
 
 import yaml
-from matrix_common.versionstring import get_distribution_version_string
 
 from twisted.internet import defer, reactor as reactor_
 
@@ -28,6 +27,7 @@ from synapse.metrics.background_process_metrics import run_as_background_process
 from synapse.server import HomeServer
 from synapse.storage import DataStore
 from synapse.types import ISynapseReactor
+from synapse.util import SYNAPSE_VERSION
 
 # Cast safety: Twisted does some naughty magic which replaces the
 # twisted.internet.reactor module with a Reactor instance at runtime.
@@ -43,8 +43,7 @@ class MockHomeserver(HomeServer):
             hostname=config.server.server_name,
             config=config,
             reactor=reactor,
-            version_string="Synapse/"
-            + get_distribution_version_string("matrix-synapse"),
+            version_string=f"Synapse/{SYNAPSE_VERSION}",
         )