| Message ID | 20261204174107.1295971-6-tgamblin@baylibre.com |
|---|---|
| State | New |
| Headers | show |
| Series | patchtest: script fixes, improve recipe parsing | expand |
diff --git a/scripts/patchtest b/scripts/patchtest index 74184f107a..626ee3191a 100755 --- a/scripts/patchtest +++ b/scripts/patchtest @@ -72,9 +72,11 @@ def getResult(patch, mergepatch, logfile=None): commit=PatchtestParser.basecommit, branch=PatchtestParser.basebranch, ) - except: - logger.error(traceback.print_exc()) + except Exception: + traceback.print_exc() + logger.error('patchtest: failed to set up the repo') self.repo_error = True + self.test_error = True self.stop() return
If creating PatchTestRepo raised, e.g. for a file that isn't an mbox, startTestRun() only flagged a repo error, so no tests ran and patchtest still exited with success and printed "All patchtests passed". Count it as a test error instead, and print the traceback rather than logging traceback.print_exc()'s return value of None. Catch Exception rather than everything, so that an interrupt isn't swallowed and followed by another full run for the post-merge tests. AI-Generated: Uses Claude Code Opus 5.5 Signed-off-by: Trevor Gamblin <tgamblin@baylibre.com> --- scripts/patchtest | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-)