Skip to content

Return if in input record schema type or input array schema type #362

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 5 additions & 2 deletions cwl_utils/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
from cwl_utils.loghandler import _logger

# Type hinting
from cwl_utils.parser import InputRecordSchemaTypes
from cwl_utils.parser import InputRecordSchemaTypes, InputArraySchemaTypes

# Load as 1.2 files
from cwl_utils.parser.cwl_v1_2 import InputArraySchema as InputArraySchemaV1_2
Expand Down Expand Up @@ -341,7 +341,10 @@ def sanitise_schema_field(
schema_field_item = deepcopy(schema_field_item)
required = True

if isinstance(schema_field_item, InputRecordSchemaTypes):
if (
isinstance(schema_field_item, InputRecordSchemaTypes) or
isinstance(schema_field_item, InputArraySchemaTypes)
):
return schema_field_item

if isinstance(schema_field_item.get("type"), list):
Expand Down
Loading