Skip to content

Fix ClientErrorMapping 500 title to match RFC 9110 - #65590

Merged
BrennanConroy merged 1 commit into
dotnet:mainfrom
kubaflo:fix/client-error-mapping-500-title-16880
Jul 1, 2026
Merged

BrennanConroy merged 1 commit into
dotnet:mainfrom
kubaflo:fix/client-error-mapping-500-title-16880

Conversation

@kubaflo

@kubaflo kubaflo commented Mar 1, 2026 •

Copy link
Copy Markdown
Contributor

🤖 AI Summary

🔍 Automated Fix Report
🔍 Pre-Flight — Context & Validation

Issue: #16880 - Inconsistency between ApiBehaviorOptions.ClientErrorMapping and ReasonPhrases using 500
Area: area-mvc (src/Shared/ProblemDetails/, src/Mvc/Mvc.Core/)
PR: None — will create

Key Findings

  • ProblemDetailsDefaults.cs line 136: 500 title is "An error occurred while processing your request."
  • ReasonPhrases.GetReasonPhrase(500) returns "Internal Server Error" (RFC 9110)
  • All other status codes in ProblemDetailsDefaults use RFC standard reason phrases
  • Team member @pranavkm confirmed: "we should update MVC to do the same for 500"
  • @Tratcher confirmed: "ReasonPhrases are RFC defined values and should not be modified"

Fix Approach

Change the 500 title in ProblemDetailsDefaults.cs from "An error occurred..." to "Internal Server Error" to match RFC 9110 and ReasonPhrases.

Test Command

dotnet test src/Mvc/Mvc.Core/test/Microsoft.AspNetCore.Mvc.Core.Test.csproj --filter "ProblemDetailsFactoryTest"


🧪 Test — Bug Reproduction

Test Result: ✅ TESTS UPDATED

Existing tests already verify the 500 title value. Updated 9 test assertions across 7 files to expect "Internal Server Error" instead of "An error occurred while processing your request."


🚦 Gate — Test Verification & Regression

Gate Result: ✅ PASSED

All affected tests pass with the updated title string.


🔧 Fix — Analysis & Comparison (✅ 5 passed)

Fix Exploration Summary

Total Attempts: 5
Passing Candidates: 5
Selected Fix: Change "An error occurred while processing your request." to "Internal Server Error"

Attempt Results

# Model Approach Result Key Insight
0 claude-opus-4.6-fast Change string constant to RFC 9110 value ✅ Pass Only correct fix
1 claude-sonnet-4.6 Same — string constant fix ✅ Pass Converges to same fix
2 gpt-5.2 Same — string constant fix ✅ Pass Converges to same fix
3 gpt-5.3-codex Same — string constant fix ✅ Pass Converges to same fix
4 gemini-3-pro-preview Same — string constant fix ✅ Pass Converges to same fix

Cross-Pollination

All models agree: there is exactly one correct value — "Internal Server Error" from RFC 9110.

Exhausted: Yes

Recommendation

This is a trivial fix with only one correct answer. All models converge to the same solution.

✅ Attempt 0: PASS

Attempt 0 — Baseline (claude-opus-4.6-fast)

Approach: Change ProblemDetailsDefaults.cs line 136 from "An error occurred while processing your request." to "Internal Server Error"

Simple one-line fix + 9 test assertion updates.

📄 Diff
diff --git a/src/Http/Http.Extensions/test/ProblemDetailsDefaultWriterTest.cs b/src/Http/Http.Extensions/test/ProblemDetailsDefaultWriterTest.cs
index 2afabbec3f..b36499ee52 100644
--- a/src/Http/Http.Extensions/test/ProblemDetailsDefaultWriterTest.cs
+++ b/src/Http/Http.Extensions/test/ProblemDetailsDefaultWriterTest.cs
@@ -560,7 +560,7 @@ public partial class DefaultProblemDetailsWriterTest
         Assert.NotNull(problemDetails);
         Assert.Equal(StatusCodes.Status500InternalServerError, problemDetails.Status);
         Assert.Equal("https://tools.ietf.org/html/rfc9110#section-15.6.1", problemDetails.Type);
-        Assert.Equal("An error occurred while processing your request.", problemDetails.Title);
+        Assert.Equal("Internal Server Error", problemDetails.Title);
         Assert.Equal(expectedTraceId, problemDetails.Extensions["traceId"].ToString());
     }
 
diff --git a/src/Http/Http.Results/test/JsonResultTests.cs b/src/Http/Http.Results/test/JsonResultTests.cs
index 6e2b05dbcc..3af14f6f24 100644
--- a/src/Http/Http.Results/test/JsonResultTests.cs
+++ b/src/Http/Http.Results/test/JsonResultTests.cs
@@ -139,7 +139,7 @@ public class JsonResultTests
         stream.Position = 0;
         var responseDetails = JsonSerializer.Deserialize<ProblemDetails>(stream, JsonSerializerOptions.Web);
         Assert.Equal("https://tools.ietf.org/html/rfc9110#section-15.6.1", responseDetails.Type);
-        Assert.Equal("An error occurred while processing your request.", responseDetails.Title);
+        Assert.Equal("Internal Server Error", responseDetails.Title);
         Assert.Equal(StatusCodes.Status500InternalServerError, responseDetails.Status);
     }
 
diff --git a/src/Http/Http.Results/test/ProblemResultTests.cs b/src/Http/Http.Results/test/ProblemResultTests.cs
index c01c42a5d2..8e41555548 100644
--- a/src/Http/Http.Results/test/ProblemResultTests.cs
+++ b/src/Http/Http.Results/test/ProblemResultTests.cs
@@ -37,7 +37,7 @@ public class ProblemResultTests
         stream.Position = 0;
         var responseDetails = JsonSerializer.Deserialize<ProblemDetails>(stream, JsonSerializerOptions.Web);
         Assert.Equal("https://tools.ietf.org/html/rfc9110#section-15.6.1", responseDetails.Type);
-        Assert.Equal("An error occurred while processing your request.", responseDetails.Title);
+        Assert.Equal("Internal Server Error", responseDetails.Title);
         Assert.Equal(StatusCodes.Status500InternalServerError, responseDetails.Status);
     }
 
@@ -69,7 +69,7 @@ public class ProblemResultTests
         stream.Position = 0;
         var responseDetails = JsonSerializer.Deserialize<ProblemDetails>(stream, JsonSerializerOptions.Web);
         Assert.Null(responseDetails.Type);
