locked
Azure functions - started failing without warning RRS feed

  • Question

  • Existing azure functions that query the graph API using the constructor "new UserPasswordCredential(o365Email, passWord)" suddenly stopped working without warning. These functions were previously working and nothing had changed. The only symptom was that apps using them started failing. The error message is below.

    Exception while executing function: Functions.CheckEmailReceived. Microsoft.Azure.WebJobs.Script: One or more errors occurred. f-CheckEmailReceived__744912722: The type initializer for 'Microsoft.IdentityModel.Clients.ActiveDirectory.AuthenticationContext' threw an exception. Microsoft.IdentityModel.Clients.ActiveDirectory: The type initializer for 'Microsoft.IdentityModel.Clients.ActiveDirectory.PlatformPlugin' threw an exception. Microsoft.IdentityModel.Clients.ActiveDirectory: Assembly required for the platform not found. Make sure assembly 'Microsoft.IdentityModel.Clients.ActiveDirectory.Platform, Version=3.16.0.14, Culture=neutral, PublicKeyToken=31bf3856ad364e35' exists. mscorlib: Could not load file or assembly 'Microsoft.IdentityModel.Clients.ActiveDirectory.Platform, Version=3.16.0.14, Culture=neutral, PublicKeyToken=31bf3856ad364e35' or one of its dependencies. The system cannot find the file specified.		2017-12-20T02:42:27.088 Function completed (Failure, Id=d571841e-bd56-4b86-97a3-498db6863151, Duration=107ms)

    To work around the issue, the version number in each function's project.json "Microsoft.IdentityModel.Clients.ActiveDirectory": "3.16.0" -- was dropped to 3.15.0.

    Does anyone know what might cause this or how to prevent it in future?


    Wednesday, December 20, 2017 5:58 AM

All replies

  • Which version of the runtime are you using?

    Can you provide steps/code to reproduce this?

    Wednesday, December 20, 2017 8:36 PM