View Issue Details

IDProjectCategoryView StatusLast Update
0003458Compliance Test Tool (CTT) Unified Architecture1 - Script Issuepublic2019-07-25 15:11
ReporterMartin Lang Assigned ToAlexander Allmendinger  
PrioritynormalSeverityminorReproducibilityalways
Status closedResolutionfixed 
Product Version1.02.336.273 
Target Version1.03Fixed in Version1.03.341.383 
Summary0003458: Data Access DataItems/014.js - scipt throws unexpected error if server does not support CreateMonitoredItems
Description

used CTT version 1.2.336.256
Script throws unexpected error: ReferenceError: Can't find variable: uastatus, caused by line 109.

Create MonitoredItems is not implemented, the error handling use unspecified variable.

Steps To Reproduce
  • start server without support for create monitored item service
    (or let this service return BadNotSupported)
  • run script
Additional Information

Code Snippet:

// Create and add the items to the subscription
if( !CreateMonitoredItemsHelper.Execute( { ItemsToCreate: items, TimestampsToReturn: TimestampsToReturn.Both, SubscriptionId: subscription } ) )
{
    addError( "Create monitored items failed with status '" + uaStatus + "'.");
    DeleteSubscriptionsHelper.Execute( { SubscriptionIds: subscription } );
    return( false );
}

Attempt to get ServiceResult was not successfully, because the committed parameter ServiceResult returns 'undefined'.

// Create and add the items to the subscription
var serviceResult;
if( !CreateMonitoredItemsHelper.Execute( { ItemsToCreate: items, TimestampsToReturn: TimestampsToReturn.Both, SubscriptionId: subscription, ServiceResult: serviceResult } ) )
{
    addError( "Create monitored items failed with status '" + serviceResult.StatusCode + "'.");
    DeleteSubscriptionsHelper.Execute( { SubscriptionIds: subscription } );
    return( false );
}

I expect that this parameter could be set in function createMonitoredItems, but there is no code which does use the argument ServiceResult.

TagsNo tags attached.
Files Affected

Activities

Nathan Pocock

2016-08-05 21:19

viewer   ~0007135

Removed addError line of code since the service helper function will display errors internally. Code in source control and will be in next release which is when this case will be closed.

Alexander Allmendinger

2018-12-19 09:07

developer   ~0009733

Removed the additional error message

Paul Hunkar

2019-07-25 15:11

administrator   ~0010604

Reviewed in CMP Call

Issue History

Date Modified Username Field Change
2016-07-01 08:04 Martin Lang New Issue
2016-08-05 21:19 Nathan Pocock Note Added: 0007135
2016-08-05 21:19 Nathan Pocock Status new => resolved
2016-08-05 21:19 Nathan Pocock Resolution open => fixed
2016-08-05 21:19 Nathan Pocock Assigned To => Nathan Pocock
2018-11-23 15:41 Paul Hunkar Assigned To Nathan Pocock => Alexander Allmendinger
2018-11-23 15:41 Paul Hunkar Status resolved => assigned
2018-12-19 09:07 Alexander Allmendinger Note Added: 0009733
2018-12-19 09:07 Alexander Allmendinger Status assigned => resolved
2018-12-19 09:07 Alexander Allmendinger Fixed in Version => 1.03.341.383
2019-07-25 15:10 Paul Hunkar Category Implementation Bug => 1 - Script Issue
2019-07-25 15:10 Paul Hunkar Product Version => 1.02.336.273
2019-07-25 15:10 Paul Hunkar Target Version => 1.03
2019-07-25 15:11 Paul Hunkar Status resolved => closed
2019-07-25 15:11 Paul Hunkar Note Added: 0010604