halkyon/apps/train/halkyon_train_server/migrations
Repository files (latest commit first)
Filename Latest commit message Latest commit date
Tizian 「ティツィアーン」 7f1f07883a
feat(base,app,learn): a shared space's key rolls once a member goes
What is written in a shared space after a member went takes a key they
never get (Halkyon's ADR 0044, D22). The instance marks the space as one
of its members goes, removed, leaving or deleted (`keyRollDue` on
`shared_space`, set in `removeMember`, through which each of them
passes); an invitation taken back never had a key and marks nothing, nor
does a new role. The Owner's or an Editor's device that next keeps its
keys up after a sync is told so (`sharedSpaceKeys.rollDue`, never true
for a Viewer, who seals no key) and makes a new key, sealed to those who
stay (D33). The first seal bringing a key ID the space never had clears
the mark in the same transaction (D34); members the rolling device
missed get it later as newcomers do. Earlier rows keep the key they had,
which whoever went had read already.

The migration, the same in the module and in each server including it
(Learn, Meditate, Todo, Train):

  ALTER TABLE "shared_space"
    ADD COLUMN "keyRollDue" boolean NOT NULL DEFAULT false;

It adds the column with false for every space there is, so no space is
due a roll from it; PostgreSQL adds a column with a constant default
without rewriting the table. The server before the switch reads and
writes the table naming its own columns, so it keeps working.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Signed-off-by: Tizian 「ティツィアーン」 <raisondetredev@pm.me>
2026-11-11 16:57:49 +01:00
..
20261028075229917-initial feat(train): Halkyon Train's shell, Todo's copied and renamed (ADR 0030, D12) 2026-10-30 15:52:45 +01:00
20261028101012641-workouts feat(train): the sync engine and Train's first models (ADR 0030, D14) 2026-10-30 15:52:47 +01:00
20261028164640000-profile feat(train): the body's figures in a sealed, synced profile (ADR 0030, D33, D34) 2026-10-30 15:52:55 +01:00
20261028181405893-days feat(train): the Loop's days read on the phone (ADR 0030, D37, D38) 2026-10-30 15:52:57 +01:00
20261028211508606-plans feat(train): interval plans, synced and sealed, with an editor and templates (ADR 0030, D42) 2026-10-30 15:52:59 +01:00
20261028231042668-routes feat(train): routes kept as sealed rows, planned on the map (ADR 0030, D44) 2026-10-30 15:53:02 +01:00
20261102103211357-training-places feat(train): equipment by place and a plate calculator (ADR 0034) 2026-11-02 13:31:46 +01:00
20261102113104496-strength-plans feat(train): strength plans and sessions (ADR 0035) 2026-11-02 13:31:51 +01:00
20261103204323683-body-weights feat(train): weight, entered on Progress and read from Health Connect, sealed and synced (ADR 0030, D63) 2026-11-04 09:32:10 +01:00
20261110225636220-file-store refactor(base,learn): people's files kept by halkyon_base 2026-11-11 01:19:28 +01:00
20261111091721828-shared-spaces feat(base,learn): spaces people share, kept by halkyon_base 2026-11-11 10:54:19 +01:00
20261111100125761-shared-space-keys feat(base,app,keys): keys of shared spaces, sealed to each member 2026-11-11 11:35:42 +01:00
20261111145610490-shared-space-key-roll feat(base,app,learn): a shared space's key rolls once a member goes 2026-11-11 16:57:49 +01:00
migration_registry.txt feat(base,app,learn): a shared space's key rolls once a member goes 2026-11-11 16:57:49 +01:00