Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

AddApiVersioning with a custom IProblemDetailsWriter breaks both the custom and decorated IProblemDetailsWriter #1135

Copy link
Copy link
Open
@EmperorArthur

Description

@EmperorArthur
Issue body actions

Is there an existing issue for this?

  • I have searched the existing issues

Describe the bug

Cross posting from dotnet/aspnetcore#62186

Reported there, since the code explicitly mentions dotnet/aspnetcore#52577.

tldr: TryAddProblemDetailsRfc7231Compliance searches for "DefaultProblemDetailsWriter" but always replaces the first "IProblemDetailsWriter" registered with the service provider.

Expected Behavior

I can use a custom IProblemDetailsWriter before the default writer.

Steps To Reproduce

See dotnet/aspnetcore#62186

Exceptions (if any)

None

.NET Version

9.0.203

Anything else?

See dotnet/aspnetcore#62186

Metadata

Metadata

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions

    Morty Proxy This is a proxified and sanitized view of the page, visit original site.