You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
classProvRecord(object):
def__init__(self, bundle, identifier, attributes=None):
...
self._attributes=defaultdict(set)
...
defget_attribute(self, attr_name):
""" Returns the attribute of the given name. :param attr_name: Name of the attribute. :return: Tuple (name, value) """attr_name=self._bundle.valid_qualified_name(attr_name)
returnself._attributes[attr_name]
The doc string implies, that get_attribute returns a tuple containing the attribute name aswell as its value.
In practice get_attribute always returns a set. Is this intended behaviour?
I was searching for a method that would return the attribute tuple or its value for a given attribute name.
I did not expect to retrieve a set.
The text was updated successfully, but these errors were encountered:
The doc string implies, that
get_attribute
returns a tuple containing the attribute name aswell as its value.In practice
get_attribute
always returns a set. Is this intended behaviour?I was searching for a method that would return the attribute tuple or its value for a given attribute name.
I did not expect to retrieve a set.
The text was updated successfully, but these errors were encountered: