Skip to content
This repository was archived by the owner on Apr 6, 2022. It is now read-only.

Commit cbba32e

Browse files
ulfalizergalak
authored andcommitted
check_compliance.py: Don't error out for internal test(e)dtlib errors
Instead of catching DeviceTreeCheck exceptions from test(e)dtlib.py all the way up in main(), catch them in the DeviceTreeCheck test itself, and report them with ComplianceTest.error(). That way, other tests (e.g. pylint) can still run and report to GitHub when there are internal errors in test(e)dtlib.py. Motivated by zephyrproject-rtos/zephyr#22255. Signed-off-by: Ulf Magnusson <[email protected]>
1 parent e6b2e62 commit cbba32e

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

scripts/check_compliance.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -536,6 +536,9 @@ def run(self):
536536
# which raises SystemExit. Let any errors in the test scripts
537537
# themselves trickle through and turn into an internal CI error.
538538
self.add_failure(str(e))
539+
except Exception as e:
540+
# Report other exceptions as an internal test failure
541+
self.error(str(e))
539542
finally:
540543
# Restore working directory
541544
os.chdir(old_dir)

0 commit comments

Comments
 (0)