Update Entity class to be compatible with the new Dataset entity
vpchung opened this issue · 0 comments
vpchung commented
One of the fields of the Dataset data model is named, items
, which coincides with a Python builtin: dict.items()
. This results in a TypeError
when trying to print a representation of the entity:
>>> dataset = syn.get("syn123")
>>> repr(dataset)
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/Users/vchung/Desktop/synapsePythonClient/synapseclient/entity.py", line 434, in __repr__
self.properties.items(),
TypeError: 'list' object is not callable
>>>
Looking at the Entity class, the __repr__()
should be updated as to not call on self.properties.items()
, as to not confuse Python what it is we want (key-value pairs of self.properties
vs. the actual property named items
).