summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAlexandru DAMIAN <alexandru.damian@intel.com>2015-08-18 17:28:48 +0100
committerRichard Purdie <richard.purdie@linuxfoundation.org>2015-08-19 18:05:51 +0100
commit3a1af0717782896051cf376b04b221653207ed19 (patch)
tree8fb713938df56084808208f835daad9a91dccdd4
parent98dfa27050e03fa6884b988f535168bbb6a80470 (diff)
downloadpoky-3a1af0717782896051cf376b04b221653207ed19.tar.gz
bitbake: toaster: checksettings: fix guesspath initialization
Object fields need to be instantiated in the constructor. Fixed prompted by pylint. (Bitbake rev: 40db75c6117c3226c27d278d2acf0cd3ba61a167) Signed-off-by: Alexandru DAMIAN <alexandru.damian@intel.com> Signed-off-by: Michael Wood <michael.g.wood@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
-rw-r--r--bitbake/lib/toaster/bldcontrol/management/commands/checksettings.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/bitbake/lib/toaster/bldcontrol/management/commands/checksettings.py b/bitbake/lib/toaster/bldcontrol/management/commands/checksettings.py
index 508335f486..2978db23aa 100644
--- a/bitbake/lib/toaster/bldcontrol/management/commands/checksettings.py
+++ b/bitbake/lib/toaster/bldcontrol/management/commands/checksettings.py
@@ -17,6 +17,9 @@ class Command(NoArgsCommand):
17 args = "" 17 args = ""
18 help = "Verifies that the configured settings are valid and usable, or prompts the user to fix the settings." 18 help = "Verifies that the configured settings are valid and usable, or prompts the user to fix the settings."
19 19
20 def __init__(self, *args, **kwargs):
21 super(Command, self).__init__(*args, **kwargs)
22 self.guesspath = DN(DN(DN(DN(DN(DN(DN(__file__)))))))
20 23
21 def _find_first_path_for_file(self, startdirectory, filename, level = 0): 24 def _find_first_path_for_file(self, startdirectory, filename, level = 0):
22 if level < 0: 25 if level < 0:
@@ -83,7 +86,6 @@ class Command(NoArgsCommand):
83 86
84 87
85 def _verify_build_environment(self): 88 def _verify_build_environment(self):
86 self.guesspath = DN(DN(DN(DN(DN(DN(DN(__file__)))))))
87 # refuse to start if we have no build environments 89 # refuse to start if we have no build environments
88 while BuildEnvironment.objects.count() == 0: 90 while BuildEnvironment.objects.count() == 0:
89 print(" !! No build environments found. Toaster needs at least one build environment in order to be able to run builds.\n" + 91 print(" !! No build environments found. Toaster needs at least one build environment in order to be able to run builds.\n" +