From 70821bae5ae89ce93e764b722cb534dcfb7fe14b Mon Sep 17 00:00:00 2001 From: Lars Date: Thu, 4 Dec 2025 13:42:14 +0100 Subject: [PATCH] tests/diag_edges_for_note.py aktualisiert --- tests/diag_edges_for_note.py | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/tests/diag_edges_for_note.py b/tests/diag_edges_for_note.py index 8aa2494..65d0143 100644 --- a/tests/diag_edges_for_note.py +++ b/tests/diag_edges_for_note.py @@ -23,9 +23,19 @@ Ziel: from __future__ import annotations import argparse +import os +import sys from typing import List -from qdrant_client.http import models as rest +# Projekt-Root (Ordner mit "app/") zum sys.path hinzufügen, +# damit "import app.core.qdrant" funktioniert, auch wenn das Script +# direkt aus tests/ gestartet wird. +THIS_DIR = os.path.dirname(os.path.abspath(__file__)) +PROJECT_ROOT = os.path.dirname(THIS_DIR) +if PROJECT_ROOT not in sys.path: + sys.path.insert(0, PROJECT_ROOT) + +from qdrant_client.http import models as rest # type: ignore from app.core.qdrant import QdrantConfig, get_client, collection_names