pnp / PnP-Sites-Core

Microsoft 365 Dev PnP Core component (.NET) targeted for increasing developer productivity with CSOM based solutions.
Other
416 stars 642 forks source link

Field not initialized when updating item field values in document libraries #2337

Open heinrich-ulbricht opened 5 years ago

heinrich-ulbricht commented 5 years ago

Category

Environment

Expected or Desired Behavior

I expect no Microsoft.SharePoint.Client.PropertyOrFieldNotInitializedException to happen ever.

Observed Behavior

Microsoft.SharePoint.Client.PropertyOrFieldNotInitializedException happens here:

https://github.com/SharePoint/PnP-Sites-Core/blob/dev/Core/OfficeDevPnP.Core/Framework/Provisioning/ObjectHandlers/Utilities/ListItemUtilities.cs#L459

image

Steps to Reproduce

Apply the following template to a new communication site:

https://gist.github.com/heinrich-ulbricht/a9fddfb5786b66972c290869af0cd778

This triggers the error.

ghost commented 5 years ago

Thank you for reporting this issue. We will be triaging your incoming issue as soon as possible.

heinrich-ulbricht commented 5 years ago

I narrowed this down to this special case:

Better logging fix in progress.

heinrich-ulbricht commented 5 years ago

Note: fix probably needed on the way to resolving #2338 with a workaround