TypeLoadException on web application startup when using Microsoft.AspNetCore.Mvc.Razor.RuntimeCompilation package
- Dominant language
- C#
- Stars
- 38.4k
- Forks
- 10.9k
- Avg merge
- 2d 5h
- Merged PRs (30d)
- 276
Description
### Is there an existing issue for this?
- [X] I have searched the existing issues
### Describe the bug
When using dotnet 8.0.202 we will receive the following error when debugging our web app locally using the Microsoft.AspNetCore.Mvc.Razor.RuntimeCompilation nuget package (8.0.1 or 8.0.3). When runtime compilation is not used it will start up ok:
_TypeLoadException: Type 'd0' from assembly '1mj0wjnl.kmc, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null' tried to override method 'MoveNext' but does not implement or inherit that method._
_Exception thrown: 'System.TypeLoadException' in System.Private.CoreLib.dll_
It would seem the issue does not occur with 8.0.101.
### Expected Behavior
_No response_
### Steps To Reproduce
_No response_
### Exceptions (if any)
_No response_
### .NET Version
8.0.202
### Anything else?
_No response_
Contributor guide
Assessment
This issue has not been assessed yet.