Skip to content

Error handling

This page aims to summarize the way errors are reported, treated and handled throughout the pipeline.

Reporting items

Reporting items are the basic primitives for logging in the DMLA runtime.

DMLALog logging

The DMLALog object provides various methods for logging with a loglevel, and optionally an exception.

DMLALog manages DMLALogEntry log entries, all of which have an associated LogSeverity.

Log entries may be printed to the standard output when they are submitted, this behavior is enabled by default, and depends on the printEnabled property.

The currentSeverity property specifies the level above which entries are displayed when printEnabled is true.

Log Severity

Saving and loading logs

DMLALog instances are serializable. Each saved log contains a snapshot of the loaded workspace, and the log entries materialized.

All DMLA components (if possible) should save their logs in the default DMLA logs folder at ~/.dmla/logs in a subdirectory named after the component (e.g. the runtime will save logs to ~/.dmla/logs/runtime).

Logs are generally saved to

Commands

As of version 3.5.8 the DMLA launcher was updated with basic features related to logging. These features are available under the log command, and support the following arguments: - --show opens the logs directory - --inspect <LOG> shows a brief overview of the contents of a log file - --reconstruct <LOG> reconstructs the workspace and log entries saved in a log file

Frontend

Error identifiers

Identifiers are made up as follows: <Pass ID [0-9]><Group ID [0-9]{2}><Error ID [0-9]{3}> In which the: -Pass ID identifies the compilation pass 0. System (errors/reports generated by utilities, not necessarily related to the processing of DMLA models) 1. General (i.e. the pass is not known) 2. Lexer 3. Parser 4. AST Transformation 5. SymbolDB tansformations 6. SymbolDB Nodes 7. SymbolDB validation 8. RT 9. RT2

The following tables contain the current identifiers grouped by origin:

Node walker errors