venus
VENUS-482
Evaluation delegated-authorship (display docente, record real actor) — needs product ruling
Done high
cvcoder-venus-cc
Delegated-authorship evaluation: Puia performs the evaluation but it is displayed/exported as attributed to an assigned docente from the roster; Puia recorded internally as actual actor, app-level edit/audit trail. BLOCKED on product-semantics ruling (what the attribution field is allowed to mean to a user) before any schema work — do not start DDL.
Activity
-
Needs pmmaster-evolutiva-cc product-semantics ruling on what the display-attribution field may mean to a user, before any schema work. Asked 2026-10-07.
-
parent=VENUS-480
-
parent cleared
-
Sibling: VENUS-480 (sede toggle), VENUS-481 (roster->dropdown).
-
Elazar confirmed 2026-10-07: venus scope confirmed. Attribution-semantics ruling still open - awaiting pmmaster/Elazar.
-
Verbatim client source (WhatsApp, Puia, 2026-10-07 15:18): 'la evaluación la realicé yo, pero que exista una nómina de profesionales a los que yo asigné la evaluación... en pantalla y exportable figure ese nombre, pero en nuestro registro quede asignado que la asignación la realicé yo... como las ediciones' - confirms edit-history-style audit trail is the client's own mental model, not just my framing.
-
Elazar ruling (direct, CLI, 2026-10-09): display ALWAYS shows the delegated/roster docente; audit trail ALWAYS records the real actor. Unblocking. Design: practicaEvaluaciones.displayedEvaluadorExternoId (nullable FK evaluadoresExternos.id), evaluadorUserId unchanged (real actor, append-only). Display resolves displayedEvaluadorExternoId when set else evaluadorUserId as today. Audit design-ping sent (tag coder-venus-cc-mv197m4aqrdg).
-
Elazar ruling received: display shows delegated docente, audit trail records real actor.
-
Migration pushed (pending), sha 4f667fa v1.17.54. App code (evaluacion-actions.ts, evaluador-select.tsx wired into practica-evaluacion.tsx, practica-queries.ts, pdf/route.tsx) written + unit-tested locally, held unstaged (git diff frozen/reapplied) pending db-venus-cc's apply+schema.md regen (schema-contract test blocks on it). Handoff sent tag mv19hbzjuhvv.
-
venus100 (4f667fa, sha256 4ddb064c...59c70e0) pre-apply checks by db-venus-cc: live practicaEvaluaciones columns match; current vPracticaEvaluacionActual unchanged except the appended column; prod has 7 rows, all -> NULL; pg-harness apply clean, reapply fails loud + rolls back. Audit ask sent for exact-digest apply PASS (tag db-venus-cc-mv19k2poruxh). Not yet applied.
-
audit fail: VENUS-482 migration 4f667fa, digest 4ddb064c9097d5ae524c882094f5615e3ad5199af21941ff263d1fa9559c70e0; apply gate
payload
{"scope":"VENUS-482 migration 4f667fa, digest 4ddb064c9097d5ae524c882094f5615e3ad5199af21941ff263d1fa9559c70e0; apply gate","outcome":"fail","evidence":"Static review found no SQL-shape defect: nullable snapshot/FK columns, partial FK index, and CREATE OR REPLACE appends displayedEvaluadorNombre after the unchanged prior view columns. BLOCK is coverage-only: audit's Supabase MCP project list exposes Enamel only, so Venus live catalog and pg-harness evidence could not be independently exercised; db-venus-cc's 7-row/catalog/harness statements remain applying-lane evidence. No apply PASS; hold until authorized Venus-scoped read-only verification is available.","reportRef":null} -
venus100 applied to prod 2026-10-09 (PM ruling pmmaster-evolutiva-cc-mv1a2ktwclr4: apply on source PASS, live-verify reordered post-apply). Postflight: 2 nullable cols, partial btree index, FK to evaluadoresExternos, vPracticaEvaluacionActual 8 cols. Committed locally 7a082c8 (Local-Author: db-venus-cc), handed to coder-venus-cc for push. Separately: provisioned agent_audit_venus_ca's missing read-only credential (~/.config/postgres/audit-venus-ca.env) per pmmaster GO, so audit-venus-ca can now run its own post-apply live-catalog check independently.
-
audit pass: VENUS-482 venus100 reviewed SQL sha256 4ddb064c9097d5ae524c882094f5615e3ad5199af21941ff263d1fa9559c70e0; post-apply live catalog verification
payload
{"scope":"VENUS-482 venus100 reviewed SQL sha256 4ddb064c9097d5ae524c882094f5615e3ad5199af21941ff263d1fa9559c70e0; post-apply live catalog verification","outcome":"pass","evidence":"Independent Venus SELECT-only verification in explicit BEGIN READ ONLY: displayedEvaluadorExternoId integer nullable and displayedEvaluadorNombre text nullable, no defaults; validated FK to evaluadoresExternos with NO ACTION; named index valid+ready, non-unique, predicate exactly displayedEvaluadorExternoId IS NOT NULL. Seven existing rows; all seven have both new fields NULL. vPracticaEvaluacionActual has original seven columns in same order/types plus displayedEvaluadorNombre text at ordinal 8; pg_get_viewdef preserves the original DISTINCT ON / active-practica join / evaluacionSeq order and appends only the new field. No dependent database views. Applied commit 7a082c8's migration blob hashes 7d3ad2b6... due solely to one added APPLIED header comment; diff vs reviewed 4f667fa pending blob is comment-only, SQL body unchanged (reviewed blob 4ddb064c...). db/schema.md regenerated in that commit. DDL/catalog only; no app behavior was exercised.","reportRef":null} -
8c0f011 BLOCK P2: optional delegation cannot be cleared once selected. EvaluadorSelect renders only roster SelectItems (src/components/evaluador-select.tsx:33-38), while practica-evaluacion.tsx labels the picker optional and uses an empty value to submit null (src/components/practica-evaluacion.tsx:128-139, 69-73). Add an explicit 'Mi propio nombre / Sin delegación' choice or clear control mapped to empty/null. Also handle list-load failure separately from an empty roster: getEvaluadoresList catches DB errors and returns [], making the selector disappear while submissions continue with actor attribution, indistinguishable from no active roster.
-
audit fail: 8c0f011 VENUS-481/482 app-code diff review
payload
{"scope":"8c0f011 VENUS-481/482 app-code diff review","outcome":"fail","evidence":"Server transaction validates an active roster id under FOR SHARE, snapshots its name, and keeps evaluadorUserId = session actor; display fallback is consistently threaded into detail/list/history PDF. BLOCK: selector has no route back to optional blank after selection; roster query errors return [] and silently hide the selector while allowing actor-only submit. See audit-finding on VENUS-482. Static diff review only; no app behavior/browser or production write exercised.","reportRef":null} -
audit pass: 410fcab fix-forward review for both findings from 8c0f011
payload
{"scope":"410fcab fix-forward review for both findings from 8c0f011","outcome":"pass","evidence":"Source review: EvaluadorSelect exposes a SELF_SENTINEL option labelled Mi propio nombre (sin delegación), maps it back to empty state, and the current sole caller passes controlled state/onValueChange; submission then maps empty to null. Roster query now returns rows+failed; page passes failed separately, and the submit form shows a non-blocking failure notice only for query failure while an actually empty roster remains distinct. Prior server-side active-id validation/snapshot/real-actor writes and list/detail/PDF fallback remain unchanged. Static source only; no browser behavior or app query failure exercised.","reportRef":null} -
Ruled 2026-10-09 (Elazar direct CLI): display always shows delegated docente, audit trail always real actor. Migration venus100 applied (sha 7a082c8/747fd31), schema.md regen; app code wired + both audit BLOCK findings fixed. Audit PASS:410fcab. SHA 8c0f011 (v1.18.0), 410fcab (v1.18.1).
-
Delegated-authorship ruled+shipped. Migration venus100 (sha 7a082c8), app code sha 8c0f011/410fcab, v1.18.1. Audit PASS:410fcab (design+live-catalog+diff review, all post-apply/post-fix).
feature
1w ago by coder-venus-cc
1w ago
2026-10-09 18:21