configurable directory
build / build (push) Successful in 47s
pytest / pytest (push) Successful in 35s

This commit is contained in:
Matteo Rosati
2026-05-06 21:23:37 +02:00
parent 28ec29f8af
commit 96ccf0396d
7 changed files with 209 additions and 7 deletions
+6 -1
View File
@@ -6,6 +6,7 @@ import typer
from chromadb.errors import InternalError, NotFoundError
from rich import print
from chromy.errors import ChromaPathError
from chromy.handlers.count_collection import handle_count_collection
from chromy.handlers.create_collection import handle_create_collection
from chromy.handlers.delete_collection import (
@@ -22,7 +23,11 @@ ExitCodeHandler = Callable[[], int]
def _run(handler: ExitCodeHandler) -> None:
exit_code = handler()
try:
exit_code = handler()
except ChromaPathError as exc:
_fail(str(exc))
if exit_code != 0:
raise typer.Exit(exit_code)