Azure Function and SharePoint PnP PowerShell are mixing up the client context

Iron Contributor

Hi,

I'm experimenting with Azure Function, Logic apps/Flow to replace an existing SharePoint Workflow.

I've found a weird issue where the client context get mixed up when multiple flows are running in parallel and try to call the azure function. I've found a workaround to overcome this issue by allowing only one job on the azure function environment. It's not a good solution, therefor I want to find the root cause of the following error message :

Exception calling "Load" with "1" argument(s): "The object is used in the context different from the one associated with the object."

Has someone encounter a similar issue?

 

Cheers 

Bernd

 

 

3 Replies
This is interesting, do you know if it's still the case now days?

I'm still having the same issue...
My use case is with getting properties of a SharePoint Online item that was just created with Copy-PnPFile