Add a YAMLLint compliance check that uses the yamllint package to report
linting error on YAML files.
Signed-off-by: Fabio Baltieri <fabiobaltieri@google.com>
junitparser has a bug that prevents it from working correctly when lxml
is not installed.
See this GH issue for more information:
https://github.com/weiwei/junitparser/issues/99
Signed-off-by: Carles Cufi <carles.cufi@nordicsemi.no>
There is a breaking change in Junitparser 'TestCase.result' between
v1.x and v2.x.
Update check_compliance.py minimally to take into account this change.
This avoids relying on an outdated package.
Signed-off-by: Henri Xavier <datacomos@huawei.com>
The Python python-magic module that we install for compliance checks
requires libmagic to be installed on the system to work. This requires
extra OS packages on Ubuntu and macOS, and an extra wheel on Windows.
Signed-off-by: Carles Cufi <carles.cufi@nordicsemi.no>
junitparser version 2 is incompatible with check_compliance.py, it fails
like this:
File "./scripts/ci/check_compliance.py", line 295, in parse_kconfig
self.skip("Not a Zephyr tree (ZEPHYR_BASE unset)")
File "./scripts/ci/check_compliance.py", line 141, in skip
self.case.result = Skipped(msg, "skipped")
File "/usr/local/lib/python3.9/site-packages/junitparser/junitparser.py"
line 682, in result
for entry in value:
TypeError: 'Skipped' object is not iterable
Signed-off-by: Marc Herbert <marc.herbert@intel.com>
Running check_compliance on a PR before submitting it can avert
embarrassing mistakes. Ensure the packages needed to do so are
installed along with all the others.
Signed-off-by: Peter Bigot <peter.bigot@nordicsemi.no>