From cb999d4457051ab9a188d33030a9de65ebcab338 Mon Sep 17 00:00:00 2001 From: Trayan Azarov Date: Wed, 23 Aug 2023 11:32:06 +0300 Subject: [PATCH 1/4] fix: CIP-2 Auth Providers - Updated logger level --- chromadb/auth/registry.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/chromadb/auth/registry.py b/chromadb/auth/registry.py index cebf6667175..7e844753199 100644 --- a/chromadb/auth/registry.py +++ b/chromadb/auth/registry.py @@ -1,7 +1,7 @@ import importlib import logging import pkgutil -from typing import Union, Dict, Type, Callable +from typing import Union, Dict, Type, Callable # noqa: F401 from chromadb.auth import ( ClientAuthConfigurationProvider, @@ -47,7 +47,7 @@ def register_provider( short_hand: str, ) -> Callable[[Type[ProviderTypes]], Type[ProviderTypes]]: def decorator(cls: Type[ProviderTypes]) -> Type[ProviderTypes]: - logger.error("Registering provider: %s", short_hand) + logger.debug("Registering provider: %s", short_hand) global _provider_registry if issubclass(cls, ClientAuthProvider): _provider_registry["client_auth_providers"][short_hand] = cls From 82c3aa6340be64726be5d3a213d9fab31e48e744 Mon Sep 17 00:00:00 2001 From: Trayan Azarov Date: Wed, 23 Aug 2023 14:55:35 +0300 Subject: [PATCH 2/4] chore: CIP-2 Auth Providers - Set the status of the CIP to `Accepted` --- docs/CIP_2_Auth_Providers_Proposal.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/CIP_2_Auth_Providers_Proposal.md b/docs/CIP_2_Auth_Providers_Proposal.md index 2652f626523..95df2d9b6c3 100644 --- a/docs/CIP_2_Auth_Providers_Proposal.md +++ b/docs/CIP_2_Auth_Providers_Proposal.md @@ -2,7 +2,7 @@ ## Status -Current Status: `Under Discussion` +Current Status: `Accepted` ## **Motivation** From dd3af5d929ce346c0d2092eb55b8f5b710ad09da Mon Sep 17 00:00:00 2001 From: Trayan Azarov Date: Wed, 23 Aug 2023 16:45:03 +0300 Subject: [PATCH 3/4] fix: CIP-2 Auth Providers - Adding /docs and /openapi.json the the ignore paths - by default leaving the API interface public --- chromadb/config.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/chromadb/config.py b/chromadb/config.py index 67dbfe8ef40..5a0b5eed13e 100644 --- a/chromadb/config.py +++ b/chromadb/config.py @@ -128,6 +128,8 @@ def chroma_server_auth_credentials_file_non_empty_file_exists( "/api/v1": ["GET"], "/api/v1/heartbeat": ["GET"], "/api/v1/version": ["GET"], + "/docs": ["GET"], + "/openapi.json": ["GET"], } chroma_client_auth_credentials_provider: Optional[ From e336b0a3590a95e0eb6acabec1c95609ecfe3be3 Mon Sep 17 00:00:00 2001 From: Trayan Azarov Date: Wed, 23 Aug 2023 17:58:09 +0300 Subject: [PATCH 4/4] chore: CIP-2 Auth Providers - Removing /docs and /openapi.json from ignored auth paths --- chromadb/config.py | 2 -- 1 file changed, 2 deletions(-) diff --git a/chromadb/config.py b/chromadb/config.py index 5a0b5eed13e..67dbfe8ef40 100644 --- a/chromadb/config.py +++ b/chromadb/config.py @@ -128,8 +128,6 @@ def chroma_server_auth_credentials_file_non_empty_file_exists( "/api/v1": ["GET"], "/api/v1/heartbeat": ["GET"], "/api/v1/version": ["GET"], - "/docs": ["GET"], - "/openapi.json": ["GET"], } chroma_client_auth_credentials_provider: Optional[