summary refs log tree commit diff
path: root/synapse/util/frozenutils.py
diff options
context:
space:
mode:
authorAndrew Morgan <andrew@amorgan.xyz>2020-10-20 18:29:12 +0100
committerAndrew Morgan <andrew@amorgan.xyz>2020-10-20 18:29:12 +0100
commit061b9895eb04349d862db7d15ca84bcd3b9911c7 (patch)
tree33a6c33f4f5f0c44f8676213392454b828763d45 /synapse/util/frozenutils.py
parentMerge commit '525efab61' into anoa/dinsic_release_1_21_x (diff)
parentMerge tag 'v1.20.0rc1' into develop (diff)
downloadsynapse-061b9895eb04349d862db7d15ca84bcd3b9911c7.tar.xz
Merge commit 'cca03dbec' into anoa/dinsic_release_1_21_x
* commit 'cca03dbec':
  fix typo
  s/fixes/fix/
  Directly import json from the standard library. (#8259)
  Allow for make_awaitable's return value to be re-used. (#8261)
  Rename 'populate_stats_process_rooms_2' background job back to 'populate_stats_process_rooms' again (#8243)
Diffstat (limited to 'synapse/util/frozenutils.py')
-rw-r--r--synapse/util/frozenutils.py5
1 files changed, 3 insertions, 2 deletions
diff --git a/synapse/util/frozenutils.py b/synapse/util/frozenutils.py

index 0e445e01d7..bf094c9386 100644 --- a/synapse/util/frozenutils.py +++ b/synapse/util/frozenutils.py
@@ -13,7 +13,8 @@ # See the License for the specific language governing permissions and # limitations under the License. -from canonicaljson import json +import json + from frozendict import frozendict @@ -66,5 +67,5 @@ def _handle_frozendict(obj): # A JSONEncoder which is capable of encoding frozendicts without barfing. # Additionally reduce the whitespace produced by JSON encoding. frozendict_json_encoder = json.JSONEncoder( - default=_handle_frozendict, separators=(",", ":"), + allow_nan=False, separators=(",", ":"), default=_handle_frozendict, )