[Process] Готовить Prisma/dist один раз на backend verification boundary #66

Closed
opened 2026-10-11 21:45:18 +03:00 by codex-bot · 0 comments
Owner

Problem

Composed CI делает 3 explicit Prisma generations/2 Nest builds; standalone verify генерирует client после typed consumers. Quick start пропускает generated prerequisite, debug не задаёт development mode, targeted crash parent/src и child/dist могут расходиться. Engineering требует npm ci/full verify для каждого code change/worker.

Expected Behavior

Standalone commands честно self-contained, composed same-revision gate переиспользует current artifacts; install привязан к environment/dependency inputs, final full gate сохраняется.

Evidence

Audit date 2026-10-11; 11, 12. IDs VERIFY-003, DEPS-001, DEPS-004, TI-004, AGENT-001 (backend), CA-H01, CA-H05, RC-01, RC-03, RC-07, RC-08, RC-09. Revision 0ad84ff4f0b4712abc7e69dc299856f14af6eadd; Confidence High configured graph; Verification status static, clean-start runtime-unverified.
Affected: package.json:12–34; verify.yml:83–89; image.yml:30–33; Dockerfile:8–22; README:9–18,250–254; engineering.md:58–66; crash fixture:1–17.

Scope

In scope

Existing preparation ordering, composed runner reuse, startup/debug/crash guidance, installation/iteration/final policy.

Out of scope

Удаление app/test compiler roots, weakening SQLite/OpenAPI/security checks, cross-environment host dist cache, новый orchestrator/hooks/hash registry.

Proposed Approach

Generate до typed consumers, один current Nest build; после verify existing node test/sqlite.cjs --all без rebuild. Standalone build/test:e2e сохранить. Generation development Docker target не потерять. Conditional npm ci и один full final gate после последнего relevant edit; approved task Verification обязательна.

Acceptance Criteria

  • Fresh disposable checkout standalone verify работает; composed log содержит 1 explicit host generate/1 Nest build и прежние 19 functional suites/runtime schema parity.
  • Quick-start client подготовлен до import; debug mode development, production Secure/Swagger policy прежняя.
  • Targeted dist-dependent crash путь явно требует fresh build; SIGKILL/checkpoints остаются real.
  • Dev/prod Docker targets имеют current client/assets/native runtime; duplicate production generation устранена только после proof.
  • Code-only iteration не переустанавливает deps без причины; конечный full gate и risk-specific DB/auth/contract/durability evidence сохранены.

Verification

Один clean disposable install/verify/SQLite pass, schema-change input, existing container/crash checks при affected packaging. Invocation counts не выдавать за measured speedup.

Dependencies

Нет; этот quick win не prerequisite P1.

Traceability

Campaign WealthLedger/main#23 . Findings VERIFY-003, DEPS-001, DEPS-004, TI-004, AGENT-001, CA-H01, CA-H05, RC-01, RC-03, RC-07, RC-08, RC-09. WealthLedger/backend; T14 backend.

<!-- wealthledger-audit:2026-10-11:backend-verification-workflow --> ## Problem Composed CI делает 3 explicit Prisma generations/2 Nest builds; standalone verify генерирует client после typed consumers. Quick start пропускает generated prerequisite, debug не задаёт development mode, targeted crash parent/src и child/dist могут расходиться. Engineering требует npm ci/full verify для каждого code change/worker. ## Expected Behavior Standalone commands честно self-contained, composed same-revision gate переиспользует current artifacts; install привязан к environment/dependency inputs, final full gate сохраняется. ## Evidence Audit date `2026-10-11`; [11](https://git.personal.ksv741.ru/WealthLedger/main/src/commit/d07fbfabb1295780952a554185989d2d5b5c8349/audits/2026-10-11/reports/11-validation-and-ci-cd-efficiency-report.md), [12](https://git.personal.ksv741.ru/WealthLedger/main/src/commit/d07fbfabb1295780952a554185989d2d5b5c8349/audits/2026-10-11/reports/12-dependencies-and-configuration-report.md). IDs VERIFY-003, DEPS-001, DEPS-004, TI-004, AGENT-001 (backend), CA-H01, CA-H05, RC-01, RC-03, RC-07, RC-08, RC-09. Revision `0ad84ff4f0b4712abc7e69dc299856f14af6eadd`; Confidence High configured graph; Verification status static, clean-start runtime-unverified. Affected: [package.json:12–34](https://git.personal.ksv741.ru/WealthLedger/backend/src/commit/0ad84ff4f0b4712abc7e69dc299856f14af6eadd/package.json#L12-L34); verify.yml:83–89; image.yml:30–33; Dockerfile:8–22; README:9–18,250–254; engineering.md:58–66; crash fixture:1–17. ## Scope ### In scope Existing preparation ordering, composed runner reuse, startup/debug/crash guidance, installation/iteration/final policy. ### Out of scope Удаление app/test compiler roots, weakening SQLite/OpenAPI/security checks, cross-environment host dist cache, новый orchestrator/hooks/hash registry. ## Proposed Approach Generate до typed consumers, один current Nest build; после verify existing node test/sqlite.cjs --all без rebuild. Standalone build/test:e2e сохранить. Generation development Docker target не потерять. Conditional npm ci и один full final gate после последнего relevant edit; approved task Verification обязательна. ## Acceptance Criteria - [ ] Fresh disposable checkout standalone verify работает; composed log содержит 1 explicit host generate/1 Nest build и прежние 19 functional suites/runtime schema parity. - [ ] Quick-start client подготовлен до import; debug mode development, production Secure/Swagger policy прежняя. - [ ] Targeted dist-dependent crash путь явно требует fresh build; SIGKILL/checkpoints остаются real. - [ ] Dev/prod Docker targets имеют current client/assets/native runtime; duplicate production generation устранена только после proof. - [ ] Code-only iteration не переустанавливает deps без причины; конечный full gate и risk-specific DB/auth/contract/durability evidence сохранены. ## Verification Один clean disposable install/verify/SQLite pass, schema-change input, existing container/crash checks при affected packaging. Invocation counts не выдавать за measured speedup. ## Dependencies Нет; этот quick win не prerequisite P1. ## Traceability Campaign https://git.personal.ksv741.ru/WealthLedger/main/issues/23 . Findings VERIFY-003, DEPS-001, DEPS-004, TI-004, AGENT-001, CA-H01, CA-H05, RC-01, RC-03, RC-07, RC-08, RC-09. WealthLedger/backend; T14 backend.
codex-bot added this to the Technical Audit Remediation — 2026-10-11 milestone 2026-10-11 21:45:18 +03:00
codex-bot added the Kind/Enhancement
Priority
Medium
3
audit/2026-10-11
labels 2026-10-11 21:45:18 +03:00
codex-bot was assigned by hermes-agent 2026-10-12 00:04:22 +03:00
hermes-agent added this to the WealthLedger — Delivery Board project 2026-10-12 00:04:22 +03:00
hermes-agent added Kind/Process and removed Kind/Enhancement labels 2026-10-12 00:04:22 +03:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: WealthLedger/backend#66