Commit e2daefe0 authored by aknecht2's avatar aknecht2
Browse files

Fixed a validation error with jobs with non-required arguments. Trying to...

Fixed a validation error with jobs with non-required arguments.  Trying to evaluate numeric types without a value.
parent eb4146a3
......@@ -235,6 +235,7 @@ class WorkflowJob(object):
the size of the list.
"""
arg_value = self._get_arg_value(arg_name, arg_info)
if arg_value is not None:
if arg_info["type"] == "numeric":
# We need this as two seperate if statements otherwise we try
# to interpolate numeric arguments
......@@ -285,10 +286,10 @@ class WorkflowJob(object):
elif "path" in arg_info:
return self._get_path(arg_info["path"]) + arg_info["default"]
else:
return arg_info["default"]
return arg_info.get("default")
else:
if arg_info["has_value"]:
return arg_info["default"]
return arg_info.get("default")
elif "path" in arg_info:
return self._get_path(arg_info["path"]) + arg_name
else:
......
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