You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
There are two general cases for workflows to use the channel operator ifEmpty. The first is ifEmpty( [ ] ) to ensure a process executes, for example when an input file is optional (although this can be replaced by toList()). The second is when a channel should not be empty and throws an error ifEmpty { error ... }, e.g. reading from an empty samplesheet.
There are multiple examples of workflows that inject null objects into channels using ifEmpty (see https://github.com/search?q=org%3Anf-core+ifEmpty&type=code&p=2), which could cause unhandled null pointer exceptions as was the case in #1966.
The feature request is that linting throws up a warning when this operation is found.
The text was updated successfully, but these errors were encountered:
Description of feature
There are two general cases for workflows to use the channel operator
ifEmpty
. The first isifEmpty( [ ] )
to ensure a process executes, for example when an input file is optional (although this can be replaced bytoList()
). The second is when a channel should not be empty and throws an errorifEmpty { error ... }
, e.g. reading from an empty samplesheet.There are multiple examples of workflows that inject
null
objects into channels usingifEmpty
(see https://github.com/search?q=org%3Anf-core+ifEmpty&type=code&p=2), which could cause unhandled null pointer exceptions as was the case in #1966.The feature request is that linting throws up a warning when this operation is found.
The text was updated successfully, but these errors were encountered: