Get-PnPTenantSite : System.InvalidOperationException: The type of data at position 1684 is different than the one expected.
Hi,
When try to obtain the PnPTenantSite information exception is thrown. Seems, it is related to parsing of the JSON result received from O365. I have checked the traffic with fiddler and it seems that the result coming from O365 is correct.
Category
- [ ] Question
- [ ] Typo
- [x] Bug
- [ ] Additional article idea
Steps to reproduce behavior
Execute 'Get-PnPTenantSite' cmdlet with or without parameters.
Expected behavior
Receive TenantSite / List of TenantSite objects.
Actual behavior
Exception is thrown:
System.InvalidOperationException: The type of data at position 1687 is different than the one expected. at Microsoft.SharePoint.Client.JsonReader.ReadGuid() at Microsoft.Online.SharePoint.TenantAdministration.SiteProperties.InitOnePropertyFromJson(String peekedName, JsonReader reader) at Microsoft.SharePoint.Client.ClientObject.FromJson(JsonReader reader) at Microsoft.SharePoint.Client.ClientRequest.ProcessResponseStream(Stream responseStream) at Microsoft.SharePoint.Client.ClientRequest.ProcessResponse() at Microsoft.SharePoint.Client.ClientRequest.d__6.MoveNext() --- End of stack trace from previous location where exception was thrown --- at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw() at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task) at Microsoft.SharePoint.Client.ClientRequest.d__0.MoveNext() --- End of stack trace from previous location where exception was thrown --- at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw() at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task) at Microsoft.SharePoint.Client.ClientRuntimeContext.d__0.MoveNext() --- End of stack trace from previous location where exception was thrown --- at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw() at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task) at Microsoft.SharePoint.Client.ClientContext.d__4.MoveNext() --- End of stack trace from previous location where exception was thrown --- at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw() at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task) at System.Runtime.CompilerServices.TaskAwaiter.GetResult() at Microsoft.SharePoint.Client.ClientContextExtensions.d__7.MoveNext()
Thank you for reporting this issue. We will be triaging your incoming issue as soon as possible.
This seems related to the PnP Core PowerShell component... best to submit this question to that specific repo's issue list: https://github.com/SharePoint/PnP-Sites-Core
It is not related to PnP Core Powershell. The exception is coming from Microsoft.SharePoint.Client.JsonReader.ReadGuid().
Please reopen.
The issue is in the underlying CSOM APIs or specifically in the server side APIs and is being worked on. Path deployment should get on hold and canceled so we should not have new tenants experiencing this anymore. The fix is being worked on and it will be shipped server side as soon as possible, but can't provide an exact ETA at this point.
Thanks for reporting this.
Thank you very much for addressing this. Have a client tenant that is adversely affected by this bug. Thanks again.
This is affecting both our Live and Dev tenancy's with this issue.
@VesaJuvonen any ETA / updates? We have many customers who are all having this problem when provisioning sitecollections.
We do have several customers, along with different DEV/ TEST and PROD tenants who are affected when provisioning site collections.
Thanks for the clarification, @VesaJuvonen ! I can also confirm we have several environments being affected by this issue, so we are eagerly awaiting new updates :)
Thanks, everyone for following up on this with updates. I'll try to get the latest status from owners of the issue and share it here asap.
We are being impacted as well with Azure Automation scripts that have a dependency on this functionality.
Have they considered backing out the changes on the affected Tenants, until they have a fix?
Have they considered backing out the changes on the affected Tenants, until they have a fix?
+1 What he said.
Our production and development tenants suffered this problem on March 12 - 13, but now it is no longer an issue as of March 14th.
I do not have yet ETA for this, but things are actively being worked on. Thanks, everyone for the updates as they do help others to see how things are progressing cross the tenants. Transparency will reduce confusion.
Our production and development tenants suffered this problem on March 12 - 13, but now it is no longer an issue as of March 14th.
Per what spkimc also just mentioned, my client's tenant that was experiencing the issue 12th & 13th is also no longer experiencing it today (the 14th). Obviously no idea if that is a roll back or a fix, but its working for now so thank you very much for the support and communication.
The fix is currently being rolled out worldwide, so the issue should be resolved for everyone within upcoming hours. Please do provide updates on your tenant status. If the issue still exists after a few hours, please do report that in here as well. Thanks, everyone for your activity on this.
It is working again. Thanks for the fix.
Yesterday I had this error at the beginning of script when creating a site collection app catalog. This line, $ctx.ExecuteQuery(), caused this error: Exception calling "ExecuteQuery" with "0" argument(s): "The type of data at position 1144 is different than the one expected."
Today, I have been successful in passing the above point in the scripts and in building a hierarchy of 6 sites but right near the end of my scripts I see it again when I am turning off minor versioning on the site pages library: Invoke-PnPQuery : The type of data at position 1145 is different than the one expected.
While the minor versioning is successfully turned off but this Invoke-PnPQuery is returning the above error every time.
All working again in both Production and Dev tenancy's. Many thanks for the fix and updates.