Skip to content

feat: Migration toolkit gap detection Server.Transfer, HttpContext.Current.Session, ThreadAbortException#538

Merged
csharpfritz merged 3 commits intoFritzAndFriends:devfrom
csharpfritz:feature/toolkit-gap-detection
Apr 16, 2026
Merged

feat: Migration toolkit gap detection Server.Transfer, HttpContext.Current.Session, ThreadAbortException#538
csharpfritz merged 3 commits intoFritzAndFriends:devfrom
csharpfritz:feature/toolkit-gap-detection

Conversation

@csharpfritz
Copy link
Copy Markdown
Collaborator

Summary

Adds gap detection for Web Forms patterns that have no BWFC shim or require special handling during migration.

CLI Transform Enhancements

  • ServerShimTransform: Detect Server.Transfer/GetLastError/ClearError (no shim, manual rewrite TODOs)
  • SessionDetectTransform: Detect HttpContext.Current.Session[ replace with Session[, emit DI guidance
  • ResponseRedirectTransform: Detect catch(ThreadAbortException) dead code + endResponse=true warnings

Documentation Patches

  • bwfc-migration SKILL.md: Gap patterns section, non-page DI example
  • copilot-instructions-template.md: Gotchas 11-14
  • bwfc-data-migration SKILL.md: ThreadAbortException warning

Tests

  • 15 new unit tests (388 total, all passing)

csharpfritz and others added 3 commits April 14, 2026 17:10
…ion, ThreadAbortException

- ServerShimTransform: detect Server.Transfer(), GetLastError(), ClearError() with NO-SHIM TODOs
- SessionDetectTransform: detect HttpContext.Current.Session[ and replace with Session[
- ResponseRedirectTransform: detect catch(ThreadAbortException) dead code and endResponse=true warnings
- Added 15 new unit tests (388 total, all passing)
- Updated bwfc-migration SKILL.md with gap patterns section
- Updated copilot-instructions-template.md with gotchas 11-14
- Updated bwfc-data-migration SKILL.md with ThreadAbortException warning

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
…tzAndFriends#536)

Update 20 unit tests across 4 test files to match the new shim-first
approach where WebFormsPageBase provides Session, Cache, ClientScript,
Server, and Request shims without requiring [Inject] properties:

- SessionDetectTransformTests: Remove [Inject] assertions, verify
  guidance blocks reference WebFormsPageBase instead
- ClientScriptTransformTests: Replace ClientScriptShim assertions
  with WebFormsPageBase assertions
- RequestFormTransformTests: Replace FormShim with RequestShim
- ServerShimTransformTests: Update guidance text assertion

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
…ritzAndFriends#536

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
@csharpfritz csharpfritz force-pushed the feature/toolkit-gap-detection branch from 4d5bbab to d68de6f Compare April 14, 2026 21:31
@csharpfritz csharpfritz merged commit 0adbb40 into FritzAndFriends:dev Apr 16, 2026
4 checks passed
@csharpfritz csharpfritz deleted the feature/toolkit-gap-detection branch April 16, 2026 01:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant