Skip to content

Conversation

@alex-lutsenko
Copy link
Contributor

@alex-lutsenko alex-lutsenko commented Sep 26, 2025

Configuration Binder Source Generator generates duplicate field names
where the same class name is present in different namespaces.

Fix #119458

Configuration Binder source generator generates duplicate field names
where the same class name is present in different namespaces.

Fix #119458
@dotnet-policy-service dotnet-policy-service bot added the community-contribution Indicates that the PR has been added by a community member label Sep 26, 2025
@dotnet-policy-service
Copy link
Contributor

Tagging subscribers to this area: @dotnet/area-extensions-configuration
See info in area-owners.md if you want to be subscribed.

@alex-lutsenko
Copy link
Contributor Author

@dotnet-policy-service agree

@alex-lutsenko
Copy link
Contributor Author

@tarekgh - please review this.

@alex-lutsenko
Copy link
Contributor Author

I have run dotnet build /p:UpdateBaselines=true for InterceptableAttributeVersion = 0 and it has resulted in every Version 0 file being updated (src\libraries\Microsoft.Extensions.Configuration.Binder\tests\SourceGenerationTests\Baselines ). The changes are not related to my fix. Looks like these baselines are out of date.

Please advise if I should include updated Version 0 baselines in my PR.

@tarekgh tarekgh added this to the 11.0.0 milestone Sep 26, 2025
@tarekgh tarekgh self-assigned this Sep 26, 2025
alex-lutsenko and others added 3 commits September 28, 2025 19:15
NamespaceA name clashes. "SymbolDisplayMiscellaneousOptions.UseSpecialTypes" - is no longer a problem.
Added "___" as generic type delimiter to solve A.BC vs AB.c name clashes.
Shortened maximum identifier length to slightly improve code readability.
Copy link
Member

@tarekgh tarekgh left a comment

Choose a reason for hiding this comment

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

Thanks @alex-lutsenko!

@tarekgh tarekgh merged commit d47e24c into dotnet:main Sep 29, 2025
88 checks passed
@alex-lutsenko
Copy link
Contributor Author

Thank you!

@alex-lutsenko
Copy link
Contributor Author

alex-lutsenko commented Oct 7, 2025

@tarekgh - I do not see my fixes in the latest (10.0.0-rtm.25479.115) for Microsoft.Extensions.Configuration.Binder. Am I missing something? Is it not going to be released in .NET 10?

@tarekgh
Copy link
Member

tarekgh commented Oct 7, 2025

I do not see my fixes in the latest (10.0.0-rtm.25479.115) for Microsoft.Extensions.Configuration.Binder. Am I missing something? Is it not going to be released in .NET 10?

No, this is scheduled for .NET 11. Including it in .NET 10 would be risky since the fix hasn’t been released in any preview, and we can’t guarantee that it won’t introduce side effects.

@github-actions github-actions bot locked and limited conversation to collaborators Nov 7, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

area-Extensions-Configuration 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.

Configuration Binder source generator generates duplicate field names

2 participants