Model.hm_ce_errorreport#
- Model.hm_ce_errorreport(connector, report_type)#
Returns the specific reason for the failed realization of a connector.
- Parameters:
connector (Entity) – The object describing the connector entity.
report_type (int) –
0 - returns one of the failure criteria.
1 - returns all the causes for failed realization.
- Returns:
hwReturnStatus- Status objectHmQueryResult- Result object containing the output values:Keys valid for
report_type=0errorMessage (str)
Keys valid for
report_type=1errorMessage (list of strings)
Examples#
Obtain a simple report for failed realization for a connector with ID 10#import hm import hm.entities as ent model = hm.Model() ce_id = ent.Connector(model, 10) _, result = model.hm_ce_errorreport(connector=ce_id, report_type=0) single_err_report = result.errorMessage print("Single Error Report: ", result.single_err_report)
Obtain a detailed report returned as list of lists for connector with ID 10#import hm import hm.entities as ent model = hm.Model() ce_id = ent.Connector(model, 10) _, result = model.hm_ce_errorreport(connector=ce_id, report_type=1) single_err_report = result.errorMessage print("Single Error Report: ", result.single_err_report)
Note
Returns a report only for the failed connectors. The state of the connector can be looked up using the connection information table. All failed connectors are marked red.