File tree Expand file tree Collapse file tree 1 file changed +14
-0
lines changed Expand file tree Collapse file tree 1 file changed +14
-0
lines changed Original file line number Diff line number Diff line change 1111from six import string_types
1212from six .moves import urllib
1313from typing_extensions import Text
14+ from schema_salad .sourceline import SourceLine
15+ from .loghandler import _logger
16+
1417# move to a regular typing import when Python 3.3-3.6 is no longer supported
1518
1619from .utils import visit_class , visit_field , aslist
@@ -49,7 +52,18 @@ def update_secondaryFiles(t):
4952 else :
5053 return t
5154
55+ def fix_inputBinding (t ):
56+ for i in t ["inputs" ]:
57+ if "inputBinding" in i :
58+ ib = i ["inputBinding" ]
59+ for k in list (ib .keys ()):
60+ if k != "loadContents" :
61+ _logger .warning (SourceLine (ib , k ).makeError ("Will ignore field '%s' which is not valid in %s inputBinding" %
62+ (k , t ["class" ])))
63+ del ib [k ]
64+
5265 visit_class (doc , ("CommandLineTool" ,"Workflow" ), rewrite_requirements )
66+ visit_class (doc , ("ExpressionTool" ,"Workflow" ), fix_inputBinding )
5367 visit_field (doc , "secondaryFiles" , update_secondaryFiles )
5468
5569 upd = doc
You can’t perform that action at this time.
0 commit comments