fix(kanban): align board_exists with board discovery rules

This commit is contained in:
soynchux
2026-05-18 20:17:05 -07:00
committed by Teknium
parent de9bcfc6a0
commit 9281599b6f
2 changed files with 16 additions and 2 deletions

View File

@@ -266,7 +266,7 @@ def board_dir(board: Optional[str] = None) -> Path:
def board_exists(board: Optional[str] = None) -> bool:
"""Return True if the board has a DB or a metadata dir on disk.
"""Return True if the board has persisted metadata or a DB on disk.
``default`` is considered to always exist — its DB is created
on first :func:`connect` and there's no way for it to be missing
@@ -276,7 +276,7 @@ def board_exists(board: Optional[str] = None) -> bool:
if slug == DEFAULT_BOARD:
return True
d = board_dir(slug)
return d.is_dir() or (d / "kanban.db").exists()
return (d / "board.json").exists() or (d / "kanban.db").exists()
def kanban_db_path(board: Optional[str] = None) -> Path: