Remove legacy reveal phase paths and rename reveal data loader
This commit is contained in:
23
REVIEW.md
23
REVIEW.md
@@ -11,15 +11,11 @@ Active maintainability risks (priority order):
|
||||
- Cross-feature coupling still exists via shared mutable state usage across UI/data modules (`wwwroot/js/ui.js:180`, `wwwroot/js/ui.js:401`, `wwwroot/js/ui.js:622`, `wwwroot/js/data.js:82`).
|
||||
- Impact: high regression surface and expensive refactors even after removing global `window` bridges.
|
||||
|
||||
2. Legacy phase path remains in active code (Medium)
|
||||
- `Reveal` is still present in `Domain/Phase.cs:6` and compatibility branches remain in `Endpoints/StateEndpoints.cs:102` and `Endpoints/StateEndpoints.cs:111`.
|
||||
- Impact: extra cognitive load and more branches to reason about during phase-flow changes.
|
||||
|
||||
3. Unauthenticated 401 response shape is still framework-driven (Medium)
|
||||
2. Unauthenticated 401 response shape is still framework-driven (Medium)
|
||||
- Endpoint and filter unauthorized responses are standardized when app logic executes (`Infrastructure/AdminOnlyFilter.cs:15`, `Infrastructure/PhaseRequirementFilter.cs:15`, `Endpoints/SuggestEndpoints.cs:18`), but anonymous challenge responses remain middleware-controlled (`GameList.Tests/StateTests.cs:214`).
|
||||
- Impact: clients must tolerate both app-produced problem payloads and framework challenge responses.
|
||||
|
||||
4. Static analysis and frontend lint guardrails are still missing (Medium)
|
||||
3. Static analysis and frontend lint guardrails are still missing (Medium)
|
||||
- CI currently gates restore/build/test only (`.github/workflows/ci.yml:23`-`.github/workflows/ci.yml:29`).
|
||||
- Impact: style drift and low-signal warnings can enter the codebase undetected.
|
||||
|
||||
@@ -33,14 +29,6 @@ Active maintainability risks (priority order):
|
||||
- Effort / Risk: `L / Med`.
|
||||
- Dependencies (if any): none.
|
||||
|
||||
[P1] Remove legacy `Reveal` phase compatibility branches
|
||||
- Problem: Severity `Medium`, Category `Complexity`. Legacy phase compatibility logic is still present in runtime paths.
|
||||
- Evidence: `Domain/Phase.cs:6`, `Endpoints/StateEndpoints.cs:102`, `Endpoints/StateEndpoints.cs:111`, `wwwroot/js/data.js:30`.
|
||||
- Recommendation: remove `Reveal` from enum/transition logic and update affected tests/documentation.
|
||||
- Acceptance criteria (testable): no runtime references to `Phase.Reveal`; phase transitions cover only `Suggest`, `Vote`, and `Results`.
|
||||
- Effort / Risk: `S / Low`.
|
||||
- Dependencies (if any): none.
|
||||
|
||||
[P1] Unify client handling of unauthenticated 401 challenge responses
|
||||
- Problem: Severity `Medium`, Category `API/Contracts`. Fully unauthenticated requests can still bypass application-level problem shaping.
|
||||
- Evidence: challenge behavior is exercised in `GameList.Tests/StateTests.cs:214` while app-level unauthorized shaping is exercised in `GameList.Tests/AuthTests.cs:164`.
|
||||
@@ -68,10 +56,9 @@ Active maintainability risks (priority order):
|
||||
## C) Suggested execution order
|
||||
|
||||
1. Decompose `ui.js` by feature and keep orchestration thin.
|
||||
2. Remove `Reveal` phase compatibility branches.
|
||||
3. Normalize/declare unauthenticated 401 contract behavior.
|
||||
4. Add analyzers + JS lint gates in CI.
|
||||
5. Externalize i18n/FAQ assets.
|
||||
2. Normalize/declare unauthenticated 401 contract behavior.
|
||||
3. Add analyzers + JS lint gates in CI.
|
||||
4. Externalize i18n/FAQ assets.
|
||||
|
||||
## D) Guardrails
|
||||
|
||||
|
||||
Reference in New Issue
Block a user