TASK22057: phase18 additional consolidation slices
This commit is contained in:
@@ -1156,3 +1156,61 @@ Validation:
|
||||
Follow-ups:
|
||||
|
||||
- If desired, run additional integrated HTTP/manual checks in an environment with full relay/storage dependencies for end-to-end happy-path confirmation beyond mocked behaviour tests.
|
||||
|
||||
---
|
||||
|
||||
### CL-032: Phase 18 additional consolidation slices — endpoint/file consistency and guard hygiene
|
||||
|
||||
date: 2026-03-14
|
||||
author: Cline
|
||||
scope: `pages/api/endpoint/{deletewatchedcases_api,getaccounts_api,getbasicsearchpaged_api,getappealpdfdocuments_api}.js`, `pages/api/file/{deleteblob,deleteawaitingsubmissionfromblob,getprogressobjblob,getbloblist,createcase_api,updatecase_api,editRepJson}.js`, `tests/phase18/service-behaviour.test.cjs`, `memory-bank/*`
|
||||
type: change
|
||||
rationale: Complete the user-requested three additional small, reversible hardening slices (logging hygiene, hash-guard flow consistency, and required-input guard consistency) without broad refactor or contract drift.
|
||||
impact: Improves consistency of negative-path behavior and reduces noisy logging in selected sensitive handlers while preserving response/signature contracts.
|
||||
status: completed
|
||||
|
||||
Summary:
|
||||
|
||||
- Implemented all three requested additional slices:
|
||||
1. endpoint logging/input hygiene
|
||||
2. file hash-guard flow consistency
|
||||
3. create/update input-guard + logging hygiene
|
||||
- Endpoint updates:
|
||||
- `deletewatchedcases_api`: added required `watchedCaseID` early 400 guard and removed direct URL logging.
|
||||
- `getaccounts_api`: added required `emailAddress` early 400 guard and removed direct query logging.
|
||||
- `getbasicsearchpaged_api`: added required `searchString` early 400 guard and removed noisy query logging.
|
||||
- `getappealpdfdocuments_api`: added required `incidentid` early 400 guard and removed direct URL logging.
|
||||
- File handler updates:
|
||||
- standardized hash-check flow by removing redundant post-validation branches in:
|
||||
- `deleteblob`
|
||||
- `deleteawaitingsubmissionfromblob`
|
||||
- `getprogressobjblob`
|
||||
- `getbloblist`
|
||||
- added required-input early 400 guards in:
|
||||
- `createcase_api` (contact/appealType/container/lpa)
|
||||
- `updatecase_api` (collection/appealObj/incident/body)
|
||||
- removed noisy tag logging in `editRepJson`.
|
||||
- Added focused test pack:
|
||||
- `tests/phase18/service-behaviour.test.cjs` with negative-path and contract-preserving happy-path checks (8/8 pass).
|
||||
|
||||
Validation:
|
||||
|
||||
- `node tests/phase6/service-parity.test.cjs` -> pass
|
||||
- `node tests/phase6/service-behaviour.test.cjs` -> pass (8/8)
|
||||
- `node tests/phase7/service-behaviour.test.cjs` -> pass (12/12)
|
||||
- `node tests/phase8/service-behaviour.test.cjs` -> pass (5/5)
|
||||
- `node tests/phase9/service-behaviour.test.cjs` -> pass (5/5)
|
||||
- `node tests/phase10/service-behaviour.test.cjs` -> pass (5/5)
|
||||
- `node tests/phase11/service-behaviour.test.cjs` -> pass (4/4)
|
||||
- `node tests/phase12/service-behaviour.test.cjs` -> pass (4/4)
|
||||
- `node tests/phase13/service-behaviour.test.cjs` -> pass (7/7)
|
||||
- `node tests/phase14/service-behaviour.test.cjs` -> pass (9/9)
|
||||
- `node tests/phase15/service-behaviour.test.cjs` -> pass (5/5)
|
||||
- `node tests/phase16/service-behaviour.test.cjs` -> pass (4/4)
|
||||
- `node tests/phase17/service-behaviour.test.cjs` -> pass (6/6)
|
||||
- `node tests/phase18/service-behaviour.test.cjs` -> pass (8/8)
|
||||
- `npm run lint` -> warnings only (pre-existing `react-hooks/exhaustive-deps` warnings)
|
||||
|
||||
Follow-ups:
|
||||
|
||||
- Optional: execute integrated manual HTTP matrix for phase-18 touched handlers in an environment with full relay/storage dependencies for non-mocked happy-path verification.
|
||||
|
||||
Reference in New Issue
Block a user