Could not load type 'Azure.Messaging.MessageContent' from assembly 'Azure.Core'

139 Views Asked by At

I have an azure functions queue trigger. It's working fine locally but not when deployed. In Application Insights I could see the below error message & the queue trigger won't get invoked because of this exception. I had a .netcore 3.1 app with azure functions v3. Even I upgraded it to .net6.0 & azure functions v4. Also, I tried upgrading, downgrading & installing some packages still it didn't resolve the issue.

Error message

How to fix System.TypeLoadException - Could not load type Azure.Messaging.MessageContent from assembly Azure.Core?

1

There are 1 best solutions below

1
On

Ensure your deployed FUNCTIONS_EXTENSION_VERSION matches what's in your function's csproj or it may try to look for packages that are not available on the App Service you've deployed. (See: MS Documentation)