Closed bug report

Silent fallback to dev identity (barrett-land, no orgs) when adom-wiki CLI is old — Org tab renders empty

noah · 13d ago ·closed by barrett-land

Symptom

On a container with an older adom-wiki CLI (page-era v1.12.2), the Manager UI shows the Organization tab empty (and Personal wrong) even though org boards exist and are present in the /api/components payload. me resolves to barrett-land and orgs to [] for every user.

Root cause

The server shells out to adom-wiki whoami --json and expects the pkg-era shape (data.user.username, data.orgs[]). The old CLI emits a different shape (wiki_user, adom_identity, no orgs field at all). When the parse doesn't match, the app silently falls back to compiled-in dev defaults — identity barrett-land, empty org list — so orgAll = boards.filter(c => orgs.includes(c.org)) filters out every org board.

Verified on noah's container 2026-07-08: with CLI 1.12.2 on PATH → me: "barrett-land", orgs: []; after installing pkg-era CLI 1.0.22 to ~/.local/bin and restarting → me: "noah", orgs: ["adom","utd"], 7 org boards render.

Suggested fixes

  1. Never fall back silently to a developer identity. If whoami fails or the output shape is unrecognized, surface it in the UI ("couldn't resolve wiki identity — check adom-wiki --version, need pkg-era ≥1.0.x") and show me: unknown rather than a real user's name. A wrong-but-plausible identity is the worst failure mode — it looks like the wiki has no data.
  2. Check the CLI version at startup (adom-wiki --version) and warn loudly when the page-era CLI (versions like 1.12.x without pkg) is what's on PATH.
  3. Drop the remaining compiled-in dev defaults: DEST_FOLDERS is hardcoded to /home/barrett-land/... paths, which every other user sees in the "Deliver project to" dropdown. Resolve from $HOME / adom-desktop instead.

Environment

  • adom-project-manager v0.1.0 (installed from this page's files)
  • old CLI: /usr/local/bin/adom-wiki 1.12.2 · working CLI: ~/.local/bin/adom-wiki 1.0.22
  • container: noah / adom org

1 Reply

barrett-land · 13d ago

Fixed in adom-project-manager v0.2.0.

The server no longer hard-codes barrett-land. whoami parsing is now tolerant of CLI-version JSON shapes — it tries data.user.username, data.user.name, user.username, data.username, username — and reads org names from data.orgs or orgs (each entry may be an object with name or a bare string).

Crucially, if the identity can't be read at all, it is left empty rather than falling back to a dev identity, so the Personal/Organization tabs simply show nothing instead of mislabeling every user as barrett-land and rendering an empty Org tab. Update the app (adom-wiki pkg install adom/adom-project-manager) to pick it up.

Log in to reply.