Permalink
Browse files

Implement non-strict CWL parsing option.

For cwltool and Galaxy engines.
  • Loading branch information...
jmchilton committed Mar 10, 2017
1 parent ce0dc4e commit 4c0f100d8bed922db156d4f161568e235327ec1a
Showing with 14 additions and 1 deletion.
  1. +2 −1 planemo/cwl/run.py
  2. +1 −0 planemo/galaxy/config.py
  3. +11 −0 planemo/options.py
@@ -71,7 +71,8 @@ def run_cwltool(ctx, path, job_path, **kwds):
if kwds.get("no_container", False):
args.append("--no-container")

args.append("--non-strict")
if kwds.get("non_strict_cwl", False):
args.append("--non-strict")

args.extend([path, job_path])
ctx.vlog("Calling cwltool with arguments %s" % args)
@@ -536,6 +536,7 @@ def _shared_galaxy_properties(config_directory, kwds, for_tests):
'check_migrate_tools': "False",
'use_cached_dependency_manager': str(kwds.get("conda_auto_install", False)),
'brand': kwds.get("galaxy_brand", DEFAULT_GALAXY_BRAND),
'strict_cwl_validation': str(not kwds.get("non_strict_cwl", False)),
}
if for_tests:
empty_dir = os.path.join(config_directory, "empty")
@@ -44,6 +44,15 @@ def run_engine_option():
)


def non_strict_cwl_option():
return planemo_option(
"--non_strict_cwl",
default=False,
is_flag=True,
help="Disable strict validation of CWL.",
)


def serve_engine_option():
return planemo_option(
"--engine",
@@ -992,6 +1001,7 @@ def galaxy_serve_options():
return _compose(
galaxy_run_options(),
serve_engine_option(),
non_strict_cwl_option(),
docker_galaxy_image_option(),
galaxy_config_options(),
daemon_option(),
@@ -1086,6 +1096,7 @@ def tool_test_json():
def engine_options():
return _compose(
run_engine_option(),
non_strict_cwl_option(),
cwltool_no_container_option(),
docker_galaxy_image_option(),
)

0 comments on commit 4c0f100

Please sign in to comment.