PnP provisioning: page templates are not published

%3CLINGO-SUB%20id%3D%22lingo-sub-794935%22%20slang%3D%22en-US%22%3EPnP%20provisioning%3A%20page%20templates%20are%20not%20published%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-794935%22%20slang%3D%22en-US%22%3E%3CP%3EWhen%20applying%20a%20PnP%20provisioning%20template%20to%20a%20site%20I%20ran%20into%20an%20error%20of%20a%20secondary%20version%20limit%20being%20reached%20on%20a%20page%20template.%26nbsp%3B%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EAfter%20investigating%20I%20found%20out%20that%20page%20templates%20are%20explicitly%20not%20published%20(PnP-Sites-Core%2C%26nbsp%3BObjectClientSidePages.cs%20line%20591).%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EIs%20there%20a%20specific%20reason%20for%20this%3F%20And%20what%20would%20be%20a%20good%20alternate%20to%20make%20sure%20that%20I%20can%20keep%20provisioning%20new%20versions%20(applying%20this%20template%20is%20part%20of%20a%20CI%20release%20pipeline%20on%20Azure%20DevOps).%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EThanks%20in%20advance!%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-795513%22%20slang%3D%22en-US%22%3ERe%3A%20PnP%20provisioning%3A%20page%20templates%20are%20not%20published%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-795513%22%20slang%3D%22en-US%22%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F26235%22%20target%3D%22_blank%22%3E%40Marcela%20Bovio%3C%2FA%3E%26nbsp%3BPage%20Templates%20aren't%20published%20because%20that%20would%20cause%20them%20to%26nbsp%3B%20show%20up%20in%20SharePoint%20search%20which%20may%20have%20unintended%20consequences%20of%20showing%20users%20pages%20that%20would%20be%20incomplete%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-806602%22%20slang%3D%22en-US%22%3ERe%3A%20PnP%20provisioning%3A%20page%20templates%20are%20not%20published%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-806602%22%20slang%3D%22en-US%22%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F39836%22%20target%3D%22_blank%22%3E%40Beau%20Cameron%3C%2FA%3E%26nbsp%3Bthat%20makes%20sense%2C%20thanks!%3C%2FP%3E%3C%2FLINGO-BODY%3E
New Contributor

When applying a PnP provisioning template to a site I ran into an error of a secondary version limit being reached on a page template. 

 

After investigating I found out that page templates are explicitly not published (PnP-Sites-Core, ObjectClientSidePages.cs line 591).

 

Is there a specific reason for this? And what would be a good alternate to make sure that I can keep provisioning new versions (applying this template is part of a CI release pipeline on Azure DevOps).

 

Thanks in advance!

2 Replies

@Marcela Bovio Page Templates aren't published because that would cause them to  show up in SharePoint search which may have unintended consequences of showing users pages that would be incomplete

@Beau Cameron that makes sense, thanks!