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
ConceptMap.explainables().ownerships() throws a Type error, but it doesn't have any arguments.
Environment
TypeDB distribution: Core
TypeDB version: 2.26.6-rc1
Environment: Mac
Studio version: -
Other details: Python driver 2.26.6-rc1
Reproducible Steps
Set up
define_query=""" define email sub attribute, value string; name sub attribute, value string; friendship sub relation, relates friend; user sub entity, owns email @key, owns name, plays friendship:friend; admin sub user; """define_query_rule=""" define rule users: when { $u isa user; } then { $u has name "User"; }; """insert_query=""" insert $user1 isa user, has name "Alice", has email "[email protected]"; $user2 isa user, has name "Bob", has email "[email protected]"; $friendship (friend:$user1, friend: $user2) isa friendship; """withdriver.session(DB_NAME, SessionType.DATA) assession:
withsession.transaction(TransactionType.READ, TypeDBOptions(infer=True, explain=True)) astransaction:
get_query=""" match $u isa user, has email $e, has name $n; $e contains 'Alice'; get $u, $n; """
Traceback (most recent call last):
File "/Users/vladimir/Documents/GitHub/typedb_python_driver_manual/main.py", line 230, in <module>
explainable_ownerships = ConceptMap.explainables().ownerships()
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/vladimir/Documents/GitHub/python_features_code_test/venv/lib/python3.11/site-packages/typedb/concept/answer/concept_map.py", line 139, in ownerships
return {key: self.ownership(*key)
^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/vladimir/Documents/GitHub/python_features_code_test/venv/lib/python3.11/site-packages/typedb/concept/answer/concept_map.py", line 139, in <dictcomp>
return {key: self.ownership(*key)
^^^^^^^^^^^^^^^^^^^^
TypeError: typedb.concept.answer.concept_map._ConceptMap.Explainables.ownership() argument after * must be an iterable, not StringPair
Description
ConceptMap.explainables().ownerships() throws a Type error, but it doesn't have any arguments.
Environment
Reproducible Steps
Expected result
Return Explainable for every ownership.
https://typedb.com/docs/drivers/python/api-reference#Explainables_ownerships_
Additional information
The text was updated successfully, but these errors were encountered: