Fix contrib/graph/graph2.py to handle FrozenDict

This commit is contained in:
Erik Johnston 2015-02-16 13:15:41 +00:00
parent 8a59915d7d
commit a5ad6f862c
1 changed files with 2 additions and 1 deletions

View File

@ -21,6 +21,7 @@ import datetime
import argparse import argparse
from synapse.events import FrozenEvent from synapse.events import FrozenEvent
from synapse.util.frozenutils import unfreeze
def make_graph(db_name, room_id, file_prefix, limit): def make_graph(db_name, room_id, file_prefix, limit):
@ -70,7 +71,7 @@ def make_graph(db_name, room_id, file_prefix, limit):
float(event.origin_server_ts) / 1000 float(event.origin_server_ts) / 1000
).strftime('%Y-%m-%d %H:%M:%S,%f') ).strftime('%Y-%m-%d %H:%M:%S,%f')
content = json.dumps(event.get_dict()["content"]) content = json.dumps(unfreeze(event.get_dict()["content"]))
label = ( label = (
"<" "<"