Imported Tag DataType OPC Item binding not being evaluated

This is a strange one… but an issue I’m seeing with 8.0.6.

If I import a datatype that has parameters, ie Device and BaseTag, and use those specifically in the OPC Item Path to develop the item path, those bindings aren’t being evaluated on those tags anymore.

In UDTs that were created/imported prior to 8.0.6, and possibly earlier, those OPC Item Paths are grey and in italics. However on newly imported tags they are black and regular text. Tags created from this new UDT don’t have their OPC Item patch replaced properly. The look like “[{Device}]{BaseTag}” in their OPC item path rather than “[PLC]test” or whatever the parameter is assigned on Device or BaseTag. If I go into the UDT and select “Edit…” on the OPC Item Path and just select “Commit” then the tag evaluations start to happen correctly.

So… it this a bug or is there another step I’m missing? Is there anyway to get around having to go through potentially hundreds of OPC Item Paths to get them working again?

I’m also running into this, except when assigning the OPC Item Path via system.tag.configure(). If I go through and “Browse OPC”, select the path, and then edit it with the parameters, it evaluates (goes italic). If I assign the exact same string via the configure function, it does not turn to grayed italics and does not evaluate.

If you’ve found a fix for this, I’d be grateful.

Edit: I’ve found a fix for this, apparently there is a bindType as well as a Binding argument for the opcItemPath. I’ve attached my script below that edits the bindType to parameter.

results = system.tag.browse(path = '[Fairfield Water Plant]Devices/Valves', filter = {'name':'*Filter*'})
for result in results.getResults():
    path = str(result['fullPath'])
    tagType = str(result['typeId'])
    
    if 'Discrete' in tagType:
    	pathToTag = path+'/Mapping/Sts'
    	tag = {
    		"name" : 'OpenSts',
            "opcItemPath" : {
              "bindType" : 'parameter',
              "binding" : 'ns=2;s=AB_FF_WP.AB_FF_WP.Filt{FolderName}_VALVES.VALVE{DeviceName}'
              }
       		}
       	system.tag.configure(pathToTag, [tag], 'm')

    
    if 'Analog' in tagType:
    	pathToTag = path+'/Mapping/Sts'
    	tag = {
    		"name" : 'Pos',
            "opcItemPath" : {
              "bindType" : 'parameter',
              "binding" : 'ns=2;s=AB_FF_WP.AB_FF_WP.Filt{FolderName}_VALVES.{DeviceName}'
              }
       		}
       	system.tag.configure(pathToTag, [tag], 'm')

Note: This edits the Analog and Discrete valves in a folder that contains ‘Filter’ in the name. You want to point the pathToTag to the parent folder and specify the tag name in the “name” argument. ‘binding’ should be whatever you want your binding to be.