chore(parity): record prod⇄dev⇄repo parity execution + fix stale schedule test

- docs/prod-parity-plan.md: audit + phased plan, now marked EXECUTED with the
  autonomous decisions (target=HEAD, data preserved, bonus shipped at 0,
  whole-tree deploy).
- docs/releases/2026-10-16.md: append the parity release record (schema +
  ledger + whole-tree code deploy, backups/rollback tags, 151/151 e2e, 46-assert
  live rollback smoke, autosync preserved, dev==prod==repo).
- e2e/admin-schedule.spec.ts: drop the stale 'Evaluate' disabled assertion
  (button removed from the codebase in 821907b).

Co-authored-by: Stephan Charles <[email protected]>
Co-authored-by: Amelia Hernandez <[email protected]>
Co-authored-by: Markus Franz <[email protected]>
Co-authored-by: Sabrina Hota <[email protected]>
Co-authored-by: Nilüfer Doğan <[email protected]>
This commit is contained in:
committed 2026-10-16 17:56:09 +02:00
1 parent 2d4be583ce
commit 940bc5b160
3 files changed
+249 -1

No files matched your search

+75
View File
@@ -82,3 +82,78 @@ tests against it.
- `nginx -t` ok; attendee + admin HTTP/HTTPS 200; only `convivo-app`
recreated; all unrelated container IDs preserved.
- 41/41 mocked browser tests pass against `https://convivo.appe.at`.
---
# Production ⇄ Dev ⇄ Repo Parity (2026-10-16)
Follow-up release that brought **production fully up to date with the
repository** and made **dev and prod schema-identical**. See
`docs/prod-parity-plan.md` for the audit and phased plan; this records the
execution.
## Why
Prior deploys were scoped overlays because production's source had drifted
behind the repo (it predated Networking, `get_talk_cohort`, the composite
`accept_connection`, Reports export, etc.). The audit also showed **dev was not
a clean mirror either** — neither dev nor prod had the full
`20260920000000_talk_networking` migration (both lacked the bonus column, the
`shared_talk`-returning `accept_connection`, and the widened `points_log`
CHECK). The correct source of truth is git `HEAD`; both databases were brought
to it.
## Schema parity
- Applied `20260920000000_talk_networking` to **dev and prod** (single
transaction each): `events.talk_networking_bonus`, re-created
`accept_connection` (returns `shared_talk`, awards the bonus via
`_award_points`), widened `points_log.category` CHECK, `get_talk_cohort`.
- Backfilled the migration ledger with the 9 previously-untracked migrations in
**both** databases → `ledger = 38` everywhere (matches the repo file set).
- Set the active event's `talk_networking_bonus` to **0** on both, so the new
bonus path is inert until deliberately enabled (column default stays 2 for
new events).
- **Gate:** normalized `pg_dump` of the public schema — dev vs prod diff is
**empty** (byte-identical).
## Code + config parity (whole-tree deploy)
- Folded production's genuinely-better sidecar Dockerfile (`npm ci` + lockfile)
into the repo first (commit `93d188a`), so a repo→prod copy loses nothing.
- Replaced all three app trees on production with a clean checkout of `HEAD`
(`apps/{convivo,admin,sidecar}`), removing stale `.orig` overlay backups.
`docker-compose.yml` already matched; `.env`/secrets/GoTrue/kong runtime
untouched (parity is committed files + schema, not live data or credentials).
- **Gate:** production app tree `diff -rq` against the repo payload is **empty**.
## Deployment record
- Backups: full prod `pg_dump` + source archive + container inventory under
`/home/APPE/convivo-backups/parity-20261016T154507Z` (pre-migration) and
`parity-20261016T154937Z` (pre-deploy). Rollback image tags
`convivo-{app,admin,sidecar}:rollback-parity-20261016T154937Z`.
- Build-before-`up`: all three images built successfully before any container
was recreated (a build failure would have auto-restored source with zero
downtime).
- Live bundles `index-DtIEihnG.js` (attendee) and `index-CitZP5XQ.js` (admin)
match the local `HEAD` builds exactly; sidecar `/health` ok, `/export` route
+ `pdfkit` present.
- Autosync preserved: pretix every-minute (111 attendees, 0 errors) and the
Sessionize/GridSmart poller (30 sessions, 0 errors) both running after the
rebuild.
- `nginx -t` ok in both frontends; attendee + admin HTTP/HTTPS 200; only the
three convivo service containers recreated; all unrelated Supabase container
IDs preserved.
## Verification
- Mocked browser e2e against production: **151/151** (after removing one stale
`Evaluate` assertion in `admin-schedule.spec.ts` — that button was removed
from the codebase in `6bad96c`).
- Live rollback-only `leaderboard_tests.sql` smoke on production: **46
assertions passed**, exercising `accept_connection` `shared_talk` + the
`talk_networking` bonus path; all row counts unchanged after `ROLLBACK`
(real data preserved).
- Final three-way check: **dev == prod == repo** for schema, ledger, and app
source.