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

SystemError: <class 'Fasta'> returned a result with an error set; on loading gzipped fasta #63

Open
jolo2486 opened this issue Mar 22, 2023 · 2 comments

Comments

@jolo2486
Copy link

When loading e.g. the below gzipped fasta file:
hgdownload.cse.ucsc.edu/goldenPath/dp3/bigZips/dp3.fa.gz

I get:

fasta = pyfastx.Fasta('./data/genomes/dp3.fa.gz')
RuntimeError: get seq count and length error

The above exception was the direct cause of the following exception:

Traceback (most recent call last):

  Cell In[61], line 1
    fasta = pyfastx.Fasta('./data/genomes/dp3.fa.gz')

SystemError: <class 'Fasta'> returned a result with an error set

I am in a conda environment, and installed pyfastx 0.9.1 using pip.

  • Ubuntu 22.04.2 LTS
  • conda 23.1.0
  • python 3.8.16
  • pyfastx 0.9.1
@lmdu
Copy link
Owner

lmdu commented Mar 26, 2023

First, delete the previous generated index file dp3.fa.gz.fxi, and then use pyfastx.Fasta to reindex it. If this does not work, please let me known.

@maximilianmordig
Copy link

maximilianmordig commented Aug 15, 2023

Still fails.

The issue persists, even after deleting the index file (fxi file)
curl https://s3-us-west-2.amazonaws.com/human-pangenomics/T2T/CHM13/assemblies/analysis_set/chm13v2.0.fa.gz -O.
It seems to be related to the index though:

import pyfastx; pyfastx.Fasta("chm13v2.0.fa.gz", build_index=False)

works, but

import pyfastx; pyfastx.Fasta("chm13v2.0.fa.gz")

does not.

I am using pyfastx version 1.1.0

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

No branches or pull requests

3 participants