From 881b072b77ac4c3bb1c79a1df4c4ec8d30942952 Mon Sep 17 00:00:00 2001 From: cfdaily Date: Tue, 19 May 2026 22:56:24 +0800 Subject: [PATCH] auto-sync: 2026-05-19 22:56:24 --- src/api/checkpoint_routes.py | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/src/api/checkpoint_routes.py b/src/api/checkpoint_routes.py index 4280baa..807587b 100644 --- a/src/api/checkpoint_routes.py +++ b/src/api/checkpoint_routes.py @@ -10,7 +10,7 @@ from pydantic import BaseModel from typing import Optional from src.blackboard.operations import Blackboard -from src.blackboard.registry import ProjectRegistry +from src.utils import get_data_root router = APIRouter(prefix="/api/projects/{project_id}/tasks/{task_id}/checkpoints", tags=["checkpoints"]) @@ -33,9 +33,8 @@ class ResolveCheckpointRequest(BaseModel): # ── 工具 ── def _bb(project_id: str) -> Blackboard: - registry = ProjectRegistry() - db_path = registry.get_db_path(project_id) - if not db_path: + db_path = get_data_root() / project_id / "blackboard.db" + if not db_path.exists(): raise HTTPException(status_code=404, detail="Project not found") return Blackboard(db_path)