cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Rapothin
Frequent Visitor

[Microsoft.PowerApps.Administration.PowerShell][New-AdminPowerAppEnvironment] Wait that all out of the box solutions imported before responding to caller

Hello everyone,

Working on some automation around environment provisioning and solution import on the brand-new environment, I found that when you got an answer from your call to New-AdminPowerAppEnvironment there are still some "out of the box" solutions importing in background.

Below you will find the error message I get in my scenario when I try to import the solution:

 

Error: Cannot start the requested operation [Import] because there is another [LanguageProvision] running at this moment. Use Solution History for more details. -- The solution installation or removal failed due to the installation or removal of another solution at the same time. Please try again later.

 

Do you think it could be possible to wait the import of all the out of the box solutions before sending the response to a call to New-AdminPowerAppEnvironment?

You can find some resources regarding this issue below:

Thank you in advance for your help!

Raphael

1 ACCEPTED SOLUTION

Accepted Solutions
MrRegalius
Regular Visitor

Hi,

After looking into New-AdminPowerAppEnvironment I noticed there is a -WaitUntilFinished flag.
I haven't been able to test this out if this works.
But looking at the GitHub code you sent, I don't see you using this flag.2020-12-07 20_33_28-Window.png

I'm wondering if this solves it.

View solution in original post

2 REPLIES 2
MrRegalius
Regular Visitor

Hi,

After looking into New-AdminPowerAppEnvironment I noticed there is a -WaitUntilFinished flag.
I haven't been able to test this out if this works.
But looking at the GitHub code you sent, I don't see you using this flag.2020-12-07 20_33_28-Window.png

I'm wondering if this solves it.

View solution in original post

Rapothin
Frequent Visitor

Hi,

 

Good idea!

I thought I tried all the combinations of parameters of the New-AdminPowerAppEnvironment cmdlet, but it seems it was not the case.


I have made some tests and indeed, add "-WaitUntilFinished 1" in the call to the cmdlet seems to work.

I will try to make more tests in the incoming days to be sure that the solution works.

 

Thank you again for your help.

Helpful resources

Announcements
UG GA Amplification 768x460.png

Launching new user group features

Learn how to create your own user groups today!

Community Connections 768x460.jpg

Community & How To Videos

Check out the new Power Platform Community Connections gallery!

Welcome Super Users.jpg

Super User Season 2

Congratulations, the new Super User Season 2 for 2021 has started!

Carousel 2021 Release Wave 2 Plan 768x460.jpg

2021 Release Wave 2 Plan

Power Platform release plan for the 2021 release wave 2 describes all new features releasing from October 2021 through March 2022.

Users online (1,360)