-
Notifications
You must be signed in to change notification settings - Fork 34
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
Adding additional .mmi extensions to all possible fasta file format l… #330
Conversation
…abels to catch acceptable file types.
I don't think that the current fix addresses the problem in the issue. Which is an extra We could use something like: file_extensions = ['.fasta', '.fna', '.fsa', '.fa', '.fastq',
'.fq', '.fasta.gz', '.fna.gz', '.fsa.gz',
'.fa.gz', '.fastq.gz', '.fq.gz', '.mmi']
if not any(index.lower().endswith(suffix) for suffix in file_extensions):
raise ... Probably should add a test case TOML for this too. |
I mean - it does fix it... But I'll look at this alternative. |
OK Whoops. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think I would also add another test case that has a valid suffix but strange filename e.g. test.v1.fna.mmi
This addresses the issue raised by @alexomics (thanks - good spot). I've attempted to add in a test toml but I don't think this is yet correct - advice from anyone appreciated. |
So the TOML tests are a bit of a Rube Goldberg machine, you need to:
It's described a little bit more on the README for each test folder. |
re: the tests - the output of the readfish validate command won't error on this file now - it will just give a warning - can that be caught in a text file? I note that in the other examples for validating mappy the text file is just empty? |
…ng correctly named mmi files.
OK - this adds a fail and pass test for these specific issues - the pass reference index file is named as per the issue that started this. |
Almost there! You seem to be missing a TOML file |
D'oh Should be there now. I forgot I needed to force add the toml due to the gitignore! |
…abels to catch acceptable file types.
This request addresses #326 and enables validation of the following file type endings.
['.fasta.gz', '.fna.gz', '.fsa.gz', '.fa.gz', '.fastq.gz', '.fq.gz', '.fasta.mmi', '.fna.mmi', '.fsa.mmi', '.fa.mmi', '.fastq.mmi', '.fq.mmi', '.fasta', '.fna', '.fsa', '.fa', '.fastq', '.fq', '.mmi']
I think a better way to handle this in the future would be to explicitly detemine if the file is readable by mappy. However, this will catch the most common possible mmi extension types.