File tree Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change 33import uuid
44from collections import defaultdict
55from copy import copy
6- from pprint import pformat
6+ from pprint import saferepr
77
88from django .conf .urls import url
99from django .db import connections
@@ -151,10 +151,10 @@ def similar_key(query):
151151
152152 def duplicate_key (query ):
153153 raw_params = () if query ['raw_params' ] is None else tuple (query ['raw_params' ])
154- # pformat () avoids problems because of unhashable types
154+ # saferepr () avoids problems because of unhashable types
155155 # (e.g. lists) when used as dictionary keys.
156156 # https://github.com/jazzband/django-debug-toolbar/issues/1091
157- return (query ['raw_sql' ], pformat (raw_params ))
157+ return (query ['raw_sql' ], saferepr (raw_params ))
158158
159159 if self ._queries :
160160 width_ratio_tally = 0
You can’t perform that action at this time.
0 commit comments