Skip to content

Commit

Permalink
filtering error log: metanorma/metanorma-utils#34
Browse files Browse the repository at this point in the history
  • Loading branch information
opoudjis committed Sep 17, 2024
1 parent 3cbf113 commit 8d34969
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 0 deletions.
7 changes: 7 additions & 0 deletions author/ref/document-attributes.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,13 @@ Suppress document validation.
Terms (and symbols) are indexed automatically in postprocessing.
See link:/author/topics/document-format/xrefs/#auto-index-terms[automatic reference lookup]. [added in https://github.com/metanorma/metanorma-standoc/releases/tag/v1.11.3]

`:log-filter-severity:`::
Filter from error log all warnings at the given severity level or above it. [added in https://github.com/metanorma/metanorma-standoc/releases/tag/v2.9.7]

`:log-filter-category:`::
Filter from error log all warnings belonging to one of the named categories; comma-delimited. [added in https://github.com/metanorma/metanorma-standoc/releases/tag/v2.9.7]


== Reference lookup

For bibliographic lookup, see link:/author/topics/building/reference-lookup[automatic reference lookup].
Expand Down
11 changes: 11 additions & 0 deletions author/topics/output/validation.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,17 @@ are also output to console. To date, these are applicable to all flavours of Met
Severity 3 errors, by contrast, are information-only warnings. You must address severity 0 errors, to get documents to
compile at all, and you should also address severity 1 errors.

The error file can get quite large, and it is possible to filter certain classes of log message from the error log.
In order not to log messages from a given severity level up, use the document attribute `:log-filter-severity:`;
in order to log messages from one or more categories, use the document attribute `:log-filter-category:`, with the
categories to exclude comma-delimited [added in https://github.com/metanorma/metanorma-standoc/releases/tag/v2.9.7].

[source,asciidoc]
----
:log-filter-severity: 3
:log-filter-category: Crossreferences,Document Attributes,Metanorma XML Syntax
----

Error classes include the following:


Expand Down

0 comments on commit 8d34969

Please sign in to comment.