mirror of
https://github.com/alicevision/Meshroom.git
synced 2025-07-24 12:07:19 +02:00
[graph] Attribute: robust UIDs for list of elements as value
Fix variable UIDs for non-exclusive choices, which could be affected by different string encodings
This commit is contained in:
parent
7e2d37c819
commit
f1fdd34b6c
1 changed files with 3 additions and 2 deletions
|
@ -166,8 +166,9 @@ class Attribute(BaseObject):
|
|||
return hash(self._invalidationValue)
|
||||
if self.isLink:
|
||||
return self.getLinkParam().uid()
|
||||
if isinstance(self._value, basestring):
|
||||
return hash(str(self._value))
|
||||
if isinstance(self._value, (list, tuple, set,)):
|
||||
# hash of sorted values hashed
|
||||
return hash([hash(v) for v in sorted(self._value)])
|
||||
return hash(self._value)
|
||||
|
||||
@property
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue