Repository navigation
Settings ownership P52: strict configuration JSON admission (E2992 v23) #3146
Description
Current authoritative specification: v29 / Full R23
All five original participants newly approved this exact master and twenty phase digests. Thirteen recipes now validate Cargo workspace at the authorized repository root; target/executable containment and STOP on error remain mandatory. P52 source commit1d5f6b9 is preserved, so its next stage is verification. This corrects documentation and source provenance within the original scope.
Master: D:/0_repos/AgentsCommander_iac/.ac/plans/2992-settings-owner/plan-v29-settings-owner.md
Plan-SHA256: E12A49A810F4270C93BFA7D2EA0C9829EE99AF0B95231912C5CFC30FA80A2051
Mapping: D:/0_repos/AgentsCommander_iac/.ac/plans/2992-settings-owner/phase-issues-v17.json
Identity-SHA256 (compact identity object): 43A926CB7FE16F1FB9CC1D16E5437851C894993C51CD7BBBA5CFF1DFE5EC8D2A
Consensus: D:/0_repos/AgentsCommander_iac/.ac/project-shared/2992-settings-owner/minimum-path-20261016/full-r23-consensus-approved-v1.json
Standing authorization: D:/0_repos/AgentsCommander_iac/.ac/plans/2992-settings-owner/v29-standing-authorization-receipt-v1.json
Complete joined phase and file-impact packet: D:/0_repos/AgentsCommander_iac/.ac/project-shared/2992-settings-owner/minimum-path-20261016/v29-mapped-review-packet-v1.md
All twenty child/branch identities and BASE values are preserved. Six delivered phases remain closed; fourteen phases remain sequential. Execution requires a fresh cold gate and explicit lead dispatch. Shipper exclusively runs product checks; no intermediate app build. Previously requested final no-bundle build once after all phases merge from clean synchronized main, with room09 artifact path/hash/bytes/UTC/sourceSHA; no installation/release/version bump.
Phase P52, child#3146, owner ac-dev-rust-v5, class design-bearing, branch refactor/3146-settings-owner-p52-configuration-admission, dependencies P44.
Canonical phase file (sole implementation specification): D:/0_repos/AgentsCommander_iac/.ac/plans/2992-settings-owner/P52-v5-configuration-admission.md
Phase-SHA256: 910DBB9EB9EB058FC2AB2BC6F02328C7AC5623AA1B5C9AFC76E4A44E6C69C836
Allowed MODIFIED paths (0A/0D):
- src-tauri/src/path_identity.rs
- src-tauri/src/config/local_config_io.rs
- src-tauri/src/config/agent_config.rs
- src-tauri/src/config/replica_identity.rs
- src-tauri/src/config/coding_agent_profiles.rs
- src-tauri/src/config/teams.rs
- src-tauri/src/config/local_overlay.rs
- src-tauri/src/config/root_agent.rs
- src-tauri/src/config/sessions_persistence.rs
- src-tauri/src/commands/config.rs
Existing sourceHEAD1d5f6b9ac1695243c4844f2bf81b50ecebc2e378 is committed/clean; BASE196a4cf48b8e97a087d68fcfdd7abc2687d7cfcd. Mandatory duplicate error with real filename/cause and intact bytes; same-buffer initial admission and typed propagation/ordinary policy/PAIR C3 preserved. Local checks, independent code/proof review and integrated PRE/POST/CI remain pending.
Historical issue body, superseded only by the current exact specification above:
Current authoritative specification: v26 / Full R20
All five original participants approved the exact master plus twenty phase digests. P52 preserves a typed duplicate cause through the shared writer/repair/coordinator chain; ordinary errors retain their existing behavior. Configuration images remain checked before embedded parsing with full operational validation. Same user scope and ten paths; exact ten own partial outputs are preserved, not an initially clean tree.
Master: D:/0_repos/AgentsCommander_iac/.ac/plans/2992-settings-owner/plan-v26-settings-owner.md
Plan-SHA256: A736FEE7B1ADBC3764334310BFDE15C91E67CBE2479B2EE814A67ACB6D488EBC
Mapping: D:/0_repos/AgentsCommander_iac/.ac/plans/2992-settings-owner/phase-issues-v16.json
Identity-SHA256: 201A0CC7C4FF31667E77015E52261B8C7496B5DECE651748C18A1DC105075761
Consensus: D:/0_repos/AgentsCommander_iac/.ac/project-shared/2992-settings-owner/minimum-path-20261016/full-r20-consensus-approved-v1.json
Standing authorization: D:/0_repos/AgentsCommander_iac/.ac/plans/2992-settings-owner/v26-standing-authorization-receipt-v1.json
Review packet: D:/0_repos/AgentsCommander_iac/.ac/project-shared/2992-settings-owner/minimum-path-20261016/v26-mapped-review-packet-v1.md
Existing P52 child3146/branch/BASE196a4cf4 and P45 historical child3000/branch/base are retained without recreation/reset/rebase. Source resume remains gated by a successful fresh cold gate and explicit P52 dispatch; no source/checks/build authorized merely by this header. Nineteen other specs and their phase identities remain unchanged, six delivered remain closed. One phase at a time. No intermediate app build; final requested no-bundle build once after all phases merged from clean synchronized main, shipper only, room09 exe receipt; no install/release/version bump.
Phase P52, owner ac-dev-rust-v5, class design-bearing, dependency P44 #2999 / merged PR3139, branch refactor/3146-settings-owner-p52-configuration-admission.
Phase file (sole implementation specification, read in full): D:/0_repos/AgentsCommander_iac/.ac/plans/2992-settings-owner/P52-v4-configuration-admission.md
Phase-SHA256: 83FF3BA4D1F7399D89C3A7AD98475E34BB6A67111D6FF5786C2B00ED7A03BD06
Allowed MODIFIED files (0A/0D):
- src-tauri/src/path_identity.rs
- src-tauri/src/config/local_config_io.rs
- src-tauri/src/config/agent_config.rs
- src-tauri/src/config/replica_identity.rs
- src-tauri/src/config/coding_agent_profiles.rs
- src-tauri/src/config/teams.rs
- src-tauri/src/config/local_overlay.rs
- src-tauri/src/config/root_agent.rs
- src-tauri/src/config/sessions_persistence.rs
- src-tauri/src/commands/config.rs
Acceptance: initial duplicateJsonMember error before Value/normalization/use, real physical filename and cause preserved, no duplicate member names/values in error, config bytes intact. Typed duplicate propagation covers writer/repair/coordinator and checked profile resolution, without classifying by text or swallowing duplicates. Contextual reservation admission still covers before_tuple and all stages before plan validation/map/protected projection; operational envelope checks remain complete. Use the frozen phase recipe and its minimal inline fixtures/verification; exclusive shipper execution after Rust source.
Historical issue body, superseded only where the v26 header and frozen phase differ:
Current authoritative specification: v25 / Full R19
All five original participants approved the exact master plus twenty phase digests. P52 now checks configuration images before any embedded JSON parse, preserving full operational reservation validation and the real D/S filename/cause in the mandatory error. Same user scope, same ten P52 paths.
Master: D:/0_repos/AgentsCommander_iac/.ac/plans/2992-settings-owner/plan-v25-settings-owner.md
Plan-SHA256: A22019C0610E582E7A21CFBFB267FB5D7BBA4129339A799BDFC264EE9B2AB431
Mapping: D:/0_repos/AgentsCommander_iac/.ac/plans/2992-settings-owner/phase-issues-v15.json
Identity-SHA256: 209CB84F33F547BC1132C77EB09FCDCFF7B5499B3E6391138B5B933A138FFD31
Consensus: D:/0_repos/AgentsCommander_iac/.ac/project-shared/2992-settings-owner/minimum-path-20261016/full-r19-consensus-approved-v1.json
Standing authorization: D:/0_repos/AgentsCommander_iac/.ac/plans/2992-settings-owner/v25-standing-authorization-receipt-v1.json
Review packet: D:/0_repos/AgentsCommander_iac/.ac/project-shared/2992-settings-owner/minimum-path-20261016/v25-mapped-review-packet-v1.md
Existing P52 child3146/branch/BASE196a4cf4 and P45 historical child3000/branch/base are retained without recreation/reset/rebase. Source resume remains gated by a successful fresh cold gate and explicit P52 dispatch; no source/checks/build authorized merely by this header. Nineteen other specs and their phase identities remain unchanged, six delivered remain closed. One phase at a time. No intermediate app build; final requested no-bundle build once after all phases merged from clean synchronized main, shipper only, room09 exe receipt; no install/release/version bump.
Phase P52, owner ac-dev-rust-v5, class design-bearing, dependency P44 #2999 / merged PR3139, branch refactor/3146-settings-owner-p52-configuration-admission.
Phase file (sole implementation specification, read in full): D:/0_repos/AgentsCommander_iac/.ac/plans/2992-settings-owner/P52-v3-configuration-admission.md
Phase-SHA256: 36A52E2F1C10683618E5EBC045F2430505C90F0253EC4F87D5A2AB87C68DB9BF
Allowed MODIFIED files (0A/0D):
- src-tauri/src/path_identity.rs
- src-tauri/src/config/local_config_io.rs
- src-tauri/src/config/agent_config.rs
- src-tauri/src/config/replica_identity.rs
- src-tauri/src/config/coding_agent_profiles.rs
- src-tauri/src/config/teams.rs
- src-tauri/src/config/local_overlay.rs
- src-tauri/src/config/root_agent.rs
- src-tauri/src/config/sessions_persistence.rs
- src-tauri/src/commands/config.rs
Acceptance: initial duplicateJsonMember error before Value/normalization/use, real physical filename and cause preserved, no duplicate member names/values in error, config bytes intact. Contextual reservation admission covers before_tuple and all stages before plan validation/map/protected projection, while operational envelope checks remain complete. Use the frozen phase recipe and its minimal inline fixtures/verification; exclusive shipper execution after Rust source.
Historical issue body, superseded only where the v25 header and frozen phase differ:
Part of #2992. This phase implements the user-required strict rejection of duplicate JSON members in consumed AgentsCommander configuration. Return an error with the file intact; never choose first/last, repair, default or partially consume duplicates. Other errors preserve their existing policy.
Approved Full R17 specification: D:/0_repos/AgentsCommander_iac/.ac/plans/2992-settings-owner/plan-v23-settings-owner.md
Plan-SHA256: FA45A1A72BD0A8DF30F3AFD0BAE6DDA3159FA5DCD65D5F7B4EC5CDFF4F6B34F3
Phase: P52; owner ac-dev-rust-v5; class design-bearing; depends on P44 (#2999), which must be merged before starting.
Phase file: D:/0_repos/AgentsCommander_iac/.ac/plans/2992-settings-owner/P52-v1-configuration-admission.md
Phase-SHA256: 3EEE6C4AE49D00911724FA151CD666AA1F9B72E956DD71765FD8F44FD68E0583
Consensus: D:/0_repos/AgentsCommander_iac/.ac/project-shared/2992-settings-owner/minimum-path-20261016/full-r17-consensus-approved-v1.json
Source is gated by the exact mapping/standing-authorization receipt and a successful cold implementation dispatch. Branch is created only at phase start from current synchronized main. Product checks are executed exclusively by shipper; no intermediate app build. One final requested no-bundle build after all phases merge.
The following immutable phase specification contains the situation, decided change, exact allowed files, acceptance and verification commands. It is the sole implementation specification; the issue/mapping supplies administrative identity only.
E2992 P52 v1 — configuration-admission
Status: READY_FOR_IMPLEMENTATION
Versión:1; inicial R16, sin archivo histórico creado en R15. Readiness sólo AUTORÍA; consenso/ejecución pendientes.
Owner: ac-dev-rust-v5. Class: design-bearing. Changed contract: admisión de configuración. Depends-on: P44.
Epic2992; workflow Full continuación R16, gate frío full-r16-planning-cold-gate-approved-v1.json. Sólo autoría autorizada; fuente bloqueada.
Participantes exactos: ac-architect-v5, ac-dev-rust-v5, ac-dev-webpage-ui-v5, ac-dev-rust-grinch-v5, ac-architect-grinch-v5. Mismo master+veinte digests, revisión pendiente; lead despacha, votos previos no se transfieren.
Repo D:/0_repos/AgentsCommander_iac/.ac/room-09-ac-dev-team-v5/repo-AgentsCommander; diseño9ce147f8454af7ad9d4bd27c1a358f93fd229850. Rutas producto relativas al repo, planes desde .ac.
Fuente pedido: autorización rechazo p45-user-reject-duplicate-json-paths-authorization-v1.json/decisión restore v2/propuesta v3/reconciliación R15-B1, no permiso de fuente.
Riesgo rutinario funcional transversal: selección/conservación/concurrencia cooperante, sin host attestation/signing/PATH hostil.
Archivos permitidos
Sólo MODIFIED/ADDED0/REMOVED0; 10 paths máximo10, un dueño, secuencial tras dependencia merged. No reabrir seis entregadas.
| Archivo relativo al repo | Impacto |
|---|---|
| src-tauri/src/path_identity.rs | MODIFIED |
| src-tauri/src/config/local_config_io.rs | MODIFIED |
| src-tauri/src/config/agent_config.rs | MODIFIED |
| src-tauri/src/config/replica_identity.rs | MODIFIED |
| src-tauri/src/config/coding_agent_profiles.rs | MODIFIED |
| src-tauri/src/config/teams.rs | MODIFIED |
| src-tauri/src/config/local_overlay.rs | MODIFIED |
| src-tauri/src/config/root_agent.rs | MODIFIED |
| src-tauri/src/config/sessions_persistence.rs | MODIFIED |
| src-tauri/src/commands/config.rs | MODIFIED |
Objetivo y corte verde
Admisión común y proveedores checked, sin reclamar rechazo global antes de migrar consumidores.
R15-B1 resuelto por sustitución autorizada: commands/config reemplaza project_settings; diez paths.
Project settings conserva íntegro su trabajo en P58; P53–P57 no llaman sus load/save/migrate, sólo lib registra dos comandos.
No cambia inventario global, dueño, orden ni contratos. Nada requiere código futuro para compilar.
Decisiones por archivo y API
- path_identity.rs: añadir pub(crate) validate_ac_configuration_json(path: &Path, bytes: &[u8]) -> Result<(), String>, adaptador puro de scan_json_document. Con scan exitoso y duplicate_keys true devuelve prefijo duplicateJsonMember:. Con scan Err devuelve Ok sólo para este chequeo de duplicados: NO declara válido el JSON; el parser nativo obligatorio que sigue conserva su error de sintaxis. Nunca usar este Ok para omitir parse. No cambiar parse_json_no_duplicates de protocolos.
- El mensaje generado: "duplicateJsonMember: configuration file contains repeated JSON object members. Remove duplicate members from the same object and restart/retry. The file was left unchanged." No claves/valores/posición prometida; path local real autorizado. No IO ni log en adaptador.
- local_config_io.rs: exponer forwarding pub(super) check_configuration_json(path, bytes) al adaptador por su referencia existente. update_config_json_object:263 y read_pair_side:2605 validan los mismos bytes antes de Value/callback/normalización/publicación. PAIR D/S :1473, reconcile activity :1755 y reserved execute :1912 validan ambos originales de configuración y cada imagen adoptada bajo guard antes de cleanup. read_config_pair_physical NO se valida indiscriminadamente: journals/reservations operativos permanecen fuera. Conservar testigos, caps, locks, C1/C2/C3 y PartialOrUnknown real tras efectos.
- agent_config.rs: añadir read_agent_local_config_checked(dir)->Result<Option,String> y read_last_agent_message_at_checked(repo_path)->Result<Option,String>. read_agent_local_config_json ya Result: admitir config.json y config.state.no-git.json antes de typed_ok, filter o merge. Chequeo sobre bytes capturados una vez por lector, nunca reabrir para validar. checked conserva None/política ordinaria IO/sintaxis del typed reader; duplicado siempre Err. raw conserva su error ordinario de decisions y filtrado state ajeno a duplicados. Exponer forwarding pub(super) check_configuration_json para profiles, sin nuevo arco. Wrappers Option anteriores permanecen únicamente hasta consumidores P53; no declarar cierre global.
- replica_identity.rs: añadir ReplicaConfigFault::DuplicateJsonMember. read_wg_replica_config_read_only_classified valida bounded bytes 1MiB antes del parser actual y devuelve esa razón+mensaje. Reparación usa update_existing_agent_config validado bajo guard antes de tocar identidad/contexto. Ningún error por duplicado se vuelve IdentityMissing o ConfigNotJson dentro del dominio.
- commands/config.rs: scope_fault_code sigue exhaustivo SIN wildcard; nueva variante mapea a ScopeFaultCode::ConfigNotJson sólo en este helper de compatibilidad DTO. enumerate_profile_assignment_targets retorna Err(message) ante DuplicateJsonMember ANTES de warnings/scope_faults/candidatos parciales de :2552. Otros seis errores y DTO exitoso intactos; no API clasificada paralela ni inspección de texto para esconder la variante.
- coding_agent_profiles.rs: preparar read_json_object_checked y selección/origen checked paralelos para consumidores Option de P53; admitir sus bytes por forwarding agent_config antes de Value. read_replica_selection_default:814 e identity_reference_value:1172 ya Result: propagar duplicado antes de defaults, expected-prior o mutación. Revisiones físicas/CAS y locks iguales. Mantener wrappers sólo para callers todavía no migrados.
- teams.rs: preparar variantes checked Result de discover_teams/discover_teams_in_project_filtered, resolve_wg_coordinator_replica y verified_wg_coordinator_target con los mismos argumentos y valores Vec/Option dentro de Result; discover_teams_from_project_paths_checked recibe &[String] para no recargar settings. La variante filtered con &mut Vec conserva esos argumentos y retorna Result<(),String>: acumular en Vec local y extender destino sólo después del éxito completo. read_identity_json checked valida bytes antes de Value. Un duplicado de cualquier documento recorrido aborta snapshot completo, nunca equipo omitido. Wrappers viejos sólo hasta P54/P55; checked implementa lectura propia compartida, nunca delega en infalible y examina resultado.
- local_overlay.rs: añadir from_overlay_bytes_paired_checked con argumentos históricos más overlay_path:&Path y callback fn(&Path,&[u8])->Result<(),String> al final y Result del valor histórico. Validar fuentes presentes antes de merge/shadowing. Hoja permanece sin imports scanner/settings/host ni logging; caller da etiquetas físicas de los mismos bytes. Wrapper legacy sólo hasta P45.
- root_agent.rs: preparar read_last_coding_agent_checked(root_dir)->Result<Option,String> usando raw checked antes de proyección; preservar ausencia y sintaxis ajena. merge_root_agent_config/ensure admiten config y state existentes ANTES de repair/layout que los consuma, por forwarding existente agent_config. Wrapper Option sólo hasta P54; no producto por él al final.
- sessions_persistence.rs: añadir pub(crate) read_startup_sessions_for_admission(config_dir:&Path, settings:&AppSettings)->Result<Vec,String>. Factorizar decoder load_sessions_from_path_with_settings:1432 y partición :640-690/session_retention_project_paths:563 (active+archived, Root igual). Mismas filas seleccionadas/normalización/binding origins; no settings loader físico. Ausencia/sintaxis de sessions conserva política porque es dato operativo. Cero purge/orphan archive/drop/save/creación; no publicar snapshot preparado.
Todos los inline consumers alterados de los diez paths se adaptan dentro del corte. Helpers preparados sin caller admiten dead_code estrecho temporal sólo si lint lo exige; retirar al migrar. Sin tipo futuro, flag de tolerancia ni dependencia nueva.
Evidencia y aceptación propia
Reutilización confirmada estáticamente al HEAD: scan_json_document:1596 conserva duplicate_keys recursivo; Serde decodifica escapes/HashSet por objeto. local_config_io ya importa path_identity; agent_config ya importa local_config_io; profiles ya agent_config; teams/replica ya path_identity. Callback mantiene overlay leaf. Decoder sessions ya recibe settings opcional.
Fixtures inline existentes con prefijo e2992_duplicate_json_: matriz detector única (igual/distinto/escape/unknown/nested-array duplicados Err; padres/índices distintos, literal a.b y overrides entre documentos válidos); config.state inválido aunque se proyecte sólo timestamp; typed razón y perfil aborta sin parciales; PAIR/naming no altera bytes ante duplicado; read-only sessions cero efectos y mismas filas/Root.
Canary en clave y valor no aparece en error. Ausencia válida conserva defaults legítimos, sintaxis conserva clasificación nativa. No tests nuevos por wrapper ni infraestructura.
Handoff P53: APIs checked agents/profiles/Root/teams, lector sessions sin efectos y adaptador disponibles; grupos pendiente P58, core settings pendiente P45, co-managed/catalog/menus en sus cortes.
Contrato común de admisión y preservación
Único dueño settings/RAM, sin nueva fuente productiva. Configuración JSON AC realmente consumida incluye core, menús/ayuda, catálogos, project/team/agent/replica/co-managed y config.state mixto por selección/perfiles. Primera lectura necesaria para boot/restore automático rechaza startup; lectura/reemplazo posterior rechaza uso dependiente. Sin discovery de no usados, defaults/partial/Off ante duplicate, reparación automática ni atomicidad multiarchivo.
Igualdad de claves decodificadas por objeto recursivo (x/\u0078 iguales); padre repetido invalida, padres/índices diferentes y literal a.b versus a/b válidos; overrides entre documentos válidos. No casefold/normalización Unicode/identidad filesystem de keys. No confundir IDs repetidos con duplicate JSON.
Bytes admitidos son los mismos que se parsean; antes Value/typed/filter/merge/shadowing/refresh/naming. Caps/locks/autoridad/identidad/revocation/rechecks actuales preceden y acompañan lectura; preparado no acredita actualidad. Ausencia verificada conserva ausencia; otros errores mantienen política, sintaxis siempre pasa por parser nativo.
Err duplicateJsonMember: con archivo/causa sin keys/values/env/token; conservar razón tipada donde existe. IPC/WS Err envelope actual, CLI mensaje/exit no cero, boot StartupError/present_fatal; workers sin Result cortan acción dependiente y ERROR sanitizado al sink/error_log_event existente. No log sólo WARN y fallback. Pre-auth remoto nunca revela path/payload; respuesta fija sensible intacta, diagnóstico local autorizado.
No tocar sessions/clocks/TASK/protocolos/journals/caches puramente operativos, capture/state ni loops TOML; config.state sí se valida entero por uso mixto. No parser/deps/framework/registry/transporte/esquema nuevo.
Preservar dueño/availability/guard por expresión/PTY permit hasta write, principal/caps/privacidad, nueve sessions/F2/FinalRetention, retención activa+archivada y QuitGate. P51 current_read fallible/factories/catch/guards/barriers/tail y cadencia/cancelación exactos; sin reabrir seis entregadas. Fallo parcial real nunca se llama rollback/no-write ni adopta defaults.
Capas y evidencia estática
Base9ce147f8454af7ad9d4bd27c1a358f93fd229850. Índice raíz room09 ready44413/262454 sin SHA; metadata_changed obliga fuente directa focal, no prueba universal de callers. Blueprint v3 y reconciliación R15-B1 respaldan receta, no sustituyen decisiones de esta spec ni son spec alternativa.
Delta duplicate previsto: cero parejas de módulos nuevas/retiradas; adaptador en path_identity y forwarding por relaciones existentes. Callbacks puros hacia hojas local_overlay/co_managed/capture_catalog/container_repos/session_context evitan imports al scanner/host. Nada lower->AppHandle/Tauri/CLI/WS. PRE histórico c61cfbd/SCC89 y module-arcs DDBC8A498AF2FBFCFA8275001F0A623A77BD4615E1AF601AECBA3231A47A16FC no son POST actual.
Shipper debe comprobar PRE/POST integrado exacto, SCC member sets idénticos, cero nuevas parejas externas, arcos regenerados byte-idénticos y guards verdes; manual métodos/macros/guards complementa detector. No compile/Send/lifetime/runtime/test/graph/CI/GUI PASS durante autoría. Hallazgo no previsto detiene corte/revisión acotada, no ampliar baseline.
Ejecución futura y entrega (no ejecutada durante autoría)
No mutar producto antes de cinco votos exactos, revisión humana y despacho del lead. Un solo corte en vuelo; dueño ac-dev-rust-v5. Revisor Rust Grinch, arquitectura Grinch y dueño UI revisan el mismo conjunto. Child/branch/bases/PR/recibos van en registro externo MAP provisto por lead externo, nunca editar Markdown congelado. Un child y un PR por fase; epic2992 permanece abierto hasta integración/build final.
Todas las compilaciones/tests/fmt/grafos/npm son ejecución FUTURA EXCLUSIVA ac-shipper-v5; Rust/UI sólo editan fuente autorizada. Los comandos focales anteriores se ejecutan DESPUÉS de inicializar R/EVIDENCE/toolchain/containment abajo. Shipper retiene stdout/stderr/exit/UTC con timeout del runner; filtro vacío/fallo/timeout bloquea. Verificar Node22.14.0/npm11.6.2/Rust1.98.1 y locks intactos; Cargo sólo proceso, sin config/jobs/profile/caches globales. Antes de integration tests repetir --no-run --message-format=json con sus tres --test y el mismo chequeo de executable containment. No build intermedio; único build de producto final tras todas las fases.
Git Bash en Windows; cwd raíz repo room09. Ejecutar con timeout/log/stdout/stderr/exit del runner existente, stdin no interactivo; guardar evidencia en target/2992-evidence/<PHASE_ID>. Fallo/timeout/filtro vacío no es PASS. No reset/clean global ni restauración que pise terceros.
set -euo pipefail
PHASE_ID="P52"
EXPECTED_DEPS="P44"
R="D:/0_repos/AgentsCommander_iac/.ac/room-09-ac-dev-team-v5/repo-AgentsCommander"
cd "$R"
test "$(git rev-parse --show-toplevel)" = "$R"
test -z "$(git status --porcelain=v1 --untracked-files=all)"
test -z "$(git diff --cached --name-only)"
: "${MAP:?lead debe proveer ruta exacta del mapping validado de este conjunto}"
export MAP PHASE_ID EXPECTED_DEPS
# CHILD/BRANCH provistos por lead desde mapping validado, no inventarlos.
export CHILD BRANCH
node --input-type=module - <<'NODE'
import fs from 'node:fs'; import assert from 'node:assert/strict';
const m=JSON.parse(fs.readFileSync(process.env.MAP,'utf8'));
const p=m.phases[process.env.PHASE_ID]; assert(p);
assert.equal(String(p.child),process.env.CHILD); assert.equal(p.branch,process.env.BRANCH);
assert.deepEqual(p.dependencies,process.env.EXPECTED_DEPS.split(',').filter(Boolean));
assert(new RegExp('^refactor/'+p.child+'-[a-z0-9-]+$').test(p.branch));
NODE
test "$(gh issue view "$CHILD" --repo mblua/AgentsCommander --json state --jq .state)" = OPEN
gh api --paginate repos/mblua/AgentsCommander/issues/2992/sub_issues --jq '.[].number' | grep -Fx "$CHILD"
git fetch origin main
git diff --name-status 9ce147f8454af7ad9d4bd27c1a358f93fd229850 origin/main
# Clasificar drift por paths/formatter/toolchain/CI. Refrescar sólo evidencia relevante.
EVIDENCE="$R/target/2992-evidence/$PHASE_ID"
mkdir -p "$EVIDENCE"
node --input-type=module - <<'NODE' > "$EVIDENCE/dependencies.tsv"
import fs from 'node:fs';import assert from 'node:assert/strict';
const m=JSON.parse(fs.readFileSync(process.env.MAP,'utf8'));
for(const id of m.phases[process.env.PHASE_ID].dependencies){
const p=m.phases[id]; assert(p.pr&&p.mergeSha); console.log(p.pr+'\t'+p.mergeSha);
}
NODE
while IFS=$'\t' read -r dep_pr merge_sha; do
test "$(gh pr view "$dep_pr" --repo mblua/AgentsCommander --json state --jq .state)" = MERGED
test "$(gh pr view "$dep_pr" --repo mblua/AgentsCommander --json baseRefName --jq .baseRefName)" = main
test "$(gh pr view "$dep_pr" --repo mblua/AgentsCommander --json mergeCommit --jq .mergeCommit.oid)" = "$merge_sha"
git merge-base --is-ancestor "$merge_sha" origin/main
done < "$EVIDENCE/dependencies.tsv"
git switch -c "$BRANCH" origin/main
BASE="$(git rev-parse HEAD)"
printf '%s\n' "$BASE" > "$EVIDENCE/base.sha"
git branch --show-current
git status --porcelain=v1 --untracked-files=all
node --version # esperado22.14.0
npm --version # esperado11.6.2
export CARGO_TARGET_DIR="$R/target" CARGO_BUILD_BUILD_DIR="$R/target"
cd "$R/src-tauri"
rustc +1.98.1 -vV
cargo +1.98.1 --version
cargo +1.98.1 metadata --locked --no-deps --format-version=1 > "$EVIDENCE/metadata.json"
export EVIDENCE R
node --input-type=module - <<'NODE'
import fs from 'node:fs';import path from 'node:path';import assert from 'node:assert/strict';
const m=JSON.parse(fs.readFileSync(process.env.EVIDENCE+'/metadata.json'));
const normal=p=>path.resolve(p).replaceAll('\\','/').toLowerCase();
assert.equal(normal(m.target_directory),normal(process.env.R+'/target'));
assert.equal(normal(m.workspace_root),normal(process.env.R+'/src-tauri'));
NODE
cargo +1.98.1 test --locked --lib --no-run --message-format=json > "$EVIDENCE/test-artifacts.jsonl"
node --input-type=module - <<'NODE'
import fs from 'node:fs';import path from 'node:path';import assert from 'node:assert/strict';
const normal=p=>path.resolve(p).replaceAll('\\','/').toLowerCase();
const root=normal(process.env.R+'/target')+'/';let n=0;
for(const l of fs.readFileSync(process.env.EVIDENCE+'/test-artifacts.jsonl','utf8').split('\n').filter(Boolean)){
const a=JSON.parse(l);if(a.executable){assert(normal(a.executable).startsWith(root));n++}
}assert(n>0,'no test executable');console.log({containedExecutables:n});
NODE
cargo +1.98.1 test --locked --lib e2992_duplicate_json_ -- --list > "$EVIDENCE/duplicate-list.txt"
grep -F e2992_duplicate_json_ "$EVIDENCE/duplicate-list.txt"
# Lista debe incluir casos de ESTA fase; revisar nombres/count>0, no aceptar sólo casos previos.
cargo +1.98.1 test --locked --lib e2992_duplicate_json_ -- --test-threads=1 --nocapture
cargo +1.98.1 check --locked --all-targets
cargo +1.98.1 fmt --all -- --check
cargo +1.98.1 test --locked --test loops_layering --test instance_gitignore_layering --test project_settings_layeringConservar Node22.14.0/npm11.6.2/Rust1.98.1 de CI y locks existentes. Sin cambios de versiones/deps/formatter ajenos. Al escribir: revalidar branch/base/index/paths, registrar preimagen y output propio por path. Recuperar sólo bytes propios aún intactos; preservar cambios ajenos y reportar conflicto. Comparar full BASE..HEAD (jamás HEAD~1), staged y ordinary-untracked; todo hunk propio dentro de la tabla. Cero es estado válido, no ausencia de evidencia.
Antes de push/PR integrar origin/main localmente y resolver sólo conflictos autorizados. Registrar PRE actual (origin/main) e integrated HEAD limpios. Si merge incorpora cambios ajenos, mantener full diff desde BASE y documentar por separado ese delta byte-idéntico a upstream; comprobar también PRE..HEAD para aislar trabajo propio, sin ocultar cambios ni reiniciar diseño por drift ajeno. No ampliar union propia para silenciar gates.
cd "$R"
git fetch origin main
PRE="$(git rev-parse origin/main)"
git merge --no-edit origin/main
# Resolver/commit si corresponde; después debe estar limpio.
test -z "$(git status --porcelain=v1 --untracked-files=all)"
mkdir -p "$EVIDENCE/pre-source"
git archive "$PRE" | tar -x -C "$EVIDENCE/pre-source"
set +e
node scripts/01-rust_module-dependency-cycles.mjs "$EVIDENCE/pre-source/src-tauri" --emit-graph "$EVIDENCE/pre.json" --quiet > "$EVIDENCE/pre-detector.log" 2>&1
pre_exit=$?
node scripts/01-rust_module-dependency-cycles.mjs src-tauri --emit-graph "$EVIDENCE/post.json" --quiet > "$EVIDENCE/post-detector.log" 2>&1
post_exit=$?
set -e
test "$pre_exit" -le 1
test "$post_exit" -le 1
node scripts/02-module-arc-record.mjs --graph "$EVIDENCE/post.json" --out "$EVIDENCE/post-arcs.txt"
export EVIDENCE
node --input-type=module - <<'NODE'
import fs from 'node:fs';import assert from 'node:assert/strict';
const root=process.env.EVIDENCE,pre=JSON.parse(fs.readFileSync(root+'/pre.json')),post=JSON.parse(fs.readFileSync(root+'/post.json'));
function scc(g){
const a=new Map(g.modules.map(n=>[n.id,[]]));for(const e of g.edges)if(e.from!==e.to)a.get(e.from).push(e.to);
let i=0,idx=new Map,low=new Map,stack=[],on=new Set,sets=[];
function walk(v){idx.set(v,i);low.set(v,i++);stack.push(v);on.add(v);
for(const w of a.get(v)){if(!idx.has(w)){walk(w);low.set(v,Math.min(low.get(v),low.get(w)))}else if(on.has(w))low.set(v,Math.min(low.get(v),idx.get(w)))}
if(low.get(v)===idx.get(v)){let z=[],w;do{w=stack.pop();on.delete(w);z.push(w)}while(w!==v);sets.push(z.sort())}}
for(const v of a.keys())if(!idx.has(v))walk(v);
const cyclic=sets.filter(z=>z.length>1).sort((a,b)=>a[0].localeCompare(b[0]));
assert.equal(cyclic.length,g.summary.moduleCycles);return {sets,cyclic,map:new Map(sets.flatMap((z,i)=>z.map(v=>[v,i])))};
}
const a=scc(pre),b=scc(post);assert.deepEqual(b.cyclic,a.cyclic);
const arcs=g=>new Set(g.edges.filter(e=>e.from!==e.to).map(e=>e.from+' -> '+e.to)),old=arcs(pre),now=arcs(post);
const internal=(f,t)=>a.map.has(f)&&a.map.get(f)===a.map.get(t)&&a.sets[a.map.get(f)].length>1;
assert(internal(a.cyclic[0][0],a.cyclic[0][1])); // control positivo sobre SCC real
const outside=a.sets.find(z=>z.length===1);assert(outside);assert(!internal(a.cyclic[0][0],outside[0]));
const added=[...now].filter(x=>!old.has(x));for(const x of added){const [f,t]=x.split(' -> ');assert(internal(f,t),'new cross-boundary arc '+x)}
console.log(JSON.stringify({cyclicSccs:b.cyclic.length,memberSetsIdentical:true,newArcs:added,newCrossBoundaryPairs:0}));
NODE
cmp "$EVIDENCE/post-arcs.txt" src-tauri/module-arcs.txt
npm run check:arcs
npm run check:cycles
git diff --check "$BASE" HEAD
git diff --name-status "$BASE" HEAD
git diff --name-status "$PRE" HEAD
git diff --cached --exit-code
git status --porcelain=v1 --untracked-files=allReviewer compara grafos por SCC con algoritmo del instrumento: coverage.graphShape.cyclicSccs debe ser igual PRE/POST, TODOS los conjuntos completos de miembros idénticos, cero NUEVAS parejas from->to entre SCC PRE distintos; referencias internas sólo en SCC preexistente. No basta igual número/SCC count. Graph exit1 con archivo válido es ciclos existentes; exit2/3/análisis ausente bloquea. Instrumento1.1.1 ignora métodos/macros y algunos paths: revisar manualmente referencias reales/guards y el permiso PTY; no afirmar cero universal. Registro regenerado byte-idéntico y guards verdes antes de publicación, no POST imaginario.
Todos los jobs disparados y configured-required verdes en exact PR-head. CI actual: ci-tier/test-debt/rust-regression Windows/clippy-linux/rust-regression-linux/rust-linux-release-parity/rust-regression-macos/rust-fmt/terminal-snapshot-portable/windows-release-cli-smoke/issue-1850-windows-profile/frontend-regression según tier. Lead consulta reglas required reales y aplica ci:full para evidencia OS nueva; skips inexplicados/otro SHA bloquean. P41 incorpora filtros e2992_ en Linux/macOS existentes; Windows ya corre --lib --bins --tests. No nuevo runner.
git rev-parse HEAD
# Tras autorización de publicar: PR base main, head BRANCH/SHA exactos, cierre sólo CHILD.
gh pr view "$PR" --repo mblua/AgentsCommander --json baseRefName,headRefName,headRefOid,closingIssuesReferences,statusCheckRollup
gh pr checks "$PR" --repo mblua/AgentsCommander --watch
gh pr checks "$PR" --repo mblua/AgentsCommander --requiredLead verifica conjunto de cierres exactamente {CHILD}, tested-head, mergeSHA y ancestry en main; guarda recibos externos. No cierre de epic por keyword de fase. Build histórico sólo tras todos los children merged: shipper ejecuta npm run build:prod:no-bundle en main limpio/upstream origin/main/igualdad targetSHA; copia no-clobber de agentscommander_testeable.exe al target/release/agentscommander_standalone_room-09__.exe (UTC del build), entrega path/hash/bytes/UTC/SHAfuente; lead verifica y recién entonces cierra epic. No instalación/release/version bump.
Activity
chore: preserve P52 work before temporary suspension refs #3146
mblua commentedon Oct 22, 2026
El trabajo de este issue queda suspendido temporalmente por instrucción expresa del usuario. Se suspenden P52 y todas las tareas posteriores del requerimiento de settings en memoria; no habrá continuación automática. La reanudación requiere una nueva instrucción del usuario.
Todo el código trabajado hasta la suspensión, incluidos los últimos dos ajustes mecánicos de formato, queda conservado en origin/refactor/3146-settings-owner-p52-configuration-admission, commit 9cd2999.
Estado: PENDING. El issue permanece abierto y el PR #3162 no se integra. P52 y el requerimiento original no se consideran terminados. Persisten verificaciones pendientes y fallos de CI anteriores; no se declara aprobación de pruebas para este último commit. No se ejecutan nuevas pruebas, builds, correcciones, revisiones ni fases.
mblua commentedon Oct 27, 2026
Current restart: new plan from current main (2026-10-27)
The user authorized replanning via room-37, P50 option 1. The previous v29/P52-v5 specification and votes are historical requirements/evidence; they do not authorize implementation against the new module structure. PR #3162 is closed as superseded; its branch is preserved.
Current issue branch:
refactor/3146-settings-owner-current-structure, clean at56a7d00e433c6b0b1b5fa0c5c0a6c2d328522e13. The objective remains one effective in-memory settings owner for app/CLI/daemon. Six delivered phases remain preserved; static investigation still finds gaps in all fourteen remaining historical phases. The first P52 cut must use free paths; full P52 also crosses reserved Root/replica/sessions/commands paths and cannot be declared complete prematurely.Verified evidence:
.ac/project-shared/2992-settings-owner/replan-20261027/rust-current-state-v1.md, SHA25649DBEE50C947357DC2D4B63105F9C4A3D5FAEA9AEAA52157FC0E64E98D62685A. Static findings are not runtime/test approval.Technical cost (each 1–20, ceremony excluded): scope 16 (many modules); diagnosis 13 (silent Option/Vec fallback); domain 14 (decoded JSON keys, privacy, PAIR); ambiguity 13 (new structure and cross-module contracts); blast radius 17 (persisted configuration preservation); integration 15 (shared contracts and cross-room reservations); verification 17 (no-consumption/no-write controls and effective ownership); state/compatibility 16 (owner adoption/retention); concurrency 16 (locks/lifecycle/lease); environment 11 (platform filesystem/permissions and shared host constraints).
Raw 148; final 73/100, using
round((raw - 10) / 190 * 99) + 1. Excluded: issues, branches/push, PR, CI wait, review rounds, messaging/delegation, changelog/version, merge/cleanup. Full workflow applies on architectural, state and concurrency grounds as well. Architect authors; Rust, UI, Rust Grinch and Architecture Grinch review the exact master/phase identities. Verification controls, full file tables and written environment risk are mandatory. The owning dev may dispute one category with evidence before implementation.No product edits, Cargo, tests or implementation dispatch authorized yet. New exact consensus, room-37 reservations and Step 7.5 approval remain required. Updated plan and approval package will be routed through room-37.
mblua commentedon Oct 27, 2026
#3146 — partición aprobada técnicamente R5
Issue: #3146
Branch: refactor/3146-settings-owner-current-structure
Master: D:/0_repos/AgentsCommander_iac/.ac/plans/3146-settings-owner-replan/plan-v6-settings-owner-replan.md
Plan-SHA256: A403F33C535E3BB7A38086F9DF9B5DF96EFA196724349BAAA4C8D8EAB68116EA
Certificado: D:/0_repos/AgentsCommander_iac/.ac/project-shared/2992-settings-owner/replan-20261027/architect-r5-candidate-v1.md
Certificate-SHA256: BC8A93CDD9F5CDA2404362026A713150B272764AB1273EFFBF4A872203DC4EF9
Cinco participantes conformes; Step7.5 pendiente vía room37, sin ejecución autorizada. 48fases secuenciales en una issue/rama/PR; no sub-issues. 245paths225M20A0D/375incidencias; reserva por fase.
Registro externo: D:/0_repos/AgentsCommander_iac/.ac/plans/3146-settings-owner-replan/phase-commits.json; initialBase y commits pendientes de gates de ejecución.
mblua commentedon Oct 27, 2026
#3146 — re-score del remanente tras contradicción contractual R5
Original73/raw148: D:/0_repos/AgentsCommander_iac/.ac/project-shared/2992-settings-owner/replan-20261027/lead-intake-and-score-v1.md.
Nuevo66/raw135, fórmula round((135-10)/190*99)+1=66. No fase de este conjunto se comprometió/entregó: se puntúa el producto restante completo, no la ceremonia de corregir dos documentos. El draft parcial no se considera entrega.
Excluidos: issues/ramas/push/PR, esperaCI, revisiones, mensajería/delegación, changelog, versiones, merge/limpieza, nueva ronda y aprobación. Ninguna categoría inaplicable.
Suma135, final66. WorkflowFull persiste por arquitectura/persistencia/concurrencia; mismos5participantes, controles Verification>=8,Blast>=12,State/Concurrency>=10 y Environment>=8. Ninguna disminución de gates ni scope. El ajuste de scope físico refleja inventario conocido; diagnóstico/ambigüedad bajan por evidencia ya resuelta.
Contradicción/candidato preservado: lead-r5-implementation-plan-gap-v1.md en este directorio.
mblua commentedon Oct 28, 2026
#3146 — partición aprobada técnicamente R7
Issue: #3146
Branch: refactor/3146-settings-owner-current-structure
Master: D:/0_repos/AgentsCommander_iac/.ac/plans/3146-settings-owner-replan/plan-v8-settings-owner-replan.md
Plan-SHA256: 645AC95896951D9B839832763EDC8A7A14D76DAC32397FD52B5CCA7776054C72
Certificado: D:/0_repos/AgentsCommander_iac/.ac/project-shared/2992-settings-owner/replan-20261027/architect-r7-candidate-v1.md
Certificate-SHA256: 2A48D05612F7F19A1A40D714752D5CE30F5468358E503386B1DB1AD612310FCD
Cinco participantes conformes; Step7.5 pendiente vía room37, sin ejecución autorizada. 48fases secuenciales en una issue/rama/PR; no sub-issues. 245paths225M20A0D/377incidencias; reserva por fase.
Registro externo: D:/0_repos/AgentsCommander_iac/.ac/plans/3146-settings-owner-replan/phase-commits.json; initialBase observada41762994; ningún commit de fase. Mapping reconciliado conserva historia y requiere nueva7.5.
mblua commentedon Oct 28, 2026
Closed as not planned by the user's decision (2026-10-28): the effort grew out of scope (re-plan v8: 48 phases, 245 files, owner channel and Windows integrity-level handling). It may be resumed in the future.
Nothing was pushed for this re-plan. The local branch
refactor/3146-settings-owner-current-structurein room-09 keeps the unpublished first-cut commit, and the plans/evidence stay under.ac/plans/3146-settings-owner-replan/andproject-shared/2992-settings-owner/replan-20261027/. All file reservations were released.