Could not load file or assembly 'System.IdentityModel.Tokens.Jwt after deploying on Azure

I have figured it out. I updated System.IdentityModel.Tokens.Jwt reference via nuget package manager and it works again.

Regards!


There is a known issue in Azure Functions host: https://github.com/Azure/azure-functions-host/issues/5894

The current workaround is to add the following to your .csproj:

<PropertyGroup>
  <_FunctionsSkipCleanOutput>true</_FunctionsSkipCleanOutput>
</PropertyGroup>