diff options
author | Erik Johnston <erik@matrix.org> | 2015-04-07 12:08:35 +0100 |
---|---|---|
committer | Erik Johnston <erik@matrix.org> | 2015-04-07 12:08:35 +0100 |
commit | 0af5f5efaf0b24187514cf78d7982ef9b85a208c (patch) | |
tree | 5f1b40032b349e5743af333124d6fcea0b5213e0 /synapse/storage/_base.py | |
parent | Implement or_ignore flag on inserts (diff) | |
download | synapse-0af5f5efaf0b24187514cf78d7982ef9b85a208c.tar.xz |
Don't use multiple UNIQUE constraints; it will cause deadlocks
Diffstat (limited to 'synapse/storage/_base.py')
-rw-r--r-- | synapse/storage/_base.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/synapse/storage/_base.py b/synapse/storage/_base.py index a0c1718c27..4ac61be895 100644 --- a/synapse/storage/_base.py +++ b/synapse/storage/_base.py @@ -837,11 +837,11 @@ class SQLBaseStore(object): return curr_time logger.debug("Got js: %r", js) - d = json.loads(js) + d = json.loads(str(js).decode("utf8")) start_time = update_counter("decode_json", start_time) logger.debug("Got internal_metadata: %r", internal_metadata) - internal_metadata = json.loads(internal_metadata) + internal_metadata = json.loads(str(internal_metadata).decode("utf8")) start_time = update_counter("decode_internal", start_time) ev = FrozenEvent(d, internal_metadata_dict=internal_metadata) |