microsoft / powercat-automation-kit

Other
68 stars 18 forks source link

[Automation - BUG] Get Solution Artifacts Custom Action seems to have a hardcoded user in it #407

Open bartsneary opened 2 weeks ago

bartsneary commented 2 weeks ago

Describe the issue

In the Satellite solution, when attempting to mark a flow as one to meter, it calls a Cloud Flow that attempts to run a Dataverse action that will retrieve the solution components. When making that call, it always errors with a message that systemuser with Id = e4fcf585-9fa7-ed11-aad1-00224805c3e1 Does Not Exist. Since I'm authenticated to the Dataverse connector as a user that exists and is different from that, my assumption is the action itself has a user hard coded somehow. Not sure how to move forward. Screenshot 2024-06-19 083823 Screenshot 2024-06-19 083742

Expected Behavior

Action would run under the context of the connector's logged on user or there would be instructions for how to set up the right application user to perform this action.

What component are you experiencing the issue with?

Cloud flows

What solution version are you using?

1.0.20230908.4 (latest satellite)

What app or flow are you having the issue with?

Get Dataverse Solution Artifacts

Steps To Reproduce

Attempt to use it (it's called from the Automation Solution Manager App) by trying to meter a flow.

Anything else?

No response

AB#3634

McKiko030 commented 3 days ago

I also experienced the same.

You need to follow this instruction to create a Microsoft Entra app. https://learn.microsoft.com/en-us/power-automate/guidance/automation-kit/setup/satellite#create-a-microsoft-entra-app-registration-to-connect-to-dataverse-web-api

Then, create an application user inside Dataverse, per satellite environment. https://learn.microsoft.com/en-us/power-automate/guidance/automation-kit/setup/satellite#create-an-application-user-inside-dataverse

Get the UserID from the Dataverse table named "User".

You may either update the environment variable "Solution Manager Artifacts Read User Id" to use the UserID of the MS Entra app or delete the Satellite Solution then import it again.

bartsneary commented 1 day ago

That did it. Thank you!

Bart Sneary Innovation Hub Architect | 952-837-4560 W or 507-403-3088 M @.**@.> 3601 West 76th St, Suite 600, Edina, MN 55435 | Microsoft Innovation Hubhttps://www.microsoft.com/en-us/hub/ @.***

From: McKiko030 @.> Sent: Monday, July 1, 2024 4:58 AM To: microsoft/powercat-automation-kit @.> Cc: Bart Sneary @.>; Author @.> Subject: Re: [microsoft/powercat-automation-kit] [Automation - BUG] Get Solution Artifacts Custom Action seems to have a hardcoded user in it (Issue #407)

I also experienced the same.

You need to follow this instruction to create a Microsoft Entra app. https://learn.microsoft.com/en-us/power-automate/guidance/automation-kit/setup/satellite#create-a-microsoft-entra-app-registration-to-connect-to-dataverse-web-api

Then, create an application user inside Dataverse, per satellite environment. https://learn.microsoft.com/en-us/power-automate/guidance/automation-kit/setup/satellite#create-an-application-user-inside-dataverse

Get the UserID from the Dataverse table named "User".

You may either update the environment variable "Solution Manager Artifacts Read User Id" to use the UserID of the MS Entra app or delete the Satellite Solution then import it again.

- Reply to this email directly, view it on GitHubhttps://github.com/microsoft/powercat-automation-kit/issues/407#issuecomment-2199727898, or unsubscribehttps://github.com/notifications/unsubscribe-auth/AJ645VCHV2XR6GNYU5XVRIDZKER4HAVCNFSM6AAAAABJSDSD7KVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDCOJZG4ZDOOBZHA. You are receiving this because you authored the thread.Message ID: @.**@.>>