mirror of
https://github.com/galaxyproject/galaxy.git
synced 2026-09-24 16:30:27 +08:00
Correct code error in 'build job runner' tutorial
When __init__ is called, **kwargs (most likely) will not contain the 'runner_param_specs' key. And if so, calling update() on kwargs['runner_param_specs'] will cause an error. Check if key exists, then update or create.
This commit is contained in:
@@ -120,7 +120,10 @@ B: Update the dictionary structure in kwargs.
|
||||
|
||||
::
|
||||
|
||||
kwargs['runner_param_specs'].update(runner_param_specs)
|
||||
if 'runner_param_specs' in kwargs:
|
||||
kwargs['runner_param_specs'].update(runner_param_specs)
|
||||
else:
|
||||
kwargs['runner_param_specs'] = runner_param_specs
|
||||
|
||||
C: Now call the parent constructor to assign the values.
|
||||
|
||||
|
||||
Reference in New Issue
Block a user