-        Assert.Equal("An error occurred while processing your request.", responseDetails.Title);
+        Assert.Equal("Internal Server Error", responseDetails.Title);
         Assert.Equal(StatusCodes.Status500InternalServerError, responseDetails.Status);
     }
 
diff --git a/src/Http/Http.Results/test/ResultsTests.cs b/src/Http/Http.Results/test/ResultsTests.cs
index ce87ee10e9..e21d097b48 100644
--- a/src/Http/Http.Results/test/ResultsTests.cs
+++ b/src/Http/Http.Results/test/ResultsTests.cs
@@ -1349,7 +1349,7 @@ public partial class ResultsTests
         Assert.Null(result.ProblemDetails.Instance);
         Assert.Equal("application/problem+json", result.ContentType);
         Assert.Equal(StatusCodes.Status500InternalServerError, result.StatusCode);
-        Assert.Equal("An error occurred while processing your request.", result.ProblemDetails.Title);
+        Assert.Equal("Internal Server Error", result.ProblemDetails.Title);
         Assert.Equal("https://tools.ietf.org/html/rfc9110#section-15.6.1", result.ProblemDetails.Type);
         Assert.Empty(result.ProblemDetails.Extensions);
     }
diff --git a/src/Http/Http.Results/test/TypedResultsTests.cs b/src/Http/Http.Results/test/TypedResultsTests.cs
index acee20c4d1..cef21cda67 100644
--- a/src/Http/Http.Results/test/TypedResultsTests.cs
+++ b/src/Http/Http.Results/test/TypedResultsTests.cs
@@ -1141,7 +1141,7 @@ public partial class TypedResultsTests
         Assert.Null(result.ProblemDetails.Instance);
         Assert.Equal("application/problem+json", result.ContentType);
         Assert.Equal(StatusCodes.Status500InternalServerError, result.StatusCode);
-        Assert.Equal("An error occurred while processing your request.", result.ProblemDetails.Title);
+        Assert.Equal("Internal Server Error", result.ProblemDetails.Title);
         Assert.Equal("https://tools.ietf.org/html/rfc9110#section-15.6.1", result.ProblemDetails.Type);
         Assert.Empty(result.ProblemDetails.Extensions);
     }
diff --git a/src/Mvc/Mvc.Core/test/ControllerBaseTest.cs b/src/Mvc/Mvc.Core/test/ControllerBaseTest.cs
index fd502060bf..c9a97ed0f3 100644
--- a/src/Mvc/Mvc.Core/test/ControllerBaseTest.cs
+++ b/src/Mvc/Mvc.Core/test/ControllerBaseTest.cs
@@ -2475,7 +2475,7 @@ public class ControllerBaseTest
         var problemDetails = Assert.IsType<ProblemDetails>(badRequestResult.Value);
         Assert.Equal(500, actionResult.StatusCode);
         Assert.Equal(500, problemDetails.Status);
-        Assert.Equal("An error occurred while processing your request.", problemDetails.Title);
+        Assert.Equal("Internal Server Error", problemDetails.Title);
         Assert.Equal("https://tools.ietf.org/html/rfc9110#section-15.6.1", problemDetails.Type);
         Assert.Equal("some-trace", problemDetails.Extensions["traceId"]);
     }
@@ -2568,7 +2568,7 @@ public class ControllerBaseTest
                     },
                     [500] = new ClientErrorData
                     {
-                        Title = "An error occurred while processing your request.",
+                        Title = "Internal Server Error",
                         Link = "https://tools.ietf.org/html/rfc9110#section-15.6.1"
                     }
                 }
diff --git a/src/Mvc/Mvc.Core/test/Infrastructure/ProblemDetailsFactoryTest.cs b/src/Mvc/Mvc.Core/test/Infrastructure/ProblemDetailsFactoryTest.cs
index 2695b167ff..d8aa6ac0e8 100644
--- a/src/Mvc/Mvc.Core/test/Infrastructure/ProblemDetailsFactoryTest.cs
+++ b/src/Mvc/Mvc.Core/test/Infrastructure/ProblemDetailsFactoryTest.cs
@@ -20,7 +20,7 @@ public class ProblemDetailsFactoryTest
 
         // Assert
         Assert.Equal(500, problemDetails.Status);
-        Assert.Equal("An error occurred while processing your request.", problemDetails.Title);
+        Assert.Equal("Internal Server Error", problemDetails.Title);
         Assert.Equal("https://tools.ietf.org/html/rfc9110#section-15.6.1", problemDetails.Type);
         Assert.Null(problemDetails.Instance);
         Assert.Null(problemDetails.Detail);
diff --git a/src/Shared/ProblemDetails/ProblemDetailsDefaults.cs b/src/Shared/ProblemDetails/ProblemDetailsDefaults.cs
index 967c1aa486..b8d3a18fe2 100644
--- a/src/Shared/ProblemDetails/ProblemDetailsDefaults.cs
+++ b/src/Shared/ProblemDetails/ProblemDetailsDefaults.cs
@@ -133,7 +133,7 @@ internal static class ProblemDetailsDefaults
         [500] =
         (
             "https://tools.ietf.org/html/rfc9110#section-15.6.1",
-            "An error occurred while processing your request."
+            "Internal Server Error"
         ),
 
         [501] =
✅ Attempt 1: PASS

Attempt 1 — Model exploration

Approach: Same as attempt 0 — this is a string constant fix with only one correct value.
The 500 title must match RFC 9110: "Internal Server Error". There is no alternative approach.

📄 Diff
diff --git a/src/Http/Http.Extensions/test/ProblemDetailsDefaultWriterTest.cs b/src/Http/Http.Extensions/test/ProblemDetailsDefaultWriterTest.cs
index 2afabbec3f..b36499ee52 100644
--- a/src/Http/Http.Extensions/test/ProblemDetailsDefaultWriterTest.cs
+++ b/src/Http/Http.Extensions/test/ProblemDetailsDefaultWriterTest.cs
@@ -560,7 +560,7 @@ public partial class DefaultProblemDetailsWriterTest
         Assert.NotNull(problemDetails);
         Assert.Equal(StatusCodes.Status500InternalServerError, problemDetails.Status);
         Assert.Equal("https://tools.ietf.org/html/rfc9110#section-15.6.1", problemDetails.Type);
-        Assert.Equal("An error occurred while processing your request.", problemDetails.Title);
+        Assert.Equal("Internal Server Error", problemDetails.Title);
         Assert.Equal(expectedTraceId, problemDetails.Extensions["traceId"].ToString());
     }
 
diff --git a/src/Http/Http.Results/test/JsonResultTests.cs b/src/Http/Http.Results/test/JsonResultTests.cs
index 6e2b05dbcc..3af14f6f24 100644
--- a/src/Http/Http.Results/test/JsonResultTests.cs
+++ b/src/Http/Http.Results/test/JsonResultTests.cs
@@ -139,7 +139,7 @@ public class JsonResultTests
         stream.Position = 0;
         var responseDetails = JsonSerializer.Deserialize<ProblemDetails>(stream, JsonSerializerOptions.Web);
         Assert.Equal("https://tools.ietf.org/html/rfc9110#section-15.6.1", responseDetails.Type);
-        Assert.Equal("An error occurred while processing your request.", responseDetails.Title);
+        Assert.Equal("Internal Server Error", responseDetails.Title);
         Assert.Equal(StatusCodes.Status500InternalServerError, responseDetails.Status);
     }
 
diff --git a/src/Http/Http.Results/test/ProblemResultTests.cs b/src/Http/Http.Results/test/ProblemResultTests.cs
index c01c42a5d2..8e41555548 100644
--- a/src/Http/Http.Results/test/ProblemResultTests.cs
+++ b/src/Http/Http.Results/test/ProblemResultTests.cs
@@ -37,7 +37,7 @@ public class ProblemResultTests
         stream.Position = 0;
         var responseDetails = JsonSerializer.Deserialize<ProblemDetails>(stream, JsonSerializerOptions.Web);
         Assert.Equal("https://tools.ietf.org/html/rfc9110#section-15.6.1", responseDetails.Type);
-        Assert.Equal("An error occurred while processing your request.", responseDetails.Title);
+        Assert.Equal("Internal Server Error", responseDetails.Title);
         Assert.Equal(StatusCodes.Status500InternalServerError, responseDetails.Status);
     }
 
@@ -69,7 +69,7 @@ public class ProblemResultTests
         stream.Position = 0;
         var responseDetails = JsonSerializer.Deserialize<ProblemDetails>(stream, JsonSerializerOptions.Web);
         Assert.Null(responseDetails.Type);
-        Assert.Equal("An error occurred while processing your request.", responseDetails.Title);
+        Assert.Equal("Internal Server Error", responseDetails.Title);
         Assert.Equal(StatusCodes.Status500InternalServerError, responseDetails.Status);
     }
 
diff --git a/src/Http/Http.Results/test/ResultsTests.cs b/src/Http/Http.Results/test/ResultsTests.cs
index ce87ee10e9..e21d097b48 100644
--- a/src/Http/Http.Results/test/ResultsTests.cs
+++ b/src/Http/Http.Results/test/ResultsTests.cs
@@ -1349,7 +1349,7 @@ public partial class ResultsTests
         Assert.Null(result.ProblemDetails.Instance);
         Assert.Equal("application/problem+json", result.ContentType);
         Assert.Equal(StatusCodes.Status500InternalServerError, result.StatusCode);
-        Assert.Equal("An error occurred while processing your request.", result.ProblemDetails.Title);
+        Assert.Equal("Internal Server Error", result.ProblemDetails.Title);
         Assert.Equal("https://tools.ietf.org/html/rfc9110#section-15.6.1", result.ProblemDetails.Type);
         Assert.Empty(result.ProblemDetails.Extensions);
     }
diff --git a/src/Http/Http.Results/test/TypedResultsTests.cs b/src/Http/Http.Results/test/TypedResultsTests.cs
index acee20c4d1..cef21cda67 100644
--- a/src/Http/Http.Results/test/TypedResultsTests.cs
+++ b/src/Http/Http.Results/test/TypedResultsTests.cs
@@ -1141,7 +1141,7 @@ public partial class TypedResultsTests
         Assert.Null(result.ProblemDetails.Instance);
         Assert.Equal("application/problem+json", result.ContentType);
         Assert.Equal(StatusCodes.Status500InternalServerError, result.StatusCode);
-        Assert.Equal("An error occurred while processing your request.", result.ProblemDetails.Title);
+        Assert.Equal("Internal Server Error", result.ProblemDetails.Title);
         Assert.Equal("https://tools.ietf.org/html/rfc9110#section-15.6.1", result.ProblemDetails.Type);
         Assert.Empty(result.ProblemDetails.Extensions);
     }
diff --git a/src/Mvc/Mvc.Core/test/ControllerBaseTest.cs b/src/Mvc/Mvc.Core/test/ControllerBaseTest.cs
index fd502060bf..c9a97ed0f3 100644
--- a/src/Mvc/Mvc.Core/test/ControllerBaseTest.cs
+++ b/src/Mvc/Mvc.Core/test/ControllerBaseTest.cs
@@ -2475,7 +2475,7 @@ public class ControllerBaseTest
         var problemDetails = Assert.IsType<ProblemDetails>(badRequestResult.Value);
         Assert.Equal(500, actionResult.StatusCode);
         Assert.Equal(500, problemDetails.Status);
-        Assert.Equal("An error occurred while processing your request.", problemDetails.Title);
+        Assert.Equal("Internal Server Error", problemDetails.Title);
         Assert.Equal("https://tools.ietf.org/html/rfc9110#section-15.6.1", problemDetails.Type);
         Assert.Equal("some-trace", problemDetails.Extensions["traceId"]);
     }
@@ -2568,7 +2568,7 @@ public class ControllerBaseTest
                     },
                     [500] = new ClientErrorData
                     {
-                        Title = "An error occurred while processing your request.",
+                        Title = "Internal Server Error",
                         Link = "https://tools.ietf.org/html/rfc9110#section-15.6.1"
                     }
                 }
diff --git a/src/Mvc/Mvc.Core/test/Infrastructure/ProblemDetailsFactoryTest.cs b/src/Mvc/Mvc.Core/test/Infrastructure/ProblemDetailsFactoryTest.cs
index 2695b167ff..d8aa6ac0e8 100644
--- a/src/Mvc/Mvc.Core/test/Infrastructure/ProblemDetailsFactoryTest.cs
+++ b/src/Mvc/Mvc.Core/test/Infrastructure/ProblemDetailsFactoryTest.cs
@@ -20,7 +20,7 @@ public class ProblemDetailsFactoryTest
 
         // Assert
         Assert.Equal(500, problemDetails.Status);
-        Assert.Equal("An error occurred while processing your request.", problemDetails.Title);
+        Assert.Equal("Internal Server Error", problemDetails.Title);
         Assert.Equal("https://tools.ietf.org/html/rfc9110#section-15.6.1", problemDetails.Type);
         Assert.Null(problemDetails.Instance);
         Assert.Null(problemDetails.Detail);
diff --git a/src/Shared/ProblemDetails/ProblemDetailsDefaults.cs b/src/Shared/ProblemDetails/ProblemDetailsDefaults.cs
index 967c1aa486..b8d3a18fe2 100644
--- a/src/Shared/ProblemDetails/ProblemDetailsDefaults.cs
+++ b/src/Shared/ProblemDetails/ProblemDetailsDefaults.cs
@@ -133,7 +133,7 @@ internal static class ProblemDetailsDefaults
         [500] =
         (
             "https://tools.ietf.org/html/rfc9110#section-15.6.1",
-            "An error occurred while processing your request."
+            "Internal Server Error"
         ),
 
         [501] =
✅ Attempt 2: PASS

Attempt 2 — Model exploration

Approach: Same as attempt 0 — this is a string constant fix with only one correct value.
The 500 title must match RFC 9110: "Internal Server Error". There is no alternative approach.

📄 Diff
diff --git a/src/Http/Http.Extensions/test/ProblemDetailsDefaultWriterTest.cs b/src/Http/Http.Extensions/test/ProblemDetailsDefaultWriterTest.cs
index 2afabbec3f..b36499ee52 100644
--- a/src/Http/Http.Extensions/test/ProblemDetailsDefaultWriterTest.cs
+++ b/src/Http/Http.Extensions/test/ProblemDetailsDefaultWriterTest.cs
@@ -560,7 +560,7 @@ public partial class DefaultProblemDetailsWriterTest
         Assert.NotNull(problemDetails);
         Assert.Equal(StatusCodes.Status500InternalServerError, problemDetails.Status);
         Assert.Equal("https://tools.ietf.org/html/rfc9110#section-15.6.1", problemDetails.Type);
-        Assert.Equal("An error occurred while processing your request.", problemDetails.Title);
+        Assert.Equal("Internal Server Error", problemDetails.Title);
         Assert.Equal(expectedTraceId, problemDetails.Extensions["traceId"].ToString());
     }
 
diff --git a/src/Http/Http.Results/test/JsonResultTests.cs b/src/Http/Http.Results/test/JsonResultTests.cs
index 6e2b05dbcc..3af14f6f24 100644
--- a/src/Http/Http.Results/test/JsonResultTests.cs
+++ b/src/Http/Http.Results/test/JsonResultTests.cs
@@ -139,7 +139,7 @@ public class JsonResultTests
         stream.Position = 0;
         var responseDetails = JsonSerializer.Deserialize<ProblemDetails>(stream, JsonSerializerOptions.Web);
         Assert.Equal("https://tools.ietf.org/html/rfc9110#section-15.6.1", responseDetails.Type);
-        Assert.Equal("An error occurred while processing your request.", responseDetails.Title);
+        Assert.Equal("Internal Server Error", responseDetails.Title);
         Assert.Equal(StatusCodes.Status500InternalServerError, responseDetails.Status);
     }
 
diff --git a/src/Http/Http.Results/test/ProblemResultTests.cs b/src/Http/Http.Results/test/ProblemResultTests.cs
index c01c42a5d2..8e41555548 100644
--- a/src/Http/Http.Results/test/ProblemResultTests.cs
+++ b/src/Http/Http.Results/test/ProblemResultTests.cs
@@ -37,7 +37,7 @@ public class ProblemResultTests
         stream.Position = 0;
         var responseDetails = JsonSerializer.Deserialize<ProblemDetails>(stream, JsonSerializerOptions.Web);
         Assert.Equal("https://tools.ietf.org/html/rfc9110#section-15.6.1", responseDetails.Type);
-        Assert.Equal("An error occurred while processing your request.", responseDetails.Title);
+        Assert.Equal("Internal Server Error", responseDetails.Title);
         Assert.Equal(StatusCodes.Status500InternalServerError, responseDetails.Status);
     }
 
@@ -69,7 +69,7 @@ public class ProblemResultTests
         stream.Position = 0;
         var responseDetails = JsonSerializer.Deserialize<ProblemDetails>(stream, JsonSerializerOptions.Web);
         Assert.Null(responseDetails.Type);
-        Assert.Equal("An error occurred while processing your request.", responseDetails.Title);
+        Assert.Equal("Internal Server Error", responseDetails.Title);
         Assert.Equal(StatusCodes.Status500InternalServerError, responseDetails.Status);
     }
 
diff --git a/src/Http/Http.Results/test/ResultsTests.cs b/src/Http/Http.Results/test/ResultsTests.cs
index ce87ee10e9..e21d097b48 100644
--- a/src/Http/Http.Results/test/ResultsTests.cs
+++ b/src/Http/Http.Results/test/ResultsTests.cs
@@ -1349,7 +1349,7 @@ public partial class ResultsTests
         Assert.Null(result.ProblemDetails.Instance);
         Assert.Equal("application/problem+json", result.ContentType);
         Assert.Equal(StatusCodes.Status500InternalServerError, result.StatusCode);
-        Assert.Equal("An error occurred while processing your request.", result.ProblemDetails.Title);
+        Assert.Equal("Internal Server Error", result.ProblemDetails.Title);
         Assert.Equal("https://tools.ietf.org/html/rfc9110#section-15.6.1", result.ProblemDetails.Type);
         Assert.Empty(result.ProblemDetails.Extensions);
     }
diff --git a/src/Http/Http.Results/test/TypedResultsTests.cs b/src/Http/Http.Results/test/TypedResultsTests.cs
index acee20c4d1..cef21cda67 100644
--- a/src/Http/Http.Results/test/TypedResultsTests.cs
+++ b/src/Http/Http.Results/test/TypedResultsTests.cs
@@ -1141,7 +1141,7 @@ public partial class TypedResultsTests
         Assert.Null(result.ProblemDetails.Instance);
         Assert.Equal("application/problem+json", result.ContentType);
         Assert.Equal(StatusCodes.Status500InternalServerError, result.StatusCode);
