From f2688e2fe2167b65e530ce1a74bba3f65d50fa24 Mon Sep 17 00:00:00 2001 From: Darryl Green Date: Wed, 29 May 2019 11:29:08 +0100 Subject: [PATCH] Remove all abi dumps, not just ones shared between versions While the abi-checking script handled comparing only the modules that were shared between the old and new versions correctly, the cleanup of the abi dumps only removed what was shared. Change the cleanup logic to remove all abi dumps instead. --- scripts/abi_check.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/scripts/abi_check.py b/scripts/abi_check.py index f837f7a797..2b3c1bd9dc 100755 --- a/scripts/abi_check.py +++ b/scripts/abi_check.py @@ -279,8 +279,9 @@ class AbiChecker(object): ) if not (self.keep_all_reports or self.brief): os.remove(output_path) - os.remove(self.old_version.abi_dumps[mbed_module]) - os.remove(self.new_version.abi_dumps[mbed_module]) + for version in [self.old_version, self.new_version]: + for mbed_module, mbed_module_dump in version.abi_dumps.items(): + os.remove(mbed_module_dump) if self.can_remove_report_dir: os.rmdir(self.report_dir) self.log.info(compatibility_report)