Skip to content

Commit 95ffab9

Browse files
Merge pull request #623 from Labelbox/kkim/refresh-ontology
[AL-0] Call refresh_ontology() for create/update/delete metadata
2 parents 91bf802 + f2ece6d commit 95ffab9

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

labelbox/schema/data_row_metadata.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -366,6 +366,7 @@ def delete_schema(self, name: str) -> bool:
366366
res = self._client.execute(query, {'where': {
367367
'id': schema.uid
368368
}})['deleteCustomMetadataSchema']
369+
self.refresh_ontology()
369370

370371
return res['success']
371372

@@ -642,6 +643,7 @@ def _upsert_schema(
642643
res = self._client.execute(
643644
query, {"data": upsert_schema.dict(exclude_none=True)
644645
})['upsertCustomMetadataSchema']
646+
self.refresh_ontology()
645647
return _parse_metadata_schema(res)
646648

647649
def _parse_upsert(

0 commit comments

Comments
 (0)