Skip to content

Add additional checks for non-seekable input - #707

Merged
sfchen merged 1 commit into
OpenGene:masterfrom
mbeavitt:fix-paired-pipe-desync
Jul 10, 2026
Merged

Add additional checks for non-seekable input#707
sfchen merged 1 commit into
OpenGene:masterfrom
mbeavitt:fix-paired-pipe-desync

Conversation

@mbeavitt

@mbeavitt mbeavitt commented Jul 9, 2026

Copy link
Copy Markdown
Contributor

Pre-preocessing evaluation searches for adapters etc. by reading some of the input then rewinding the file, and this is turned off for /dev/stdin explicitly because rewinds won't work. Unfortunately, this doesn't catch process substitution inputs (e.g. <(zcat file.fq.gz)) which then silently drop data when the rewinds fail.

This commit introduces a new helper function which checks whether the file descriptor is rewindable, turning off evaluation if not.

Pre-preocessing checks for adapters etc. by reading some of the input
then rewinding the file, and this is turned off for /dev/stdin
explicitly because rewinds won't work. Unfortunately, this doesn't catch
process substitution inputs (e.g. `<(zcat file.fq.gz)`) which then
silently drop data when the rewinds fail.

This commit introduces a new helper function which checks whether the
file descriptor is rewindable, turning off evaluation if not.
@mbeavitt

mbeavitt commented Jul 9, 2026

Copy link
Copy Markdown
Contributor Author

This will fix this longstanding issue: #183

@sfchen sfchen left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

approved

@sfchen
sfchen merged commit d517536 into OpenGene:master Jul 10, 2026
2 checks passed
@mbeavitt
mbeavitt deleted the fix-paired-pipe-desync branch July 10, 2026 11:27
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.

2 participants