summary refs log tree commit diff
path: root/synapse/storage
diff options
context:
space:
mode:
authorDavid Robertson <davidr@element.io>2021-09-14 11:25:05 +0100
committerGitHub <noreply@github.com>2021-09-14 11:25:05 +0100
commit319b8b6bef1a8666b9ef57dfea5030da0e1effc2 (patch)
tree616a399d8ad06039911ca6b12dc18ca5d4f0badd /synapse/storage
parentUse direct references for some configuration variables (#10798) (diff)
downloadsynapse-319b8b6bef1a8666b9ef57dfea5030da0e1effc2.tar.xz
Name the type of token in "Invalid token" messages (#10815)
I had one of these error messages yesterday and assumed it was an
invalid auth token (because that was an HTTP query parameter in the
test) I was working on. In fact, it was an invalid next batch token for
syncing.
Diffstat (limited to 'synapse/storage')
-rw-r--r--synapse/storage/relations.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/synapse/storage/relations.py b/synapse/storage/relations.py
index c552dbf04c..10a46b5e82 100644
--- a/synapse/storage/relations.py
+++ b/synapse/storage/relations.py
@@ -73,7 +73,7 @@ class RelationPaginationToken:
             t, s = string.split("-")
             return RelationPaginationToken(int(t), int(s))
         except ValueError:
-            raise SynapseError(400, "Invalid token")
+            raise SynapseError(400, "Invalid relation pagination token")
 
     def to_string(self) -> str:
         return "%d-%d" % (self.topological, self.stream)
@@ -103,7 +103,7 @@ class AggregationPaginationToken:
             c, s = string.split("-")
             return AggregationPaginationToken(int(c), int(s))
         except ValueError:
-            raise SynapseError(400, "Invalid token")
+            raise SynapseError(400, "Invalid aggregation pagination token")
 
     def to_string(self) -> str:
         return "%d-%d" % (self.count, self.stream)