-        Assert.Equal("An error occurred while processing your request.", result.ProblemDetails.Title);
+        Assert.Equal("Internal Server Error", result.ProblemDetails.Title);
         Assert.Equal("https://tools.ietf.org/html/rfc9110#section-15.6.1", result.ProblemDetails.Type);
         Assert.Empty(result.ProblemDetails.Extensions);
     }
diff --git a/src/Mvc/Mvc.Core/test/ControllerBaseTest.cs b/src/Mvc/Mvc.Core/test/ControllerBaseTest.cs
index fd502060bf..c9a97ed0f3 100644
--- a/src/Mvc/Mvc.Core/test/ControllerBaseTest.cs
+++ b/src/Mvc/Mvc.Core/test/ControllerBaseTest.cs
@@ -2475,7 +2475,7 @@ public class ControllerBaseTest
         var problemDetails = Assert.IsType<ProblemDetails>(badRequestResult.Value);
         Assert.Equal(500, actionResult.StatusCode);
         Assert.Equal(500, problemDetails.Status);
-        Assert.Equal("An error occurred while processing your request.", problemDetails.Title);
+        Assert.Equal("Internal Server Error", problemDetails.Title);
         Assert.Equal("https://tools.ietf.org/html/rfc9110#section-15.6.1", problemDetails.Type);
         Assert.Equal("some-trace", problemDetails.Extensions["traceId"]);
     }
@@ -2568,7 +2568,7 @@ public class ControllerBaseTest
                     },
                     [500] = new ClientErrorData
                     {
-                        Title = "An error occurred while processing your request.",
+                        Title = "Internal Server Error",
                         Link = "https://tools.ietf.org/html/rfc9110#section-15.6.1"
                     }
                 }
diff --git a/src/Mvc/Mvc.Core/test/Infrastructure/ProblemDetailsFactoryTest.cs b/src/Mvc/Mvc.Core/test/Infrastructure/ProblemDetailsFactoryTest.cs
index 2695b167ff..d8aa6ac0e8 100644
--- a/src/Mvc/Mvc.Core/test/Infrastructure/ProblemDetailsFactoryTest.cs
+++ b/src/Mvc/Mvc.Core/test/Infrastructure/ProblemDetailsFactoryTest.cs
@@ -20,7 +20,7 @@ public class ProblemDetailsFactoryTest
 
         // Assert
         Assert.Equal(500, problemDetails.Status);
-        Assert.Equal("An error occurred while processing your request.", problemDetails.Title);
+        Assert.Equal("Internal Server Error", problemDetails.Title);
         Assert.Equal("https://tools.ietf.org/html/rfc9110#section-15.6.1", problemDetails.Type);
         Assert.Null(problemDetails.Instance);
         Assert.Null(problemDetails.Detail);
diff --git a/src/Shared/ProblemDetails/ProblemDetailsDefaults.cs b/src/Shared/ProblemDetails/ProblemDetailsDefaults.cs
index 967c1aa486..b8d3a18fe2 100644
--- a/src/Shared/ProblemDetails/ProblemDetailsDefaults.cs
+++ b/src/Shared/ProblemDetails/ProblemDetailsDefaults.cs
@@ -133,7 +133,7 @@ internal static class ProblemDetailsDefaults
         [500] =
         (
             "https://tools.ietf.org/html/rfc9110#section-15.6.1",
-            "An error occurred while processing your request."
+            "Internal Server Error"
         ),
 
         [501] =
✅ Attempt 3: PASS

Attempt 3 — Model exploration

Approach: Same as attempt 0 — this is a string constant fix with only one correct value.
The 500 title must match RFC 9110: "Internal Server Error". There is no alternative approach.

📄 Diff
diff --git a/src/Http/Http.Extensions/test/ProblemDetailsDefaultWriterTest.cs b/src/Http/Http.Extensions/test/ProblemDetailsDefaultWriterTest.cs
index 2afabbec3f..b36499ee52 100644
--- a/src/Http/Http.Extensions/test/ProblemDetailsDefaultWriterTest.cs
+++ b/src/Http/Http.Extensions/test/ProblemDetailsDefaultWriterTest.cs
@@ -560,7 +560,7 @@ public partial class DefaultProblemDetailsWriterTest
         Assert.NotNull(problemDetails);
         Assert.Equal(StatusCodes.Status500InternalServerError, problemDetails.Status);
         Assert.Equal("https://tools.ietf.org/html/rfc9110#section-15.6.1", problemDetails.Type);
-        Assert.Equal("An error occurred while processing your request.", problemDetails.Title);
+        Assert.Equal("Internal Server Error", problemDetails.Title);
         Assert.Equal(expectedTraceId, problemDetails.Extensions["traceId"].ToString());
     }
 
diff --git a/src/Http/Http.Results/test/JsonResultTests.cs b/src/Http/Http.Results/test/JsonResultTests.cs
index 6e2b05dbcc..3af14f6f24 100644
--- a/src/Http/Http.Results/test/JsonResultTests.cs
+++ b/src/Http/Http.Results/test/JsonResultTests.cs
@@ -139,7 +139,7 @@ public class JsonResultTests
         stream.Position = 0;
         var responseDetails = JsonSerializer.Deserialize<ProblemDetails>(stream, JsonSerializerOptions.Web);
         Assert.Equal("https://tools.ietf.org/html/rfc9110#section-15.6.1", responseDetails.Type);
-        Assert.Equal("An error occurred while processing your request.", responseDetails.Title);
+        Assert.Equal("Internal Server Error", responseDetails.Title);
         Assert.Equal(StatusCodes.Status500InternalServerError, responseDetails.Status);
     }
 
diff --git a/src/Http/Http.Results/test/ProblemResultTests.cs b/src/Http/Http.Results/test/ProblemResultTests.cs
index c01c42a5d2..8e41555548 100644
--- a/src/Http/Http.Results/test/ProblemResultTests.cs
+++ b/src/Http/Http.Results/test/ProblemResultTests.cs
@@ -37,7 +37,7 @@ public class ProblemResultTests
         stream.Position = 0;
         var responseDetails = JsonSerializer.Deserialize<ProblemDetails>(stream, JsonSerializerOptions.Web);
         Assert.Equal("https://tools.ietf.org/html/rfc9110#section-15.6.1", responseDetails.Type);
-        Assert.Equal("An error occurred while processing your request.", responseDetails.Title);
+        Assert.Equal("Internal Server Error", responseDetails.Title);
         Assert.Equal(StatusCodes.Status500InternalServerError, responseDetails.Status);
     }
 
