Skip to content

Kanban should not silently synthesize/create boards from a stale current-board pointer #20055

@steezkelly

Description

@steezkelly

Bug Description

Kanban can silently treat a stale <root>/kanban/current board pointer as a real board. Some commands synthesize metadata for the missing slug, and other commands can create an empty board directory/DB implicitly. This makes a stale or corrupted current-board pointer look like a valid active board instead of warning and falling back to default or requiring explicit board creation.

Reproduction

Run in an isolated Hermes home:

tmp=$(mktemp -d)
mkdir -p "$tmp/kanban"
printf 'missing-board\n' > "$tmp/kanban/current"

HERMES_HOME="$tmp" hermes kanban boards show
HERMES_HOME="$tmp" hermes kanban stats
HERMES_HOME="$tmp" hermes kanban list
HERMES_HOME="$tmp" hermes kanban boards list

Actual Behavior

boards show exits 0 and reports a synthesized board even though it was never created:

Current board: missing-board
  Display name: Missing Board
  DB path:      /tmp/.../kanban/boards/missing-board/kanban.db
  Tasks:        0 total

After running stats, list, or boards list, Hermes creates the missing board path implicitly:

kanban/boards/missing-board/kanban.db

boards list then presents the stale slug as active:

    SLUG                      NAME                          COUNTS
    default                   Default                       (empty)
●   missing-board             Missing Board                 (empty)

Current board: missing-board

Expected Behavior

If <root>/kanban/current points to a board that does not exist, Kanban should not silently synthesize or create it during read/list/stats operations.

Prefer one of these behaviors:

  1. warn and fall back to default, optionally clearing the stale current pointer, or
  2. return a clear error:
current board 'missing-board' does not exist; create it with `hermes kanban boards create missing-board` or switch back with `hermes kanban boards switch default`

Only hermes kanban boards create <slug> should create a new board.

Code Path / Evidence

The behavior appears to come from the interaction of:

  • hermes_cli/kanban_db.py::get_current_board() returning the normalized slug from <root>/kanban/current without checking board_exists().
  • hermes_cli/kanban_db.py::read_board_metadata() synthesizing metadata for any slug.
  • commands such as stats / list resolving the active board through get_current_board(), then connecting to that board DB path.

hermes kanban boards switch <slug> already validates board_exists() and rejects missing boards, but a stale current pointer bypasses that protection.

Why This Matters

The dashboard and CLI rely on current-board state as the user-facing active workspace. If the pointer drifts to a missing/experimental board slug, users can end up looking at an empty synthetic board and think their real board/tasks disappeared. In a multi-agent Kanban workflow, that is a data-integrity and operator-confidence problem.

Environment

  • Hermes Agent v0.12.0 (2026.4.30)
  • Source commit: b816fd4e2
  • OS: Linux desktop 6.17.0-22-generic x86_64
  • Python: 3.11.15

Metadata

Metadata

Assignees

No one assigned

    Labels

    P3Low — cosmetic, nice to havecomp/pluginsPlugin system and bundled pluginstype/bugSomething isn't working

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions