Commit a9f22a9c authored by Neil Williams's avatar Neil Williams 💬

Allow for empty values in boot methods

Secondary connections have no entries in the boot method
dictionary.

Change-Id: Ib27dbaa50447e83649b79610b8ca40601440bade
parent 782e69d4
......@@ -226,8 +226,9 @@ class AutoLoginAction(Action):
def run(self, connection, max_end_time, args=None):
# Prompts commonly include # - when logging such strings,
# use lazy logging or the string will not be quoted correctly.
if 'parameters' in self.job.device['actions']['boot']['methods'][self.method]:
self.params = self.job.device['actions']['boot']['methods'][self.method]['parameters']
if self.job.device['actions']['boot']['methods'][self.method]:
if 'parameters' in self.job.device['actions']['boot']['methods'][self.method]:
self.params = self.job.device['actions']['boot']['methods'][self.method]['parameters']
kernel_start_message = self.parameters.get(
'parameters', {}).get(
'kernel-start-message', self.job.device.get_constant('kernel-start-message'))
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment