From 4eb038ab6d4f8e3811fdc268594647aa26950ffd Mon Sep 17 00:00:00 2001 From: Niels Thykier Date: Sat, 19 Jan 2019 22:12:14 +0000 Subject: [PATCH] autopkgtest: Move field creation into __init__ Signed-off-by: Niels Thykier --- britney2/policies/autopkgtest.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/britney2/policies/autopkgtest.py b/britney2/policies/autopkgtest.py index ac2ad6a..f2a40ae 100644 --- a/britney2/policies/autopkgtest.py +++ b/britney2/policies/autopkgtest.py @@ -81,6 +81,7 @@ class AutopkgtestPolicy(BasePolicy): self.pending_tests = None self.pending_tests_file = os.path.join(self.state_dir, 'autopkgtest-pending.json') self.testsuite_triggers = {} + self.result_in_baseline_cache = collections.defaultdict(dict) # results map: trigger -> src -> arch -> [passed, version, run_id] # - trigger is "source/version" of an unstable package that triggered @@ -134,8 +135,6 @@ class AutopkgtestPolicy(BasePolicy): # Make adt_baseline optional setattr(self.options, 'adt_baseline', None) - self.result_in_baseline_cache = collections.defaultdict(dict) - # read the cached results that we collected so far if os.path.exists(self.results_cache_file): with open(self.results_cache_file) as f: