HomePhabricator

Allow linters to run once

Description

Allow linters to run once

Summary:
This diff replaces the lint engine to override the linter paths to run
on. Only the first path is kept so the linter will effectively run once.

This is achieved by extending the GlobalExternalLinter class
and implementing the parseGlobalLinterOutput method. The check-doc
linter is the first to benefit this feature.

Test Plan:
Comment one of the exceptions in test/lint/check-doc.py.

arc lint --everything --trace 2>&1 | grep "check-doc"

Look at the traces for Linter 'check-doc' will run once..
Check the linter return the error from the commented exception only
once.

Reviewers: #bitcoin_abc, deadalnix

Reviewed By: #bitcoin_abc, deadalnix

Differential Revision: https://reviews.bitcoinabc.org/D3705

Details