MikroTik MCP / Language server / Diagnostic rules

Diagnostic rules

Every finding is a rule with a stable id, a default severity and a source that says how well founded it is. There are 36 today. This page mirrors docs/rules.md, which the repository generates from the code.

Sources

The source is shown in the message whenever a rule is not the documented language, so a quirk of RouterOS 7.21.4 is never presented as the specification.

doc

The Scripting documentation states it.

8 rules
doc-example

The documentation does not state it, but one of its examples shows it.

no rules yet
device

Observed on RouterOS, not described in the documentation.

Message ends: (RouterOS behaviour that the documentation does not describe)25 rules
open

The documentation is silent or contradicts itself.

Message ends: (the documentation does not specify this)3 rules

Where the documentation and the device disagree, the device decides what is an error — a script that fails to compile — and the documentation decides what is merely reported as a warning. The register ids point to rows of ambiguities.md, the evidence for each rule.

Severities

Change one with the severities setting, or --severity RULE=LEVEL on the command line. See Configuration.

All rules

MESSAGES
Message wording comes from the server's source; the example lines are illustrative. Run routeros-lsp check on your own scripts to see exactly what it reports for them.