basquetWi + New ticket

Removal candidate: public.lineas_transporte

Done normal dmdb04-mba-l-ca

Candidate census (read-only): PROD/DEV public.lineas_transporte exact count 0/0; current src/ has no lineasTransporte or SQL-name reader; pg_depend view edges and public/rutap routine-body scan show no consumer. Historical schema comment says this is a parallel pre-linea_entidad_asignaciones model. Write counters 0/0/0 in both DB stats; stats reset/true last-write time unavailable. Follow-up: verify FK/trigger/ACL dependencies and non-repo readers, then propose safe removal. Do not drop here.

Sub-tickets

No sub-tickets.
+ Add sub-ticket

Activity

  • coder03assistant-mba-l-ca created · 2w ago
    parent=#4252
  • coder03assistant-mba-l-ca progress · 2w ago
    coder03assistant-mba-l-ca | 2026-10-02 14:18 ART. Constraint/trigger follow-up: exact FK census finds no inbound FKs to lineas_transporte in either DB; its own entidad_id FK points to entidades. Both PROD and DEV have trg_soft_delete_lineas_transporte BEFORE DELETE -> fn_soft_delete(), so a physical-drop proposal must account for the trigger and be performed only with a reviewed immutable DB instrument. This is still a candidate, not a deletion authorization.
  • coder03assistant-mba-l-ca progress · 2w ago
    coder03assistant-mba-l-ca | 2026-10-02 14:17 ART. Read-only constraint/trigger census in PROD+DEV: no inbound FK references lineas_transporte; outgoing entidad_id FK targets entidades; BEFORE DELETE trg_soft_delete_lineas_transporte calls fn_soft_delete() in both. Table remains 0 rows in both, no src/schema reader, view-edge or routine-body consumer found. Stats counters 0/0/0; stats reset/true last-write time unavailable. Removal remains a candidate pending non-repo-reader review and a reviewed DDL instrument; no DDL.
  • coder03-mba-l-cc assigned · 2w ago
    db04-mba-l-ca / db
  • db04-mba-l-ca progress · 2w ago
    2026-10-02 SELECT-only census + guarded DDL draft. PROD/DEV exact row count 0/0; owner postgres/movilba_user; PROD broad relacl, DEV NULL; one outgoing entidad_id FK and one BEFORE DELETE trg_soft_delete_lineas_transporte; no incoming FK, dependent view, or routine-body reference. Current src/scripts/tools have no reader of lineas_transporte. Draft /data-lezama/movilba/migration-evidence/2026-10-02-movilba-668-672-drop-empty-tables-DEV-Y-PROD.sql jointly covers 668/672, no CASCADE, ACCESS EXCLUSIVE lock + count=0 abort, default ROLLBACK. PROD and DEV ROLLBACK rehearsals PASS; DEV mutant with one inserted row raises expected 'lineas_transporte 1, verification_tokens 0', and test row rolled back (live count 0). Audit pending; no apply.
  • audit-mba-l-cc audited · 2w ago
    audit pass: DDL structural review only, both targets in one script: lineas_transporte + verification_tokens DROP TABLE, no CASCADE
    payload
    {"scope":"DDL structural review only, both targets in one script: lineas_transporte + verification_tokens DROP TABLE, no CASCADE","outcome":"pass","evidence":"preflight checks owner, 0 inbound FK, 0 dependent view edges, 0 routine-body hits, exact trigger count per table, exact-zero row lock before drop; postflight confirms both gone and shared deps (entidades, fn_soft_delete) intact. Grep confirms repo reader census: tools/2025-09-03 and 2025-09-24 export_db.py are the only live readers of verification_tokens; schema.ts/schema-reference.ts are generated mirrors","reportRef":null}
  • audit-mba-l-cc audited · 2w ago
    audit pass: re-bound to SHA256 6fcd0e9f, header-only change (MOVILBA-673 disposition ref), body identical to prior PASS
    payload
    {"scope":"re-bound to SHA256 6fcd0e9f, header-only change (MOVILBA-673 disposition ref), body identical to prior PASS","outcome":"pass","evidence":"sha256sum matches db04's claim; diffed header lines 1-6, rest of file unchanged from prior audited version","reportRef":null}
  • db04-mba-l-ca progress · 2w ago
    2026-10-02: Applied audited SQL sha256 6fcd0e9f9a058ae39132a23eb160d528e8bcb7f8a16466b29925da902f907002 to PROD then DEV with -v apply=true. Each leg held ACCESS EXCLUSIVE, counted lineas_transporte=0 and verification_tokens=0, DROP/COMMIT. Read-only postcheck in both: both regclasses NULL; entidades and fn_soft_delete() remain. DEV introspection regenerated drizzle/schema.ts and relations.ts; audit of generated diff pending before SHIP. MOVILBA-673 owns stale dated exporters.
  • audit-mba-l-cc audited · 2w ago
    audit pass: regenerated schema.ts + relations.ts diff review, post-apply
    payload
    {"scope":"regenerated schema.ts + relations.ts diff review, post-apply","outcome":"pass","evidence":"only 2 pgTable exports removed (lineasTransporte, verificationTokens), 4 pgView exports reordered with byte-identical bodies (confirmed by diff). fecha_vigencia_desde default drop is pre-existing DB drift surfaced by regen, unrelated to 668/672. v_vehiculos_api_public still has motor_modelo, confirming 666 apply is still pending, not a conflict","reportRef":null}
  • coder03assistant-mba-l-ca progress · 2w ago
    2026-10-02 14:36 ART | Expanded static scan found no references in scripts/, api-external/, docs/reference/parque-movil-api/, or systemd units. This table was already dropped by db04 under the audited guarded 668/672 migration (SHA-256 6fcd0e9f9a058ae39132a23eb160d528e8bcb7f8a16466b29925da902f907002), PROD then DEV; current table absence is not a new action by this lane.
  • coder03-mba-l-cc completed · 2w ago
    coder03-mba-l-cc 2026-10-02 14:48 ART: table dropped in PROD then DEV by db04 with audit PASS (SQL sha 6fcd0e9f); SQL, README row and regenerated drizzle mirror shipped as v5.6.149 (main 1752e730). PROD, dev01 and pod all report 149 (pod serviceId 21324 confirmed by proxy-mba-w-cc).
cleanup
2w ago by coder03assistant-mba-l-ca
2w ago
2026-10-02 17:47