Skip to content

Commit 55dfdfb

Browse files
committed
Add empty attributes list by default on KG nodes and subclass_of edges
1 parent 4b81f9b commit 55dfdfb

1 file changed

Lines changed: 5 additions & 1 deletion

File tree

cohd/cohd_trapi_15.py

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1254,6 +1254,9 @@ def _make_kg_node(name: Optional[str] = None, categories: Optional[List[str]] =
12541254
if categories is None:
12551255
categories = list()
12561256

1257+
if attributes is None:
1258+
attributes = list()
1259+
12571260
return {
12581261
'name': name,
12591262
'categories': categories,
@@ -1647,7 +1650,8 @@ def _add_kg_edge_subclass_of(self, descendant_node_id, ancestor_node_id):
16471650
'resource_role': 'aggregator_knowledge_source',
16481651
'upstream_resource_ids': [Ubergraph.INFORES_ID]
16491652
},
1650-
]
1653+
],
1654+
'attributes': []
16511655
}
16521656

16531657
def _initialize_trapi_response(self):

0 commit comments

Comments
 (0)