pnp / PnP-PowerShell

SharePoint PnP PowerShell CmdLets
https://pnp.github.io/powershell
Other
990 stars 662 forks source link

[BUG] ConvertTo-PnPClientSidePage fails at OfficeDevPnP.Core.Pages.ClientSidePage.AvailableClientSideComponents(String name) - A critical error occurred - transformation did not complete #3036

Open ollij opened 3 years ago

ollij commented 3 years ago

In two customer tenants we have problems converting publishing pages to modern pages using ConvertTo-PnPClientSidePage. In our dev tenants the commandlet functions correctly.

We can overcome the issue by using older version of PnP PowerShell Online module (December 2019, 3.6.1912.0).

Expected behavior

Publishing page transformed successfully to modern page.

Actual behavior

Page transformation report

Modernization Summary Report

Date Duration Source Page Target Page Url Status
28/12/2020 9.03.05 00:00:01 /Pages/test.aspx []() A issue prevented successful transformation

Critical Errors during transformation

28/12/2020 9.03.06 - /Pages/test.aspx

One or more errors occurred. at System.Threading.Tasks.Task1.GetResultCore(Boolean waitCompletionNotification) at OfficeDevPnP.Core.Pages.ClientSidePage.AvailableClientSideComponents(String name) at SharePointPnP.Modernization.Framework.Cache.CacheManager.GetClientSideComponents(ClientSidePage page) at SharePointPnP.Modernization.Framework.Transform.ContentTransformator.Transform(List1 webParts) at SharePointPnP.Modernization.Framework.Publishing.PublishingPageTransformator.Transform(PublishingPageTransformationInformation publishingPageTransformationInformation)

Individual Page details

Transformation Details: /Pages/test.aspx

Page Transformation Settings

Property Setting
Engine version 1.0.2007.0
Overwrite False
Target Page Name
Target Page Folder
Target Page Folder Overrides Default Folder False
Keep Page Specific Permissions True
Remove Empty Sections And Columns True
Handle Wiki Images And Videos True
Add Table List Image As Image Web Part True
Keep Page Creation Modification Information False
Publish Created Page True
Post As News False
Disable Page Comments False
Skip Url Rewrite False
Skip Default Url Rewrite False
Url Mapping File
Term Mapping File
Skip Term Store Mapping False
Skip User Mapping False
User Mapping File
L D A P Connection String
Skip Telemetry False

Transformation Operation Details

Date Operation Actions Performed
28/12/2020 9.03.05 Input Validation Validation checks complete
28/12/2020 9.03.05 SharePoint Connection Loading client context objects
28/12/2020 9.03.05 SharePoint Connection Loading target client context object
28/12/2020 9.03.05 Page Creation Detect if the page is living inside a folder
28/12/2020 9.03.05 Page Creation In Cross-Site transform mode the original source file name is used
28/12/2020 9.03.05 Page Creation Just try to load the page in the fastest possible manner, we only want to see if the page exists or not
28/12/2020 9.03.06 Load Page does not exist in current web
28/12/2020 9.03.06 Page Creation Checking Page Exists
28/12/2020 9.03.06 Page Creation Modern page created
28/12/2020 9.03.06 Article page handling Transforming source page as Article page
28/12/2020 9.03.06 Article page handling Recognized source page as a Publishing Page - Analyzing web parts and page layouts
28/12/2020 9.03.06 Page Layout Manager Page uses BlankWebPartPage as page layout, mapping that will be used is BlankWebPartPage
28/12/2020 9.03.06 Article page handling Splitting images and videos from wiki text - as modern text web part does not support embedded images and videos
28/12/2020 9.03.06 Set Page Title Setting the modern page title: Test
28/12/2020 9.03.06 Article page handling Preparing content transformation
28/12/2020 9.03.06 Article page handling Transforming content
28/12/2020 9.03.06 Content Transform Transforming web parts

Steps to reproduce behavior

$SourceUrl = "https://tenant.sharepoint.com/sites/site1" $TargetUrl = "https://tenant.sharepoint.com/sites/modernsite" Connect-PnPOnline $SourceUrl -UseWebLogin

ConvertTo-PnPClientSidePage -PublishingPage -Identity test.aspx -TargetWebUrl $TargetUrl -LogType File -LogFolder c:\temp -LogVerbose

Which version of the PnP-PowerShell Cmdlets are you using?

What is the version of the Cmdlet module you are running?

The ones we are having problems

The one that works on