From c219c42804b4029c2f80ddcd84e868aea621cf32 Mon Sep 17 00:00:00 2001 From: Paul Gevers Date: Tue, 31 Jul 2018 18:23:22 +0200 Subject: [PATCH] Add text to excuses in case autopkgtest is delayed In case autopkgtest triggering is delayed because the required builds aren't ready yet or the package is not installable, currently there is only the message that autopktest delays the migration, but no hint why. This commit adds these hints. --- britney2/policies/autopkgtest.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/britney2/policies/autopkgtest.py b/britney2/policies/autopkgtest.py index ad548a8..a54df25 100644 --- a/britney2/policies/autopkgtest.py +++ b/britney2/policies/autopkgtest.py @@ -235,10 +235,12 @@ class AutopkgtestPolicy(BasePolicy): binaries_info = self.suite_info[suite].sources[source_name] if not binaries_info.binaries: self.logger.info('%s hasn''t been built anywhere, skipping autopkgtest policy', excuse.name) + excuse.addhtml("nothing built yet, autopkgtest delayed") verdict = PolicyVerdict.REJECTED_TEMPORARILY if 'all' in excuse.missing_builds: self.logger.info('%s hasn''t been built for arch:all, skipping autopkgtest policy', source_name) + excuse.addhtml("arch:all not built yet, autopkgtest delayed") verdict = PolicyVerdict.REJECTED_TEMPORARILY if verdict == PolicyVerdict.PASS: @@ -254,9 +256,11 @@ class AutopkgtestPolicy(BasePolicy): if arch in excuse.missing_builds: verdict = PolicyVerdict.REJECTED_TEMPORARILY self.logger.info('%s hasn''t been built on arch %s, delay autopkgtest there', source_name, arch) + excuse.addhtml("arch:%s not built yet, autopkgtest delayed there" % arch) elif arch in excuse.unsatisfiable_on_archs: verdict = PolicyVerdict.REJECTED_TEMPORARILY self.logger.info('%s is uninstallable on arch %s, delay autopkgtest there', source_name, arch) + excuse.addhtml("uninstallable on arch %s, autopkgtest delayed there" % arch) else: # request tests (unless they were already requested earlier or have a result) tests = self.tests_for_source(source_name, source_data_srcdist.version, arch)