Skip to content

Commit d43a0c2

Browse files
committed
fix: Handle association document versions 0.6.0 and 0.7.0 in guidelines store
The association schema hasn't changed since 0.5.0, but the document loader needs to handle the newer version strings. Signed-off-by: Laurits Søgaard Nielsen <lsn@werktoej.dk>
1 parent d513eb4 commit d43a0c2

1 file changed

Lines changed: 4 additions & 0 deletions

File tree

src/parlant/core/guidelines.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -379,6 +379,10 @@ async def _association_document_loader(
379379
if doc["version"] == "0.5.0":
380380
return cast(GuidelineTagAssociationDocument, doc)
381381

382+
# Handle versions 0.6.0+ - the association schema hasn't changed
383+
if doc["version"] in ("0.6.0", "0.7.0"):
384+
return cast(GuidelineTagAssociationDocument, doc)
385+
382386
return None
383387

384388
async def __aenter__(self) -> Self:

0 commit comments

Comments
 (0)