summary refs log tree commit diff
path: root/synapse/storage/engines
diff options
context:
space:
mode:
authorDavid Robertson <davidr@element.io>2022-12-12 21:25:07 +0000
committerGitHub <noreply@github.com>2022-12-12 21:25:07 +0000
commit3d87847ecc943c689c4587c5327d744e4a8f92c2 (patch)
tree376b5e4eecb94e0fe75272cf78be7235f307d54a /synapse/storage/engines
parentFix missing cache invalidation in application service code (#14670) (diff)
downloadsynapse-3d87847ecc943c689c4587c5327d744e4a8f92c2.tar.xz
Enable `--warn-redundant-casts` option in mypy (#14671)
* Enable `--warn-redundant-casts` option in mypy

Doesn't do much but helps me sleep better at night.

* Changelog

* Fix name of the ignore

* Fix one more missed cast

Not sure why I didn't see this one locally, maybe I needed a poetry update

* Remove old comment

Co-authored-by: Patrick Cloke <clokep@users.noreply.github.com>

Co-authored-by: Patrick Cloke <clokep@users.noreply.github.com>
Diffstat (limited to 'synapse/storage/engines')
-rw-r--r--synapse/storage/engines/postgres.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/synapse/storage/engines/postgres.py b/synapse/storage/engines/postgres.py
index 719a517336..f9f562ea45 100644
--- a/synapse/storage/engines/postgres.py
+++ b/synapse/storage/engines/postgres.py
@@ -77,7 +77,7 @@ class PostgresEngine(
         # docs: The number is formed by converting the major, minor, and
         # revision numbers into two-decimal-digit numbers and appending them
         # together. For example, version 8.1.5 will be returned as 80105
-        self._version = cast(int, db_conn.server_version)
+        self._version = db_conn.server_version
         allow_unsafe_locale = self.config.get("allow_unsafe_locale", False)
 
         # Are we on a supported PostgreSQL version?