Remove Grace from external DI container conformance tests
- Dominant language
- C#
- Stars
- 18.3k
- Forks
- 5.6k
- PR merge metrics
- PR metrics pending
Description
Drop Grace from `Microsoft.Extensions.DependencyInjection.ExternalContainers.Tests` and the README's list of recognised third-party containers. Grace has now been explicitly sunset by its author. From the Grace README:
> After many years of development I am making the decision to sunset Grace. While it's still possible to use Grace, the evolution of the built-in dependency injection container has made Grace less relevant. […] You can check out my next project that builds on top of the existing Microsoft DI container: https://github.com/ipjohnson/DependencyModules.
| Signal | Value |
| --- | --- |
| Deprecation notice committed | 2025-02-08 |
| Last non-README commit | January 2023 |
| Last open PR ("Support for new .net 8.0 features") | unmerged since Jun 2024 |
| `Grace.DependencyInjection.Extensions` (the MS.DI adapter we depend on) | no release since 7.1.0 |
| `Grace.cs` already skips 3 spec tests + opts out of `IServiceProviderIsService` | yes |
## Steps
1. Remove the `Grace.DependencyInjection.Extensions` `PackageReference` from
`src/libraries/Microsoft.Extensions.DependencyInjection/tests/DI.External.Tests/Microsoft.Extensions.DependencyInjection.ExternalContainers.Tests.csproj`.
2. Delete `src/libraries/Microsoft.Extensions.DependencyInjection/tests/DI.External.Tests/Grace.cs`.
3. Remove the Grace bullet from `src/libraries/Microsoft.Extensions.DependencyInjection/README.md`.
4. Update Microsoft docs section ["Default service container replacement"](https://learn.microsoft.com/en-us/aspnet/core/fundamentals/dependency-injection#default-service-container-replacement) which still lists Grace; that page lives in `dotnet/AspNetCore.Docs` and should be updated separately.
Contributor guide
Assessment
This issue has not been assessed yet.