Boards opened under the versions before #6515 had every per-swimlane list
un-bound automatically: the board data-repair treated any list with a
swimlaneId as #6484 corruption and cleared it, and a per-swimlane list is
indistinguishable from a corrupted board-wide one at the data level. #6515
stopped it. Nothing put the bindings back, so those lists still render under
every swimlane, and deleting one from a swimlane deletes the only list document
there is - which is what #6670 reports.
The old value is recoverable, not guessable. That clearing went through
Lists.direct.updateAsync, which bypasses collection hooks, so it only ever
touched the list document - while the binding each list was CREATED with is
recorded in a different collection:
// models/lists.js - Lists.after.insert -> trackOriginalPosition()
originalSwimlaneId: this.swimlaneId || null,
if (!existingHistory) { PositionHistory.insertAsync(document); }
That insert is insert-ONLY, written once at creation and never overwritten, so
it survived untouched for every list created since list position tracking
landed (2025-10-16, 2543df942).
Admin Panel / Problems / Summary now detects this the way it detects broken
cards - "Lists missing their swimlane N", with a Restore button beside it -
and restoring puts each list back in the swimlane its own record names.
Every rule is a reason to SKIP, because the failure mode here is worse than
doing nothing:
- a list that already has a swimlaneId is never touched, so the repair is
idempotent and cannot undo a binding an admin has since set by hand;
- a list with no record, or one recorded as board-wide (null), stays
board-wide;
- a swimlane that has since been deleted is not resurrected, and one on
another board is refused - either would hide the list in every swimlane,
which is worse than leaving it shared.
Nothing is inferred from the cards, and a test pins that the planner cannot
grow a use for them. Inference is the obvious idea and it is wrong: on a board
whose second swimlane is new every card is still in the first one, so it would
bind every list to swimlane 1 and hide them from the others - #6484 again,
the bug the clearing existed to fix.
Detection is read-only and swallows its own errors, because the Problems page
polls it every 30 seconds and a detection that throws would take the other
problems on that page with it. The repair writes swimlaneId and nothing else,
through .direct, one update per swimlane rather than one per list.
One new string, translated into all 197 locales that were complete, each
following that file's own "Repaired __fixed__ card(s)." sibling so the count
style and script match what the language already uses here. Low confidence on
the long tail - Bislama, Buryat, Cherokee, Ewe, Fijian, Greenlandic, Inuktitut,
Klingon, Nahuatl, Sakha, Tamazight, Venda, Volapük, Wolof - which a speaker
should correct. Noted while writing them: the `lists` value is wrong-language in
mn (Russian), sk (Czech), sr and wa-RR (Tagalog); not touched here.
Also fixed a guard that the parallel worktree exposed:
tests/noIdentityReplacement.test.cjs walked into .claude/worktrees/, a full
second checkout, and reported the deliberate samples in ITS copy of that test
file as real findings.
Thanks to TawsTm and xet7 !
Motivated by the 10.16-10.21 reports where, after an upgrade, the login page
showed "Must be logged in" or sat on the logo + "Loading, please wait." spinner,
pages took 5+ minutes, All Boards counts stayed 0 and i18n showed raw keys — the
FerretDB v1 (SQLite) process pegged ~2 cores for a long time under WeKan's poll
load, i.e. a migration/repair or a saturated backend, with no way to see it
without the Admin Panel.
Server-side, independent of any client / progress page:
- server/startup/repairBoardsOnStartup.js runs the shared board data-repairs once
(version-gated, background, 30s after boot) so corrupted data is fixed even if
no user opens a board and nobody watches a progress page.
- The MongoDB <-> SQLite text migration and the startup repair now PERSIST their
progress to the text_migration_status collection (models/textMigrationStatus.js),
so a separate process can see "a migration/repair is in progress" (an in-memory
object could not).
Status overview (server/lib/systemStatus.js), shown in Admin Panel / Problems ->
Summary and via the method systemStatusReport (admin-gated, server/methods/
systemStatus.js):
- everything in progress (text migration, board repair, recovery, cron migration,
attachment migration) aggregated from the persisted status collections;
- detected problems (broken cards; failing login-page checks);
- login-page "Must be logged in" / "Loading, please wait" cause checklist
(migration in progress, ROOT_URL, LDAP, Sandstorm) — models/lib/loginProblems.js;
- a CPU detail area that calls out a pegged ferretdb process and the mitigation.
Snap: `snap run wekan.problems` (snap-src/bin/wekan-problems[.mjs], snapcraft app
`problems`) prints the same overview as text — problems, migrations/repairs in
progress, login checks — so an admin with only server access can see it WITHOUT
Admin Panel access. Sub-commands: migrations | login | broken-cards | cpu | help.
Pure helpers models/lib/loginProblems.js and models/lib/problemsOverview.js are
unit-tested; tests/problemsStatus.test.cjs (14 checks) also source-guards the
server hub, method, startup pass, migration persistence and snap command.
Thanks to xet7 !