dotnet / dotnet/aspnetcore

Application fails to start when setting custom ApplicationName

Open
#58,403 9 comments 2 reactions 0 assignees View on GitHub
area-mvc
Dominant language
C#
Stars
38.4k
Forks
10.9k
Avg merge
2d 10h
Merged PRs (30d)
281

Description

> @captainsafia , @gfoidl , please have a closer look at the problem @Toudahl is complaining.
>
> Here is the problematic part in `Microsoft.Extensions.DependencyInjection.MvcCoreServiceCollectionExtensions`
>
>
> ![Image](https://github.com/user-attachments/assets/55fd9fd3-1ac0-48fa-9e8a-d08e3f9cccd8)
>
> **The fact that the value is set by default to the entry-point assembly name, doesn't allow to treat the `ApplicationName` as assembly name and try loading it !!!**
>
> This is breaking change that is not even documented.
>
> Also, even though the `manager` instance could be provided via `DI`, the `PopulateDefaultParts` method is **internal** !!! and not marked as `override` - I hardly understand the reason behind letting user to injects their own implementation if he can't provide his own implementation of `PopulateDefaultParts` method.
>
> Please reopen and provide estimations for the fix.
> Thanks

_Originally posted by @jvmlet in [#53791](https://github.com/dotnet/aspnetcore/issues/53791#issuecomment-2401780142)_

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.