Open LouFarho opened 6 years ago
I have just hit this error. It occurs when a site workflow is deleted, so the workflow definition still exists but there are no workflow subscriptions. I presume that what should happen is that there should be an empty workflowsubscriptions element. Instead it is missing altogether. I'm on schema 201805 (on prem 2016)
hi,
I am facing the same issue. In My XML templates i have only site fields. Content types and Lists.
When i add the Lists its failing and showing the below message.
(When executed with SharePoint online)
[ERROR] Apply-PnPProvisioningTemplate : The provided template is not valid!
[ERROR] At D:\FolderName\ServiceCatalog2\InstallApplication.ps1:21 char:1
[ERROR] + Apply-PnPProvisioningTemplate -Path $templateFileName
[ERROR] + ~~~~~~~~~~~~~
[ERROR] + CategoryInfo : WriteError: (:) [Apply-PnPProvisioningTemplate],
[ERROR] ApplicationException
[ERROR] + FullyQualifiedErrorId : EXCEPTION,SharePointPnP.PowerShell.Commands.Prov
[ERROR] isioning.ApplyProvisioningTemplate
[ERROR]
The program 'InstallApplication.ps1: PowerShell Script' has exited with code 0 (0x0).
i have updated to new version of pnp powershell for SharePoint online .
Kotresh
Category
[ x] Bug [ ] Enhancement
Environment
[x ] Office 365 / SharePoint Online [ ] SharePoint 2016 [ ] SharePoint 2013
Using SharePoint PnP PowerShell version ` Name Version
SharePointPnPPowerShellOnline 2.22.1801.0`
Expected or Desired Behavior
Template is applied using newly generated PnP Template using schema V201801 There appears to be an issue with the Workflows element of the template when it is generated.
Observed Behavior
Apply-PnPProvisioningTemplate : The provided template is not valid! At line:5 char:1
Debug log has the following:
powershell_ise.exe Information: 0 : 2018-01-05 16:25:28.1311 [OfficeDevPnP.Core] [0] [Information] File GPD.pnp retrieved from folder 0ms powershell_ise.exe Information: 0 : 2018-01-05 16:25:28.1331 [OfficeDevPnP.Core] [0] [Information] File GPD.pnp retrieved from folder 0ms powershell_ise.exe Information: 0 : 2018-01-05 16:25:28.2012 [OfficeDevPnP.Core] [0] [Information] File GPD.xml retrieved from folder 0ms powershell_ise.exe Error: 0 : 2018-01-05 16:25:28.2282 [SchemaFormatter] [0] [Error] Template is not valid: The element 'Workflows' in namespace 'http://schemas.dev.office.com/PnP/2018/01/ProvisioningSchema' has incomplete content. List of possible elements expected: 'WorkflowSubscriptions' in namespace 'http://schemas.dev.office.com/PnP/2018/01/ProvisioningSchema'. 0ms
Observed Behavior
If you are reporting a bug, please describe the behavior you expected to occur when performing the action. If you are making a suggestion, you can delete this section.
Steps to Reproduce
Generate a template using Schema V201801
GPD.zip
Thanks for your contribution! Sharing is caring.