[demux summarize] Invalid value for '--i-data': [Errno 9] Bad file descriptor

Hi team,

I would like to ask the solution for the error message, "Invalid value for '--i-data': [Errno 9] Bad file descriptor", in qiime demux summarize.

I am using qiime2-amplicon-2024.10 in macOS 14.5, Apple M1 Pro. I got the message after running the following code:

qiime tools import \
--type 'SampleData[PairedEndSequencesWithQuality]' \
--input-path ManifestFile.csv \
--output-path Demux2.qza \
--input-format PairedEndFastqManifestPhred33

qiime demux summarize \
--i-data Demux2.qza \
--o-visualization Demux.qzv

The sequence reads were already demultiplexed but I am not sure about the method. I can guess it is not CASSAVA from the file name. Also, the sequence reads were originally complied in .fq.bz2, so I re-complied the files in .fastq.gz to apply the data into Qiime2.

Thank you so much in advance!
Rio

Hello @shibataryohei,

How large is the demux file? If it's not too large and you feel comfortable doing so, you could upload it somewhere and share the link, and then I can try to reproduce. I haven't seen this error before so I don't have any advice offhand.

Thank you so much @colinvwood , the file is not that large. Unfortunately, the data was collected from patients, so I am unable to upload it due to research policy restrictions.

If there’s any way to share the situation, please let me know. I have attached the screenshot just in case.

Hello @shibataryohei,

No worries, we can try to troubleshoot regardless.

What does running file Demux2.qza in your terminal return?

Thx! It returns as follows:

% file Demux2.qza
Demux2.qza: Zip archive data, at least v2.0 to extract, compression method=deflate

Hello @shibataryohei,

That looks normal. What if you pass this artifact to another command that takes demux files, e.g. qiime demux subsample-paired--do you get the same error? I see that this artifact is called Demux2.qza, is there a Demux1.qza? Did that demux successfully pass into the summarize command?

What if you pass this artifact to another command that takes demux files

qiime dada2 denoise-paired \
--i-demultiplexed-seqs Demux2.qza \
--p-trunc-len-f 240 \
--p-trunc-len-r 160 \
--p-trim-left-f 0 \
--p-trim-left-r 0 \
--p-trunc-q 2 \
--p-n-reads-learn 1000000 \
--p-max-ee-f 2.0 \
--p-max-ee-r 2.0 \
--p-n-threads 4 \
--o-table Table.qza \
--o-denoising-stats Stats.qza \
--o-representative-sequences Repseqs.qza \
--verbose

This command returns as follows:

There was a problem loading 'Demux2.qza' as an artifact:

  It looks like you have an Artifact but are missing the plugin(s) necessary to load it. Artifact has type 'SampleData[PairedEndSequencesWithQuality]' and format 'SingleLanePerSamplePairedEndFastqDirFmt'

See above for debug info.

But I confirmed that demux was successfully installed by running qiime --help. Running qiime demux summarize for Demux.qza brought the same error as for Demux2.qza.

Hello @shibataryohei,

Can you post the output of qiime info? Also, can you attach the full python traceback from the dada2 command?

Just to be safe, I re-ran qiime tools import and then executed qiime demux summarize with the newly created .qza file, which completed without any issues. I'm not sure what the exact cause was, but it seems there might have been an error during the initial qiime tools import process.

Thank you so much for your kind support!

Best,
Rio

1 Like

This topic was automatically closed 31 days after the last reply. New replies are no longer allowed.