View Issue Details

IDProjectCategoryView StatusLast Update
0009200CTT UA Scripts1 - Script Issuepublic2023-10-12 15:41
ReporterYannik Klaass Assigned ToYannik Klaass  
PrioritynormalSeverityminorReproducibilityalways
Status closedResolutionfixed 
Fixed in Version1.03.505 
Summary0009200: Address Space UserWriteAccess/Err-002.js: Unexpected error when writing to an empty attribute covered by WriteMask
Description

Testing with the .NET Core OPC UA Reference Server 1.4.372-preview, e.g. with configured scalar node ''ns=2;s=Scalar_Static_Boolean", the test case Address Space UserWriteAccess/Err-002 prints "'item.OriginalValue.toLocalizedText()' [null] is not an object" when accessing the value of the Description attribute, which is empty in the server.
As the test only requires to write a valid value, the Locale part of the LocalizedText to write could as well be a hard-coded string e.g. "en", to avoid this error.

Furthermore the Read and reverting Write calls should expect BadAttributeIdInvalid, to avoid error output if the attributes to write to are empty initially.

Steps To Reproduce

Run Address Space UserWriteAccess/Err-002 while configuring a scalar node with a WriteMask that covers at least one of the attributes Description, DisplayName or InverseName, with the according attribute not being set.

TagsNo tags attached.
Files Affected

/maintree/Address Space Model/Address Space UserWriteAccess/Test Cases/Err-002.js

Relationships

related to 0009033 closedYannik Klaass AddressSpaceModel/UserWriteAccess or WriteMask: Attributes are overwritten and remain so after test. 

Activities

Yannik Klaass

2023-10-12 15:40

developer   ~0020159

Adding code to check if 'item.OriginalValue' is not empty, before accessing toLocalizedText() function to avoid an unexpected error, and setting an empty locale otherwise.

Furthermore adding BadAttributeIdInvalid to expected results of the initial Read and the reverting Write calls, as the attributes are not required to be set in order to write to them.

Paul Hunkar

2023-10-12 15:41

administrator   ~0020160

reviewed changes in call, agreed to changes, closed issue

Issue History

Date Modified Username Field Change
2023-10-11 14:53 Yannik Klaass New Issue
2023-10-11 14:54 Yannik Klaass Relationship added related to 0009033
2023-10-11 15:11 Yannik Klaass Files Affected => /maintree/Address Space Model/Address Space UserWriteAccess/Test Cases/Err-002.js
2023-10-12 15:39 Paul Hunkar Assigned To => Yannik Klaass
2023-10-12 15:39 Paul Hunkar Status new => assigned
2023-10-12 15:40 Yannik Klaass Status assigned => resolved
2023-10-12 15:40 Yannik Klaass Resolution open => fixed
2023-10-12 15:40 Yannik Klaass Note Added: 0020159
2023-10-12 15:41 Paul Hunkar Project Compliance Test Tool (CTT) Unified Architecture => CTT UA Scripts
2023-10-12 15:41 Paul Hunkar Status resolved => closed
2023-10-12 15:41 Paul Hunkar Fixed in Version => 1.03.505
2023-10-12 15:41 Paul Hunkar Note Added: 0020160