changeset fb72868d013e in tryton:5.0
details: https://hg.tryton.org/tryton?cmd=changeset&node=fb72868d013e
description:
Freeze the content of tuple
The content of a tuple could be unhashable so it must also be frozen.
issue10603
review367321002
(grafted from ed3ce1fab2ab275e27f3e31e68156f2259eb9c84)
diffstat:
tryton/common/selection.py | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diffs (12 lines):
diff -r 845e52519918 -r fb72868d013e tryton/common/selection.py
--- a/tryton/common/selection.py Thu Jun 17 21:25:41 2021 +0200
+++ b/tryton/common/selection.py Fri Aug 06 09:30:06 2021 +0200
@@ -135,7 +135,7 @@
if isinstance(value, dict):
return tuple(sorted((k, freeze_value(v))
for k, v in value.items()))
- elif isinstance(value, (list, set)):
+ elif isinstance(value, (list, set, tuple)):
return tuple(freeze_value(v) for v in value)
else:
return value