|
31 | 31 | - Run 9 Skill Fixes — 6 RF items across 4 skill files (2026-03-07) |
32 | 32 | - Run 9 RCA Documentation — path preservation + CSS verification rules (2026-03-07) |
33 | 33 |
|
34 | | -### Issue #438: Deprecation Guidance Docs (Latest) |
| 34 | +### Issue #438: Deprecation Guidance Docs |
35 | 35 |
|
36 | 36 | 📌 **Team update (2026-03-17):** #471 & #472 resolved. GUID IDs removed from CheckBox/RadioButton/RadioButtonList; L1 script test suite 100%. 2105 tests passing. — decided by Cyclops |
37 | 37 |
|
38 | | -**Delivered:** Comprehensive deprecation guidance page (`docs/Migration/DeprecationGuidance.md`) covering Web Forms patterns with no Blazor equivalent. |
39 | | - |
40 | | -**Content:** |
41 | | -- `runat="server"` → Blazor native components |
42 | | -- `ViewState` → Component fields + scoped services |
43 | | -- `UpdatePanel` → Blazor's incremental component rendering |
44 | | -- `ScriptManager` → `IJSRuntime` + `HttpClient` |
45 | | -- PostBack events → Component lifecycle + event handlers |
46 | | -- Page lifecycle (`Page_Load`, `Page_Init`) → `OnInitializedAsync`, `OnParametersSetAsync` |
47 | | -- `IsPostBack` → Removed (use `OnInitializedAsync`) |
48 | | -- Server-side control properties → Declarative data binding |
49 | | -- Application/Session state → Singleton/scoped services |
50 | | -- Data binding events (`ItemDataBound`) → Component templates with `@context` |
| 38 | +**✅ DELIVERED** — Comprehensive deprecation guidance page covering Web Forms patterns with no Blazor equivalent. |
51 | 39 |
|
52 | | -**Format:** Before/after tabbed code examples, migration checklist table, lifecycle mapping. |
| 40 | +**Session (2026-03-17 by Beast):** |
| 41 | +- Created `docs/Migration/DeprecationGuidance.md` — 32 KB, ~600 lines covering 8 deprecation patterns |
| 42 | +- Updated `mkdocs.yml` — added "Deprecation Guidance" to Migration navigation section (after "Automated Migration Guide") |
| 43 | +- Created decision record: `.squad/decisions/inbox/beast-deprecation-docs.md` |
53 | 44 |
|
54 | | -**Branch:** `squad/438-deprecation-docs` — pushed to FritzAndFriends upstream. Commit 5b17682b. |
| 45 | +**Content patterns documented:** |
| 46 | +- `runat="server"` — Scope marker; remove (Blazor components always server-side) |
| 47 | +- `ViewState` — Use component fields + scoped/singleton services instead |
| 48 | +- `UpdatePanel` — Blazor incremental rendering makes triggers obsolete; UpdatePanel is now just a CSS-compatible wrapper |
| 49 | +- `Page_Load` / `IsPostBack` → `OnInitializedAsync` + event handlers + lifecycle mapping table |
| 50 | +- `ScriptManager` — Stub for migration compat; replace with `IJSRuntime` + `HttpClient` + DI |
| 51 | +- Server control properties → Reactive data binding (fields, not imperative assignment) |
| 52 | +- Application/Session state → Singleton/scoped services |
| 53 | +- Data binding events (`ItemDataBound`) → Component templates with `@context` |
55 | 54 |
|
56 | | -**Files:** |
57 | | -- Created `docs/Migration/DeprecationGuidance.md` (23.3 KB, ~400 lines) |
58 | | -- Updated `mkdocs.yml` — added to Migration section navigation |
| 55 | +**Format & Tone:** |
| 56 | +- Each pattern: "What It Was" → "Why Deprecated" → "What To Do Instead" + before/after code |
| 57 | +- Tabbed markdown for side-by-side comparison of Web Forms vs Blazor |
| 58 | +- Lifecycle mapping table (Page_Init → OnInitializedAsync, etc.) |
| 59 | +- Empathetic tone — acknowledges these are familiar patterns being left behind |
| 60 | +- Audience: Experienced Web Forms developers learning Blazor |
59 | 61 |
|
60 | | -**Design decision:** Placed after "Automated Migration Guide" in nav to catch developers early in their migration journey. Each section pairs Web Forms pattern with clear Blazor alternative, supporting the library's goal of enabling code reuse with minimal markup changes. |
| 62 | +**Design decision rationale:** |
| 63 | +- Placed after "Automated Migration Guide" in nav — developers run L1 automation first, then encounter these patterns; this doc is their reference |
| 64 | +- Each section pairs Web Forms pattern with clear Blazor alternative — supports library goal of enabling code reuse with minimal markup changes |
| 65 | +- Comprehensive coverage including derived patterns (e.g., application state → services) |
61 | 66 |
|
62 | 67 | **Summary (2026-03-05 through 2026-03-07 pre-Run 11) |
63 | 68 |
|
@@ -159,7 +164,7 @@ Captured three critical Run 22 learnings (39/40 tests passing) in migration skil |
159 | 164 | 1. **Overview** — What `.ashx` handlers are, why migration is needed, `HttpHandlerBase` value proposition |
160 | 165 | 2. **Quick Start** — 6-step migration checklist (mechanical changes) |
161 | 166 | 3. **Registration** — Four registration patterns: |
162 | | - - Explicit path via `[HandlerRoute]` attribute |
| 167 | + - Explicit path via `MapHandler<T>("/path")` in `Program.cs` |
163 | 168 | - Convention-based routing (derive from class name) |
164 | 169 | - Multi-path registration with `MapHandler<T>()` |
165 | 170 | - Chaining auth/CORS with `.RequireAuthorization()`, `.RequireCors()` |
@@ -451,3 +456,110 @@ Updated `.squad/skills/migration-standards/SKILL.md` to add new section at end: |
451 | 456 |
|
452 | 457 |
|
453 | 458 |
|
| 459 | + |
| 460 | +## BaseValidator & BaseCompareValidator Documentation (2026-03-17) |
| 461 | + |
| 462 | + **Session (2026-03-17 by Beast):** |
| 463 | +- Created docs/ValidationControls/BaseValidator.md 6.6 KB comprehensive base class docs covering: |
| 464 | + - Abstract base class overview for all validators |
| 465 | + - Shared properties: ControlToValidate, ControlRef, Display, Text, ErrorMessage, ValidationGroup, Enabled, style properties |
| 466 | + - ForwardRef<InputBase<T>> pattern for Blazor-native field binding |
| 467 | + - Validation lifecycle (EditContext integration, cascading context, registration/validation/cleanup) |
| 468 | + - Child validator references (RequiredFieldValidator, CompareValidator, RangeValidator, RegularExpressionValidator, CustomValidator) |
| 469 | + - Web Forms Blazor comparison with code examples |
| 470 | + |
| 471 | +- Created docs/ValidationControls/BaseCompareValidator.md 6.4 KB docs for comparison-based validators: |
| 472 | + - Abstract base class extending BaseValidator with type conversion and comparison logic |
| 473 | + - Type property with supported types table (String, Integer, Double, Date, Currency) |
| 474 | + - CultureInvariantValues property explanation with practical examples |
| 475 | + - Type conversion and comparison logic documentation |
| 476 | + - Comprehensive examples (Integer, Date, Currency) with real code samples |
| 477 | + - Web Forms Blazor syntax comparison |
| 478 | + - Child validator references (CompareValidator, RangeValidator) |
| 479 | + |
| 480 | +- Updated mkdocs.yml added BaseCompareValidator and BaseValidator alphabetically in Validation Controls section |
| 481 | +- Verified MkDocs build: --strict mode passes with no broken links (55.59 seconds build time) |
| 482 | + |
| 483 | +**Pattern Consistency:** |
| 484 | +- Followed RequiredFieldValidator.md and CompareValidator.md formatting conventions |
| 485 | +- Maintained heading structure: Overview, Properties, Examples, Web Forms comparison, Child references |
| 486 | +- Used property tables for enums (Display, Type values) |
| 487 | +- Included Microsoft documentation links to original Web Forms classes |
| 488 | +- All Blazor code examples shown with EditForm context |
| 489 | + |
| 490 | +**Key Decisions:** |
| 491 | +- BaseValidator docs positioned as "framework for all validators" not a user-facing component |
| 492 | +- Emphasized ControlRef as Blazor-native approach; ControlToValidate as Web Forms migration bridge |
| 493 | +- Type conversion explanation in BaseCompareValidator targets developers migrating numeric/date comparisons |
| 494 | +- CultureInvariantValues documentation included practical locale examples (US "." vs European "," decimals) |
| 495 | + |
| 496 | +**Files:** |
| 497 | +- Created docs/ValidationControls/BaseValidator.md |
| 498 | +- Created docs/ValidationControls/BaseCompareValidator.md |
| 499 | +- Updated mkdocs.yml (Validation Controls section) |
| 500 | + |
| 501 | +### Analyzer Architecture & Expansion Documentation (Feature/analyzer-sprint1) |
| 502 | + |
| 503 | +**Delivered:** Comprehensive analyzer contributor guide and expanded rule documentation for BWFC013 and BWFC014 rules. |
| 504 | + |
| 505 | +**Files created/updated:** |
| 506 | +1. **dev-docs/ANALYZER-ARCHITECTURE.md** (18.7 KB, new) Contributor guide for developing new Roslyn analyzers |
| 507 | +2. **docs/Migration/Analyzers.md** (updated) Added BWFC013 (Response Object Usage) and BWFC014 (Request Object Usage) rule documentation |
| 508 | + |
| 509 | +**ANALYZER-ARCHITECTURE.md content:** |
| 510 | +- **Project Layout** File naming convention, rule ID assignment, directory structure (Analyzers/ and Analyzers.Test/) |
| 511 | +- **DiagnosticAnalyzer anatomy** Minimum viable structure with DiagnosticDescriptor, Initialize(), SyntaxKind callbacks, SeverityLevels (Hidden/Info/Warning/Error) |
| 512 | +- **CodeFixProvider anatomy** BatchFixer pattern, RegisterCodeFixesAsync, trivia preservation, async best practices |
| 513 | +- **Testing strategy** CSharpAnalyzerTest/CSharpCodeFixTest patterns, stub types for external dependencies ({|#N:code|} markers), positive/negative/edge cases |
| 514 | +- **Common pitfalls** Trivia handling (EndOfLine between comment/semicolon), null guards on ancestor traversal, SyntaxKind selection mistakes, string comparisons vs syntax API, message format arguments |
| 515 | +- **PR checklist** Analyzer implementation (7 items), CodeFixProvider (8 items), Testing (6 items), Documentation (5 items), Integration (3 items) |
| 516 | +- **Reference implementation** Points to ResponseRedirectAnalyzer as working example |
| 517 | +- **Build/test commands** dotnet build, test, pack workflows |
| 518 | + |
| 519 | +**Analyzers.md updates:** |
| 520 | +- **Updated summary table** Added BWFC013 and BWFC014 to rule matrix |
| 521 | +- **BWFC013: Response Object Usage** Detects Response.Write(), WriteFile(), Clear(), Flush(), End() |
| 522 | + - Mapping table: Web Forms method Blazor equivalent (markup rendering, FileResult, not needed, not needed, early return) |
| 523 | + - Before/after example: HTML export page markup-based rendering |
| 524 | + - Recommended patterns: component state + markup for write, minimal API endpoint with FileResult for writeFile |
| 525 | +- **BWFC014: Request Object Usage** Detects Request.Form[], Cookies[], Headers[], Files, QueryString[], ServerVariables[] |
| 526 | + - Mapping table: Request collection Blazor equivalent (form binding, HttpContextAccessor, InputFile, nav params, etc.) |
| 527 | + - Before/after example: Page_Load with multiple Request accesses component with recommended patterns |
| 528 | + - Recommended patterns: route parameters (QueryString), @bind (Form), HttpContextAccessor (Cookies/Headers for Blazor Server), InputFile (Files) |
| 529 | +- **"Using Analyzers in CI/CD" section** (new) .editorconfig per-rule severity settings, dotnet build integration, grep for violations in CI scripts |
| 530 | +- **"Prioritization Guide: Which Rules to Fix First"** (new) Phase 1 (Blocking: BWFC001, BWFC003, BWFC004, BWFC011), Phase 2 (Data: BWFC002, BWFC005, BWFC014), Phase 3 (Output: BWFC013, BWFC012, BWFC010) |
| 531 | + |
| 532 | +**Format & style:** |
| 533 | +- Analyzer guide written for experienced C# developers contributing new rules (Cyclops' audience) |
| 534 | +- Analyzers.md entries written for Web Forms developers learning to interpret/fix violations |
| 535 | +- All code examples are complete and compilable (test-driven) |
| 536 | +- Admonitions (!!! note, !!! warning, !!! tip) for actionable insights |
| 537 | +- Before/After pairs show real Web Forms patterns and Blazor migrations |
| 538 | +- Tables for quick reference (SyntaxKind callbacks, mapping tables, phase priorities) |
| 539 | +- Consistent with existing BWFC doc style (Deprecation Guidance, MigratingAshxHandlers) |
| 540 | + |
| 541 | +**MkDocs verification:** |
| 542 | +- Ran python -m mkdocs build --strict 0 errors, 54.08s build time |
| 543 | +- Unshipped analyzer notes already present in AnalyzerReleases.Unshipped.md (BWFC013, BWFC014 added by Cyclops in advance) |
| 544 | +- No documentation links or cross-references broken |
| 545 | + |
| 546 | +**Design decisions:** |
| 547 | +- ANALYZER-ARCHITECTURE.md placed in dev-docs/ (developer-only, not end-user docs) vs docs/ (migration user-facing) |
| 548 | +- Prioritization guide ordered by business impact (blocking patterns first) vs alphabetical, with rationale for each phase |
| 549 | +- CI/CD section emphasizes dotnet build + .editorconfig as the primary integration point, with note that detailed CI templates are "available separately" |
| 550 | +- Request.Form[] @bind example is the most direct mapping; QueryString examples show both route parameters and NavigationManager.Uri approaches |
| 551 | + |
| 552 | +**Audience understanding:** |
| 553 | +- Analyzer rules address code-behind patterns (BWFC001BWFC005: property/state/event patterns; BWFC010BWFC014: specific object usage) |
| 554 | +- Developers see these rules in Visual Studio's Error List after L1 migration script + L2 Copilot transforms |
| 555 | +- Rules guide developers from "code compiles but behaves wrong" (blindspots) to "code compiles and works correctly" (full migration) |
| 556 | +- Prioritization guide helps developers allocate effort, fixing high-impact rules first to unblock testing/UAT |
| 557 | + |
| 558 | +**Branch:** eature/analyzer-sprint1 |
| 559 | +**Tests:** All analyzer tests in Analyzers.Test/ pass (no new analyzer implementations in this doc-only sprint) |
| 560 | +**Verified:** MkDocs build passes strict mode, no broken links or syntax errors in markdown |
| 561 | + |
| 562 | + |
| 563 | + |
| 564 | + **Team update (2026-03-20):** Analyzer architecture guide (579 lines) + expanded Analyzers.md (+363 lines). Deprecation Guidance docs (#438, 32 KB). BaseValidator/BaseCompareValidator base class docs. MkDocs strict build clean. PR #487 opened on upstream. decided by Beast |
| 565 | + |
0 commit comments