How to fix StackOverflowException after upgrading from .Net 6 to .Net 8

Abhishek, Burra 5 Reputation points
2024-04-26T06:39:38.71+00:00

Hello,

 

I have upgraded 5 projects in my solution from .Net 6 to .Net 8 using upgrade assistant in Visual Studio.

When I run the solution, StackOverflowException is being thrown and Swagger is not loading. Looks like onchangetokenfired() method is being called many times resulting in infinite loop.

 

Please help in fixing this issue.

User's image

User's image

.NET
.NET
Microsoft Technologies based on the .NET software framework.
3,437 questions
ASP.NET Core
ASP.NET Core
A set of technologies in the .NET Framework for building web applications and XML web services.
4,225 questions
{count} vote