SOLVED

PnP List deploy error "The field was found invalid: {sitecollectiontermstoreid}"

Brass Contributor

Using powershell I extracted a site definition to a pnp file. While trying to deploy from my visual studio project I receive the following error during list deployment and at this stage the term store has already been deployed.

 

"The field was found invalid:  {sitecollectiontermstoreid}"

 

Any pointers here as to why {sitecollectiontermstoreid} invalid?

9 Replies

HI @david.calabro,

 

Are you using SharePoint online or on premises?

 

Are you applying the template to the same tenant/farm as you are exporting it from?

 

I've seen similar issues when there either is no term store or if the termsets are not replicated.

 

You might want to run

 

Set-PnPTraceLog -On -Level Debug

 

prior to the Apply-PnPProvisioningTemplate Then you will get some more clue. Please copy the last 10 lines or so into a post here.

@Pieter Veenstra I am applying to a different farm on premises. After viewing the managed meta data service I do see all expected terms since I used pnp to import the pnp:TermGroups section as well.

 

The trace log reports the same information but nothing else that appears helpful to me.

 

PowerShell.exe Information: 0 : 2017-03-17 12:25:57.8007	[List instances]	[6]	[Debug]	Updating field 1699e6da-f54f-4630-9904-8fbcb547b77b	45789ms	650c4afd-5081-4dcc-bc05-6c7a359b8893


PowerShell.exe Information: 0 : 2017-03-17 12:25:58.0357	[List instances]	[6]	[Debug]	Updating field 921e697d-220a-4309-93ea-e2345c9283cf	46024ms	650c4afd-5081-4dcc-bc05-6c7a359b8893


PowerShell.exe Information: 0 : 2017-03-17 12:25:58.2397	[List instances]	[6]	[Debug]	Creating field 4c073b84-428b-4dba-9f74-0617a0ad3d3f	46228ms	650c4afd-5081-4dcc-bc05-6c7a359b8893


PowerShell.exe Error: 0 : 2017-03-17 12:25:58.4037	[List instances]	[6]	[Error]	The field was found invalid:  {sitecollectiontermstoreid}	46391ms	650c4afd-5081-4dcc-bc05-6c7a359b8893


PowerShell.exe Error: 0 : 2017-03-17 12:25:58.7138	[List instances]	[6]	[Error]	Creating field 4c073b84-428b-4dba-9f74-0617a0ad3d3f failed: The field was found invalid:  {sitecollectiontermstoreid} :    at OfficeDevPnP.Core.Framework.Provisioning.ObjectHandlers.ObjectListInstance.CreateField(XElement fieldElement, ListInfo listInfo, TokenParser parser, String originalFieldXml, ClientRuntimeContext context, PnPMonitoredScope scope)
   at OfficeDevPnP.Core.Framework.Provisioning.ObjectHandlers.ObjectListInstance.ProvisionObjects(Web web, ProvisioningTemplate template, TokenParser parser, ProvisioningTemplateApplyingInformation applyingInformation)	46702ms	650c4afd-5081-4dcc-bc05-6c7a359b8893


PowerShell.exe Information: 0 : 2017-03-17 12:25:58.7138	[List instances]	[6]	[Debug]	Code execution scope ended	46702ms	650c4afd-5081-4dcc-bc05-6c7a359b8893


PowerShell.exe Information: 0 : 2017-03-17 12:25:58.7138	[Provisioning]	[6]	[Debug]	Code execution scope ended	48426ms	650c4afd-5081-4dcc-bc05-6c7a359b8893

 

 

Hi @david.calabro,

 

could it be that you have multiple termstores? I had something similar yesterday and I haven't found a workaround for that yet. PnP doesn't seem to give an option to select a term store.

 

 

I'm not even sure what that would look like. How would I check for multiple term stores?

 

If I go to http://myinternalsite.net/sites/site1/_layouts/15/termstoremanager.aspx I don't see anything duplicated.

I'm fairly new to PnP but could it be that I'm not populating a value somewhere that it uses for {sitecollectiontermstoreid} or would that be a token that it swaps out automatically?

Check in central admin -services in this farm- check for multiple managed metadata services

I have confirmed that multiple services do not exist.

Hi @david.calabro, yes this is a token that should be resolved. So for somereason the PowerShell can't cget to the termstore.

 

Has the user that you are runnning as  been specified as a term store administrator.

 

Does the column get created?

Is this a site column or a list column? 

Are you able to share the xml from the template?

best response confirmed by david.calabro (Brass Contributor)
Solution

I updated the pnp package through NuGet and the problem seems to have been resolved.

1 best response

Accepted Solutions
best response confirmed by david.calabro (Brass Contributor)
Solution

I updated the pnp package through NuGet and the problem seems to have been resolved.

View solution in original post