powershell
powershell copied to clipboard
[BUG] Invoke-PnPSiteDesign appears to do nothing
Using 2.4.0 - Fetching a valid Site Template through Get-PnPSiteDesign
then trying to run it with Invoke-PnPSiteDesign
does nothing.
Syntax:
Invoke-PnPSiteDesign -WebUrl https://xxx.sharepoint.com/sites/something -Identity <Site Design ID>
It should return the outcome of the job. There is no output return at all.
The same templates invoked through the web UI work fine, they just appear to be failing through the cmdlet.
Maybe there is something invalid in the site script that is not running well by using this commandlet. If you are just creating a new site design with the site script example provided over here https://learn.microsoft.com/en-us/sharepoint/dev/declarative-customization/site-design-overview#anatomy-of-a-site-script. With the nightly build "2.4.73" of PnP.PowerShell and the provided example this is working as expected and get the outcome on the screen.
Is the cmdlet then running fine? I understand that some feedback of what is the error with the applying the site design should be helpfull.
Any update on this @jimmywim ? Maybe you can try it with a different site design/script ?
@gautamdsheth @markgort86 I know the root cause, the site design had more than the threshold script tasks/verbs, so had to use the REST API endpoint instead. Not sure the cleanest way to handle this in the Cmdlet though, when it current returns nothing in this scenario (not the best UX).