Closed lit-af closed 5 months ago
TL;DR: mlx-warnings is a little special and expects all of its keyword arguments first, followed by the positional arguments:
mlx-warnings --config .\mlx-warnings-config.json --code-quality doxygen_quality.json .\build\DoxygenWarningLog.txt
usage: mlx-warnings [-h] [--coverity] [-d] [-j] [-r] [-s] [-x] [--name NAME] [-m MAXWARNINGS]
[--minwarnings MINWARNINGS] [--exact-warnings EXACT_WARNINGS]
[--config CONFIGFILE] [--include-sphinx-deprecation] [-o OUTPUT]
[-C CODE_QUALITY] [-v] [--command] [--ignore-retval] [--version]
logfile [logfile ...] ...
The last ...
is the result of parser.add_argument('flags', nargs=argparse.REMAINDER, help='Possible not-used flags from above are considered as command flags')
. Your trailing --code-quality <<file>>
is gobbled up by flags
, which ends up not getting used because --command
was not used. Instead of ignoring it, a warning should be logged when flags
is not empty and unused.
Thanks for reporting the issue!
Maybe a side note, what if we would add the code-quality
field in config json file as well - then there would not be a case where we would have to be careful about the code-quality flags placement (or ignore-retval
, include-sphinx-deprecation
, name
, etc?). Probably this is then more of a feature request if we decide to go this way...
I have made a release with this bugfix 5.1.0. I hope it solved it.
Thank you for the quick reply!
Hi,
I'm wondering if it's possible to generate a code quality json report for GitLab CI from a doxygen log file ex:
DoxygenWarningLog.txt
I tried the following with out success:
with the following content in
mlx-warnings-config.json
The output of that command give me:
but there's no code_quality.json file generated.