Inventory + retire demo-data gates/rows
Done normal
pppm-pluto-cc
Per EVO-54. (1) Inventory every isDemo / demo-* gate + demo seed rows in pluto prod (note demo seed uuids c0000000-...-000N, migrations 032/034/038/042; PLUTO-578 was a symptom). (2) Decide purge-vs-keep (archive-context aware for trigger-archived tables - db-pluto-cc owns any delete, setArchiveContext before write). (3) Remove now-dead gates after rows purged. Report inventory to PM before purge.
Questions
No questions.
Activity
-
parent=#2067
-
Phase-1 inventory done, reported to pmmaster-evolutiva-cc. Code (coder-pluto-cc): 3 inconsistent demo-detection mechanisms (isDemo bool - dead signal, 0 live true rows; hardcoded @demo.evolutiva.com/.local email LIKE filters; comisión-name 'Demo %' prefix). ~30 isDemo-exclusion query gates across queries.ts+admin-actions+administrar-actions+personas-actions+admin-batch, login-allowlist DEMO_DOMAIN_PATTERN enabler, KPI-cron demo-skip, createdVia='demo_seed'+archiveReason 'demo:' vocab, UI Real/Demo tabs+name-prefix filters. DB (db-pluto-cc): demo seed data evolved into REAL production structure - periodo a0000000-...-0001 ('2026 Anual') is the live current periodo (449 real prácticas, 259 real assignments), 6 comisiones c0000000-...-0001..0006 carry a real docente roster - NONE of this is purgeable. Only cleanly-purgeable remnant: 4 synthetic 'Elazar persona' users still live + their assignment/roster rows. Everything else demo-origin already cleaned up historically (2026-07-13 and earlier). Awaiting Elazar/pmmaster purge-plan decision - no further action pending.
-
pmmaster GO (EVO-54, nqla#2) with HARD GUARD: full team (coder+db+audit) must review+agree before any push. Guard: confirm each gate is pure demo-debt and does NOT back Elazar's multi-role view-as/impersonation path before stripping - preserve anything powering role-switching view. Strip only confirmed-dead demo code per phase-1 inventory (isDemo bool is the clear dead-signal candidate; ~30 query-gate call sites, login-allowlist DEMO_DOMAIN_PATTERN, KPI-cron demo-skip, UI Real/Demo tabs need per-site view-as check). Class-A (any auth/email/DDL touch) -> full-team design-ping+audit+agreement then push. Report SHA+audit PASS+explicit 'no view-as path removed' confirmation. Dispatching team now.
-
Two independent findings converge: the 4 synthetic persona accounts (d0000000-...-0002-000{1-4}) ARE the mechanism behind Elazar's role-switching (owned by his admin account 98b5383b via the personas feature, src/lib/auth-actions.ts/031-persona-support.sql - distinct from admin view-as) - NOT purgeable, no structural tie to isDemo. isDemo itself confirmed dead fleet-wide (0 true rows across users/practicas/studentAssignments, ~25-30 no-op filter call sites) and safe to strip independently. One factual discrepancy flagged back to db+coder for reconciliation before final report: whether the 4 persona rows currently carry ANY demo marker (isDemo/createdVia/email-pattern/archiveReason) needing cleanup, or are already demo-marker-free (coder says isDemo=false + @pluto-persona.local domain, no promotion needed; db implied they carry demo framing needing a re-tag). Awaiting reconciled answer before reporting to pmmaster.
-
Discrepancy resolved: coder-pluto-cc verified actual column values on the 4 persona rows - isDemo=FALSE, createdVia='migration' (not demo_seed), email @pluto-persona.local (not the app's real demo pattern), active. No functional demo marker exists; db-pluto-cc's 'demo framing' read was inferring from the cosmetic seed-shaped UUID prefix only, which no code keys off. Nothing to re-tag or strip on the 4 rows - leave entirely as-is, do not touch PKs. Reporting final answer to pmmaster now.
-
New cross-check from pmmaster (venus finding): venus's @demo email-allowlist override turned out load-bearing (gates /puia hidden test-login). Must verify Pluto's @demo allowlist override specifically - distinct from isDemo flag (confirmed dead) and persona rows (confirmed @pluto-persona.local, unrelated) - before stripping it. Dispatched coder-pluto-cc to check for a /puia-style route or any dependency on DEMO_DOMAIN_PATTERN end-to-end.
-
@demo allowlist verified STRIPPABLE (unlike venus's /puia case). Coder evidence: DEMO_DOMAIN_PATTERN only used in isAllowlistedEmail; login gate (auth/callback) unreachable for demo.* since all 10 demo.* users have authId=NULL + are soft-deleted (0 active, 0 ever OAuth-linked); no /puia-style hidden route exists in Pluto (grep clean); persona rows use @pluto-persona.local which never matches the demo pattern or ALLOWED_DOMAINS anyway - fully disjoint mechanisms. Two consequences flagged: verify a-solucionar filters deletedAt so the 10 dead demo users don't surface as noise; new demo.* creation becomes rejected (intended). Folding into the isDemo cleanup, Class-A path.
-
GO confirmed by pmmaster: strip isDemo gates + @demo allowlist override together, under standing guard (full-team agreement, Class-A design-ping+audit before push - touches auth/login-gate code). Persona rows + a0000000/c0000000 periodo/comisiones stay untouched (already settled). HARD GATE before close: confirm /a-solucionar's irregularities filter excludes deletedAt so the 10 dead @demo users don't surface as noise. Dispatched to coder+db+audit to coordinate directly.
-
HARD GATE CONFIRMED by db-pluto-cc (verified via source, not assumed): /a-solucionar computed by fn_getASolucionarBundle (mig 071) - all 7 anomaly sections + every joined child table filter deletedAt IS NULL in their own EXISTS/NOT EXISTS subquery. No section can surface a soft-deleted user structurally. Live-data check: 10 @demo.evolutiva.com users all deletedAt=2026-07-13 (single prior cleanup batch), 0 live @demo.* users, 0 isDemo=true anywhere. Zero residual risk. Code strip now with coder-pluto-cc (app-code push lane), audit-pluto-ca looped for Class-A design-ping/PASS.
-
Audit design-ping round: approved inventoried strip with 1 correction - practica-actions.ts demoMap/mixed-pair logic is a real behavioral isDemo gate, must be removed (INSERT may write literal false temporarily pending db's column-drop migration). Archive/history projections, vUsers field, labels, generated type deferred to the DDL follow-up (schema consumers, not gates). PLACEHOLDER_EMAIL_SUFFIXES untouched. Awaiting db agreement then coder implements.
-
SHA f0b3709 -> v2.20.0, live-verified /api/app-version. Retired 22 dead isDemo gates + practica demo-pair guard + @demo allowlist override (DEMO_DOMAIN_PATTERN). INSERT keeps literal-false isDemo bridge pending db column drop (db-pluto-cc follow-up). /a-solucionar hard gate proven: 0/10 demo users surface. audit-pluto-ca PRE-PUSH PASS + coder self-serve Class-A runtime-log PTD PASS (per Q9 Vercel-lane ruling).
chore
4w ago by wi-cli-venus
4w ago
2026-07-17 10:25