I have a console app program on .Net core 2.2 to upload a file to the Azure blob storage. It's completely ok and working on my local computer, But when I deploy the app to the Azure app service, it throws an exception with this error:
Could not load file or assembly 'System.Diagnostics.DiagnosticSource, Version=4.0.4.0, Culture=neutral, PublicKeyToken=cc7b13ffcd
the problem is on this line of code:
BlobServiceClient storageAccount = new BlobServiceClient("connection string")
I tried to change the versions of System.Diagnostics.DiagnosticSource and Azure.Storage.Blobs but it didn't work on the Azure app service
Edit: I didn't find any solution for the problem, I change the code so that use Azure storage from the aps.net core app.