Hacktoberfest 2026: the issues maintainers tagged for October, open and beginner-friendly. Browse Hacktoberfest issues

xmldoc file detection by assembly from a referenced project

Open
#1,224 3 comments 0 reactions 1 assignee View on GitHub

@commonsensesoftware is already working on this.

Since Sep 5, 2026.

Assessment

This issue has not been assessed yet.

Description

asp.net core enhancement
Is there an existing issue for this?
  • I have searched the existing issues
Describe the bug

I have an issue with xmldocs and assemblies in a situation similar to #1175

  1. .AddApiVersioning.AddOpenApi() is in a Library.csproj
  2. Running code is in App.csproj, which imports the library
  3. BOTH csproj have xmldoc generation enabled

GetAssemblies behaves like this:

callingAssembly = Library
entryAssembly = App
assemblyList = [Library, App]
// assembly list is passed to XmlCommentsFile constructor
for(var i in assemblies)
  if file.exists() return // first wins

so XmlCommentsTransformer ends up with Library.xml instead of App.xml

by the way, is there any documentation on how xmldocs are loaded for referenced projects, nuget packages, etc? i searched for aspnet openapi (not versioned) and they have an unresolved issue that .AddOpenApi triggers an interceptor so this call must be placed in the app directly, not in nuget or other csproj. does versioned openapi do anything about this? i'm asking because it's not clear what default expected behavior should be, and how to customize it, eg load xmldocs for all referenced assemblies if it's not by default.

from the looks of XmlCommentsTransformer there is only one path where xmldoc is loaded from, and service registration does not allow for multiple xml transformers. XmlCommentsFile is internal so it's impossible to register it and pass assemblies directly

Expected Behavior

xmldocs should be loaded for application, all referenced projects and nugets

Steps To Reproduce

No response

Exceptions (if any)

No response

.NET Version

10.0.200

Anything else?

No response

Dominant language
C#
Stars
3.2k
Forks
721
PR merge metrics
No merged PRs in 30d

Getting set up

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from dotnet/aspnet-api-versioning

All issues in dotnet/aspnet-api-versioning

Similar issues

More C# issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.