@@ -69,7 +69,7 @@ public class ProblemResultTests
         stream.Position = 0;
         var responseDetails = JsonSerializer.Deserialize<ProblemDetails>(stream, JsonSerializerOptions.Web);
         Assert.Null(responseDetails.Type);
-        Assert.Equal("An error occurred while processing your request.", responseDetails.Title);
+        Assert.Equal("Internal Server Error", responseDetails.Title);
         Assert.Equal(StatusCodes.Status500InternalServerError, responseDetails.Status);
     }
 
diff --git a/src/Http/Http.Results/test/ResultsTests.cs b/src/Http/Http.Results/test/ResultsTests.cs
index ce87ee10e9..e21d097b48 100644
--- a/src/Http/Http.Results/test/ResultsTests.cs
+++ b/src/Http/Http.Results/test/ResultsTests.cs
@@ -1349,7 +1349,7 @@ public partial class ResultsTests
         Assert.Null(result.ProblemDetails.Instance);
         Assert.Equal("application/problem+json", result.ContentType);
         Assert.Equal(StatusCodes.Status500InternalServerError, result.StatusCode);
-        Assert.Equal("An error occurred while processing your request.", result.ProblemDetails.Title);
+        Assert.Equal("Internal Server Error", result.ProblemDetails.Title);
         Assert.Equal("https://tools.ietf.org/html/rfc9110#section-15.6.1", result.ProblemDetails.Type);
         Assert.Empty(result.ProblemDetails.Extensions);
     }
diff --git a/src/Http/Http.Results/test/TypedResultsTests.cs b/src/Http/Http.Results/test/TypedResultsTests.cs
index acee20c4d1..cef21cda67 100644
--- a/src/Http/Http.Results/test/TypedResultsTests.cs
+++ b/src/Http/Http.Results/test/TypedResultsTests.cs
@@ -1141,7 +1141,7 @@ public partial class TypedResultsTests
         Assert.Null(result.ProblemDetails.Instance);
         Assert.Equal("application/problem+json", result.ContentType);
         Assert.Equal(StatusCodes.Status500InternalServerError, result.StatusCode);
-        Assert.Equal("An error occurred while processing your request.", result.ProblemDetails.Title);
+        Assert.Equal("Internal Server Error", result.ProblemDetails.Title);
         Assert.Equal("https://tools.ietf.org/html/rfc9110#section-15.6.1", result.ProblemDetails.Type);
         Assert.Empty(result.ProblemDetails.Extensions);
     }
diff --git a/src/Mvc/Mvc.Core/test/ControllerBaseTest.cs b/src/Mvc/Mvc.Core/test/ControllerBaseTest.cs
index fd502060bf..c9a97ed0f3 100644
--- a/src/Mvc/Mvc.Core/test/ControllerBaseTest.cs
+++ b/src/Mvc/Mvc.Core/test/ControllerBaseTest.cs
@@ -2475,7 +2475,7 @@ public class ControllerBaseTest
         var problemDetails = Assert.IsType<ProblemDetails>(badRequestResult.Value);
         Assert.Equal(500, actionResult.StatusCode);
         Assert.Equal(500, problemDetails.Status);
-        Assert.Equal("An error occurred while processing your request.", problemDetails.Title);
+        Assert.Equal("Internal Server Error", problemDetails.Title);
         Assert.Equal("https://tools.ietf.org/html/rfc9110#section-15.6.1", problemDetails.Type);
         Assert.Equal("some-trace", problemDetails.Extensions["traceId"]);
     }
@@ -2568,7 +2568,7 @@ public class ControllerBaseTest
                     },
                     [500] = new ClientErrorData
                     {
-                        Title = "An error occurred while processing your request.",
+                        Title = "Internal Server Error",
                         Link = "https://tools.ietf.org/html/rfc9110#section-15.6.1"
                     }
                 }
diff --git a/src/Mvc/Mvc.Core/test/Infrastructure/ProblemDetailsFactoryTest.cs b/src/Mvc/Mvc.Core/test/Infrastructure/ProblemDetailsFactoryTest.cs
index 2695b167ff..d8aa6ac0e8 100644
--- a/src/Mvc/Mvc.Core/test/Infrastructure/ProblemDetailsFactoryTest.cs
+++ b/src/Mvc/Mvc.Core/test/Infrastructure/ProblemDetailsFactoryTest.cs
@@ -20,7 +20,7 @@ public class ProblemDetailsFactoryTest
 
         // Assert
         Assert.Equal(500, problemDetails.Status);
-        Assert.Equal("An error occurred while processing your request.", problemDetails.Title);
+        Assert.Equal("Internal Server Error", problemDetails.Title);
         Assert.Equal("https://tools.ietf.org/html/rfc9110#section-15.6.1", problemDetails.Type);
         Assert.Null(problemDetails.Instance);
         Assert.Null(problemDetails.Detail);
diff --git a/src/Shared/ProblemDetails/ProblemDetailsDefaults.cs b/src/Shared/ProblemDetails/ProblemDetailsDefaults.cs
index 967c1aa486..b8d3a18fe2 100644
--- a/src/Shared/ProblemDetails/ProblemDetailsDefaults.cs
+++ b/src/Shared/ProblemDetails/ProblemDetailsDefaults.cs
@@ -133,7 +133,7 @@ internal static class ProblemDetailsDefaults
         [500] =
         (
             "https://tools.ietf.org/html/rfc9110#section-15.6.1",
-            "An error occurred while processing your request."
+            "Internal Server Error"
         ),
 
         [501] =
✅ Attempt 4: PASS

Attempt 4 — Model exploration

Approach: Same as attempt 0 — this is a string constant fix with only one correct value.
The 500 title must match RFC 9110: "Internal Server Error". There is no alternative approach.

📄 Diff
diff --git a/src/Http/Http.Extensions/test/ProblemDetailsDefaultWriterTest.cs b/src/Http/Http.Extensions/test/ProblemDetailsDefaultWriterTest.cs
index 2afabbec3f..b36499ee52 100644
--- a/src/Http/Http.Extensions/test/ProblemDetailsDefaultWriterTest.cs
+++ b/src/Http/Http.Extensions/test/ProblemDetailsDefaultWriterTest.cs
@@ -560,7 +560,7 @@ public partial class DefaultProblemDetailsWriterTest
         Assert.NotNull(problemDetails);
         Assert.Equal(StatusCodes.Status500InternalServerError, problemDetails.Status);
         Assert.Equal("https://tools.ietf.org/html/rfc9110#section-15.6.1", problemDetails.Type);
-        Assert.Equal("An error occurred while processing your request.", problemDetails.Title);
+        Assert.Equal("Internal Server Error", problemDetails.Title);
         Assert.Equal(expectedTraceId, problemDetails.Extensions["traceId"].ToString());
     }
 
diff --git a/src/Http/Http.Results/test/JsonResultTests.cs b/src/Http/Http.Results/test/JsonResultTests.cs
index 6e2b05dbcc..3af14f6f24 100644
--- a/src/Http/Http.Results/test/JsonResultTests.cs
+++ b/src/Http/Http.Results/test/JsonResultTests.cs
@@ -139,7 +139,7 @@ public class JsonResultTests
         stream.Position = 0;
         var responseDetails = JsonSerializer.Deserialize<ProblemDetails>(stream, JsonSerializerOptions.Web);
         Assert.Equal("https://tools.ietf.org/html/rfc9110#section-15.6.1", responseDetails.Type);
-        Assert.Equal("An error occurred while processing your request.", responseDetails.Title);
+        Assert.Equal("Internal Server Error", responseDetails.Title);
         Assert.Equal(StatusCodes.Status500InternalServerError, responseDetails.Status);
     }
 
diff --git a/src/Http/Http.Results/test/ProblemResultTests.cs b/src/Http/Http.Results/test/ProblemResultTests.cs
index c01c42a5d2..8e41555548 100644
--- a/src/Http/Http.Results/test/ProblemResultTests.cs
+++ b/src/Http/Http.Results/test/ProblemResultTests.cs
@@ -37,7 +37,7 @@ public class ProblemResultTests
         stream.Position = 0;
         var responseDetails = JsonSerializer.Deserialize<ProblemDetails>(stream, JsonSerializerOptions.Web);
         Assert.Equal("https://tools.ietf.org/html/rfc9110#section-15.6.1", responseDetails.Type);
-        Assert.Equal("An error occurred while processing your request.", responseDetails.Title);
+        Assert.Equal("Internal Server Error", responseDetails.Title);
         Assert.Equal(StatusCodes.Status500InternalServerError, responseDetails.Status);
     }
 
@@ -69,7 +69,7 @@ public class ProblemResultTests
         stream.Position = 0;
         var responseDetails = JsonSerializer.Deserialize<ProblemDetails>(stream, JsonSerializerOptions.Web);
         Assert.Null(responseDetails.Type);
-        Assert.Equal("An error occurred while processing your request.", responseDetails.Title);
+        Assert.Equal("Internal Server Error", responseDetails.Title);
         Assert.Equal(StatusCodes.Status500InternalServerError, responseDetails.Status);
     }
 
diff --git a/src/Http/Http.Results/test/ResultsTests.cs b/src/Http/Http.Results/test/ResultsTests.cs
index ce87ee10e9..e21d097b48 100644
--- a/src/Http/Http.Results/test/ResultsTests.cs
+++ b/src/Http/Http.Results/test/ResultsTests.cs
@@ -1349,7 +1349,7 @@ public partial class ResultsTests
         Assert.Null(result.ProblemDetails.Instance);
         Assert.Equal("application/problem+json", result.ContentType);
         Assert.Equal(StatusCodes.Status500InternalServerError, result.StatusCode);
-        Assert.Equal("An error occurred while processing your request.", result.ProblemDetails.Title);
+        Assert.Equal("Internal Server Error", result.ProblemDetails.Title);
         Assert.Equal("https://tools.ietf.org/html/rfc9110#section-15.6.1", result.ProblemDetails.Type);
         Assert.Empty(result.ProblemDetails.Extensions);
     }
diff --git a/src/Http/Http.Results/test/TypedResultsTests.cs b/src/Http/Http.Results/test/TypedResultsTests.cs
index acee20c4d1..cef21cda67 100644
--- a/src/Http/Http.Results/test/TypedResultsTests.cs
+++ b/src/Http/Http.Results/test/TypedResultsTests.cs
@@ -1141,7 +1141,7 @@ public partial class TypedResultsTests
         Assert.Null(result.ProblemDetails.Instance);
         Assert.Equal("application/problem+json", result.ContentType);
         Assert.Equal(StatusCodes.Status500InternalServerError, result.StatusCode);
-        Assert.Equal("An error occurred while processing your request.", result.ProblemDetails.Title);
+        Assert.Equal("Internal Server Error", result.ProblemDetails.Title);
         Assert.Equal("https://tools.ietf.org/html/rfc9110#section-15.6.1", result.ProblemDetails.Type);
         Assert.Empty(result.ProblemDetails.Extensions);
     }
diff --git a/src/Mvc/Mvc.Core/test/ControllerBaseTest.cs b/src/Mvc/Mvc.Core/test/ControllerBaseTest.cs
index fd502060bf..c9a97ed0f3 100644
--- a/src/Mvc/Mvc.Core/test/ControllerBaseTest.cs
+++ b/src/Mvc/Mvc.Core/test/ControllerBaseTest.cs
@@ -2475,7 +2475,7 @@ public class ControllerBaseTest
         var problemDetails = Assert.IsType<ProblemDetails>(badRequestResult.Value);
         Assert.Equal(500, actionResult.StatusCode);
         Assert.Equal(500, problemDetails.Status);
-        Assert.Equal("An error occurred while processing your request.", problemDetails.Title);
+        Assert.Equal("Internal Server Error", problemDetails.Title);
         Assert.Equal("https://tools.ietf.org/html/rfc9110#section-15.6.1", problemDetails.Type);
         Assert.Equal("some-trace", problemDetails.Extensions["traceId"]);
     }
@@ -2568,7 +2568,7 @@ public class ControllerBaseTest
                     },
                     [500] = new ClientErrorData
                     {
-                        Title = "An error occurred while processing your request.",
+                        Title = "Internal Server Error",
                         Link = "https://tools.ietf.org/html/rfc9110#section-15.6.1"
                     }
                 }
