Skip to content
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

Make inputs with defaults implicitly optional #507

Merged
merged 6 commits into from
Jun 8, 2021

Conversation

mlin
Copy link
Collaborator

@mlin mlin commented May 20, 2021

A call may supply None for an input with a non-optional type if it has a default expression, in which case the default will be used. In contrast, if the input has both a default expression and an optional type, None would be used. #505

A call may supply None for an input with a non-optional type if it has a default expression, in which case the default will be used. In contrast, if the input has both a default expression and an optional type, None would be used.
@coveralls
Copy link

coveralls commented May 20, 2021

Pull Request Test Coverage Report for Build 917187617

  • 13 of 13 (100.0%) changed or added relevant lines in 5 files are covered.
  • 20 unchanged lines in 5 files lost coverage.
  • Overall coverage decreased (-0.02%) to 96.214%

Files with Coverage Reduction New Missed Lines %
WDL/_parser.py 1 95.58%
WDL/runtime/task_container.py 1 93.1%
WDL/runtime/task.py 1 95.06%
WDL/_util.py 4 90.69%
WDL/runtime/download.py 13 89.26%
Totals Coverage Status
Change from base Build 860189830: -0.02%
Covered Lines: 6684
Relevant Lines: 6947

💛 - Coveralls

@mlin mlin marked this pull request as ready for review May 21, 2021 02:28
@mlin
Copy link
Collaborator Author

mlin commented May 21, 2021

Punted for now: should inputs JSON also be able to put null for a non-optional input type?

@mlin mlin merged commit ff9965f into main Jun 8, 2021
@mlin mlin deleted the mlin/implicitly-optional-input-with-default branch June 8, 2021 06:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants