Skip to content

Clarify StatusCodePages ProblemDetails docs#66172

Merged
mikekistler merged 7 commits intodotnet:mainfrom
mikekistler:docs/clarify-statuscodepages-problemdetails
Apr 16, 2026
Merged

Clarify StatusCodePages ProblemDetails docs#66172
mikekistler merged 7 commits intodotnet:mainfrom
mikekistler:docs/clarify-statuscodepages-problemdetails

Conversation

@mikekistler
Copy link
Copy Markdown
Contributor

Summary

  • clarify that UseStatusCodePages() and the default options handler prefer Problem Details when IProblemDetailsService is available
  • document the plain-text fallback behavior in the XML comments

Copilot AI review requested due to automatic review settings April 6, 2026 16:11
@github-actions github-actions Bot added the area-middleware Includes: URL rewrite, redirect, response cache/compression, session, and other general middlewares label Apr 6, 2026
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR updates the XML documentation for Status Code Pages to clarify that the default handler prefers emitting ProblemDetails (via IProblemDetailsService) and otherwise falls back to a plain-text response.

Changes:

  • Updated StatusCodePagesOptions XML docs to describe the ProblemDetails-first behavior and fallback conditions.
  • Updated UseStatusCodePages() XML docs to describe default handler behavior (ProblemDetails vs plain text).

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.

File Description
src/Middleware/Diagnostics/src/StatusCodePage/StatusCodePagesOptions.cs Clarifies the default HandleAsync behavior: try IProblemDetailsService, then fall back to plain text.
src/Middleware/Diagnostics/src/StatusCodePage/StatusCodePagesExtensions.cs Updates UseStatusCodePages() docs to describe default handler behavior (needs a small accuracy tweak re: fallback).

Comment thread src/Middleware/Diagnostics/src/StatusCodePage/StatusCodePagesExtensions.cs Outdated
mikekistler and others added 2 commits April 13, 2026 09:22
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
@mikekistler mikekistler force-pushed the docs/clarify-statuscodepages-problemdetails branch from 8ad25af to 4200e32 Compare April 13, 2026 17:57
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Comment thread src/Middleware/Diagnostics/src/StatusCodePage/StatusCodePagesOptions.cs Outdated
mikekistler and others added 2 commits April 15, 2026 19:09
@mikekistler mikekistler merged commit 765e192 into dotnet:main Apr 16, 2026
25 checks passed
@dotnet-policy-service dotnet-policy-service Bot added this to the 11.0-preview4 milestone Apr 16, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area-middleware Includes: URL rewrite, redirect, response cache/compression, session, and other general middlewares

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants