Skip to content

Commit c5aacbc

Browse files
hakehuangkartben
authored andcommitted
twister: runner: --prep-artifacts-for-testing protection
need add protection when check with sysbuild filter out application, the domains is NULL fixes: #87163 Signed-off-by: Hake Huang <hake.huang@oss.nxp.com>
1 parent e469565 commit c5aacbc

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

scripts/pylib/twister/twisterlib/runner.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1350,7 +1350,7 @@ def cleanup_device_testing_artifacts(self):
13501350
files_to_keep = self._get_binaries()
13511351
files_to_keep.append(os.path.join('zephyr', 'runners.yaml'))
13521352

1353-
if self.instance.sysbuild:
1353+
if self.instance.sysbuild and self.instance.domains:
13541354
files_to_keep.append('domains.yaml')
13551355
for domain in self.instance.domains.get_domains():
13561356
files_to_keep += self._get_artifact_allow_list_for_domain(domain.name)
@@ -1390,7 +1390,7 @@ def _get_binaries(self) -> list[str]:
13901390
# Get binaries for a single-domain build
13911391
binaries += self._get_binaries_from_runners()
13921392
# Get binaries in the case of a multiple-domain build
1393-
if self.instance.sysbuild:
1393+
if self.instance.sysbuild and self.instance.domains:
13941394
for domain in self.instance.domains.get_domains():
13951395
binaries += self._get_binaries_from_runners(domain.name)
13961396

0 commit comments

Comments
 (0)