From 6b16ad90d10a60df40e3b9e3299639c086a4d9d5 Mon Sep 17 00:00:00 2001 From: Massimiliano Pippi Date: Fri, 1 Mar 2024 12:57:03 +0100 Subject: [PATCH 1/4] release chroma on python 3.8 --- integrations/chroma/pyproject.toml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/integrations/chroma/pyproject.toml b/integrations/chroma/pyproject.toml index f8265a1e7..90e037942 100644 --- a/integrations/chroma/pyproject.toml +++ b/integrations/chroma/pyproject.toml @@ -7,7 +7,7 @@ name = "chroma-haystack" dynamic = ["version"] description = '' readme = "README.md" -requires-python = ">=3.9" +requires-python = ">=3.8" license = "Apache-2.0" keywords = [] authors = [ @@ -16,6 +16,7 @@ authors = [ classifiers = [ "Development Status :: 4 - Beta", "Programming Language :: Python", + "Programming Language :: Python :: 3.8", "Programming Language :: Python :: 3.9", "Programming Language :: Python :: 3.10", "Programming Language :: Python :: 3.11", From 5662a87bebf2a786b05ac8d3467fdda0a7eeebfd Mon Sep 17 00:00:00 2001 From: Massimiliano Pippi Date: Fri, 1 Mar 2024 13:00:28 +0100 Subject: [PATCH 2/4] also run tests on 3.8 --- .github/workflows/chroma.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/chroma.yml b/.github/workflows/chroma.yml index b7f158cfe..fec309f6b 100644 --- a/.github/workflows/chroma.yml +++ b/.github/workflows/chroma.yml @@ -30,7 +30,7 @@ jobs: fail-fast: false matrix: os: [ubuntu-latest, windows-latest, macos-latest] - python-version: ['3.9', '3.10'] + python-version: ['3.8', '3.9', '3.10'] steps: - name: Support longpaths From da51e147694c979b3fb8465b1e577e991feddcbd Mon Sep 17 00:00:00 2001 From: anakin87 Date: Fri, 1 Mar 2024 13:09:31 +0100 Subject: [PATCH 3/4] fix test --- .../document_stores/chroma/document_store.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/integrations/chroma/src/haystack_integrations/document_stores/chroma/document_store.py b/integrations/chroma/src/haystack_integrations/document_stores/chroma/document_store.py index 1dbeddbd3..88376e8c2 100644 --- a/integrations/chroma/src/haystack_integrations/document_stores/chroma/document_store.py +++ b/integrations/chroma/src/haystack_integrations/document_stores/chroma/document_store.py @@ -315,7 +315,7 @@ def _normalize_filters(filters: Dict[str, Any]) -> Tuple[List[str], Dict[str, An for k in keys_to_remove: del filters[k] - final_where = dict(filters | where) + final_where = dict(filters | dict(where)) try: if final_where: validate_where(final_where) From 8877137e412a8cec8d0e0a5e43b8cb54aa77541c Mon Sep 17 00:00:00 2001 From: anakin87 Date: Fri, 1 Mar 2024 13:17:36 +0100 Subject: [PATCH 4/4] retry wo pipe --- .../document_stores/chroma/document_store.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/integrations/chroma/src/haystack_integrations/document_stores/chroma/document_store.py b/integrations/chroma/src/haystack_integrations/document_stores/chroma/document_store.py index 88376e8c2..4201de23b 100644 --- a/integrations/chroma/src/haystack_integrations/document_stores/chroma/document_store.py +++ b/integrations/chroma/src/haystack_integrations/document_stores/chroma/document_store.py @@ -315,7 +315,8 @@ def _normalize_filters(filters: Dict[str, Any]) -> Tuple[List[str], Dict[str, An for k in keys_to_remove: del filters[k] - final_where = dict(filters | dict(where)) + final_where = dict(filters) + final_where.update(dict(where)) try: if final_where: validate_where(final_where)