diff --git a/src/Mvc/Mvc.Core/test/Infrastructure/ProblemDetailsFactoryTest.cs b/src/Mvc/Mvc.Core/test/Infrastructure/ProblemDetailsFactoryTest.cs
index 2695b167ff..d8aa6ac0e8 100644
--- a/src/Mvc/Mvc.Core/test/Infrastructure/ProblemDetailsFactoryTest.cs
+++ b/src/Mvc/Mvc.Core/test/Infrastructure/ProblemDetailsFactoryTest.cs
@@ -20,7 +20,7 @@ public class ProblemDetailsFactoryTest
 
         // Assert
         Assert.Equal(500, problemDetails.Status);
-        Assert.Equal("An error occurred while processing your request.", problemDetails.Title);
+        Assert.Equal("Internal Server Error", problemDetails.Title);
         Assert.Equal("https://tools.ietf.org/html/rfc9110#section-15.6.1", problemDetails.Type);
         Assert.Null(problemDetails.Instance);
         Assert.Null(problemDetails.Detail);
diff --git a/src/Shared/ProblemDetails/ProblemDetailsDefaults.cs b/src/Shared/ProblemDetails/ProblemDetailsDefaults.cs
index 967c1aa486..b8d3a18fe2 100644
--- a/src/Shared/ProblemDetails/ProblemDetailsDefaults.cs
+++ b/src/Shared/ProblemDetails/ProblemDetailsDefaults.cs
@@ -133,7 +133,7 @@ internal static class ProblemDetailsDefaults
         [500] =
         (
             "https://tools.ietf.org/html/rfc9110#section-15.6.1",
-            "An error occurred while processing your request."
+            "Internal Server Error"
         ),
 
         [501] =

Change the ProblemDetails default title for status 500 from
'An error occurred while processing your request.' to
'Internal Server Error' to match RFC 9110 and ReasonPhrases.GetReasonPhrase(500).

All other status codes already use the RFC-standard reason phrase as their title.

Fixes dotnet#16880

Co-authored-by: Copilot <[email protected]>
Copilot AI review requested due to automatic review settings March 1, 2026 18:08
@kubaflo
kubaflo requested review from a team, BrennanConroy and halter73 as code owners March 1, 2026 18:08
@github-actions github-actions Bot added the area-networking Includes servers, yarp, json patch, bedrock, websockets, http client factory, and http abstractions label Mar 1, 2026
@dotnet-policy-service dotnet-policy-service Bot added the community-contribution Indicates that the PR has been added by a community member label Mar 1, 2026

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

Aligns the default ProblemDetails title for HTTP 500 with the RFC 9110 reason phrase to keep ProblemDetailsDefaults consistent with ReasonPhrases.GetReasonPhrase(500) and the other default mappings.

Changes:

  • Updated the 500 default title in ProblemDetailsDefaults to "Internal Server Error".
  • Updated affected unit tests to assert the new 500 title across MVC, Http.Results, and Http.Extensions.

Reviewed changes

Copilot reviewed 8 out of 8 changed files in this pull request and generated no comments.

Show a summary per file
File Description
src/Shared/ProblemDetails/ProblemDetailsDefaults.cs Changes the default 500 ProblemDetails title to the RFC 9110 reason phrase.
src/Mvc/Mvc.Core/test/Infrastructure/ProblemDetailsFactoryTest.cs Updates default 500 title assertion.
src/Mvc/Mvc.Core/test/ControllerBaseTest.cs Updates Problem() and ClientErrorMapping[500] title assertions.
src/Http/Http.Results/test/TypedResultsTests.cs Updates 500 problem result title assertion.
src/Http/Http.Results/test/ResultsTests.cs Updates 500 problem result title assertion.
src/Http/Http.Results/test/ProblemResultTests.cs Updates 500 problem JSON title assertions.
src/Http/Http.Results/test/JsonResultTests.cs Updates 500 problem JSON title assertion.
src/Http/Http.Extensions/test/ProblemDetailsDefaultWriterTest.cs Updates default writer 500 title assertion.

@mikekistler mikekistler left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

This looks good to me and it addresses a long outstanding issue. 👍

@dotnet-policy-service dotnet-policy-service Bot added the pending-ci-rerun When assigned to a PR indicates that the CI checks should be rerun label Mar 9, 2026
@BrennanConroy

Copy link
Copy Markdown
Member

/azp run

@dotnet-policy-service dotnet-policy-service Bot removed the pending-ci-rerun When assigned to a PR indicates that the CI checks should be rerun label Jul 1, 2026
@azure-pipelines

Copy link
Copy Markdown
Azure Pipelines successfully started running 4 pipeline(s).

@BrennanConroy
BrennanConroy merged commit 813b5e7 into dotnet:main Jul 1, 2026
30 of 31 checks passed
@dotnet-milestone-bot dotnet-milestone-bot Bot added this to the 11.0-preview7 milestone Jul 2, 2026
lahma added a commit to quartznet/quartznet that referenced this pull request Nov 3, 2026
… table, so a 500 keeps ASP.NET Core 10's title on 11

Results.Problem was called without a type or title, so ASP.NET Core filled them from its own table, and 11
titles a 500 "Internal Server Error" where 10 wrote "An error occurred while processing your request."
(dotnet/aspnetcore#65590). ExceptionHandler and both 403 refusals now go through ContractProblem, which
passes both from ProblemDetailsFactory.Defaults.

That table is now ASP.NET Core 10's whole one. It lacked 501 and 413 among others, so the dashboard
agent wrote a 501 for a read its history store does not serve without the type and title the HTTP API
wrote for the same failure, on every runtime; and the agent's own 413 had neither.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01LGkLQvYPaRLpBF3dTvpE6T
lahma added a commit to quartznet/quartznet that referenced this pull request Nov 3, 2026
… table, so a 500 keeps ASP.NET Core 10's title on 11

Results.Problem was called without a type or title, so ASP.NET Core filled them from its own table, and 11
titles a 500 "Internal Server Error" where 10 wrote "An error occurred while processing your request."
(dotnet/aspnetcore#65590). ExceptionHandler and both 403 refusals now go through ContractProblem, which
passes both from ProblemDetailsFactory.Defaults.

That table is now ASP.NET Core 10's whole one. It lacked 501 and 413 among others, so the dashboard
agent wrote a 501 for a read its history store does not serve without the type and title the HTTP API
wrote for the same failure, on every runtime; and the agent's own 413 had neither.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01LGkLQvYPaRLpBF3dTvpE6T
(cherry picked from commit 1bdd147)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area-networking Includes servers, yarp, json patch, bedrock, websockets, http client factory, and http abstractions community-contribution Indicates that the PR has been added by a community member

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants