Skip to content

Commit

Permalink
Read _venomx only if it exists
Browse files Browse the repository at this point in the history
  • Loading branch information
caufieldjh committed Oct 24, 2024
1 parent 0c756ed commit 4f991a3
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/curategpt/store/metadata.py
Original file line number Diff line number Diff line change
Expand Up @@ -46,8 +46,8 @@ def deserialize_venomx_metadata_from_adapter(cls, metadata_dict: dict, adapter:
"""
if adapter == 'chromadb':
# Deserialize '_venomx' (str) back into 'venomx' (dict)
venomx_json = metadata_dict.pop("_venomx")
if venomx_json:
if "_venomx" in metadata_dict:
venomx_json = metadata_dict.pop("_venomx")
metadata_dict["venomx"] = Index(**json.loads(venomx_json))
# for 'duckdb', 'venomx' remains as is
if adapter == 'duckdb':
Expand Down

0 comments on commit 4f991a3

Please sign in to comment.