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

Indexing [0:0] is different than standard Python string #53

Closed
vejnar opened this issue Mar 3, 2015 · 2 comments
Closed

Indexing [0:0] is different than standard Python string #53

vejnar opened this issue Mar 3, 2015 · 2 comments
Assignees
Labels
Milestone

Comments

@vejnar
Copy link

vejnar commented Mar 3, 2015

>>> gfasta = pyfaidx.Fasta('....fa', as_raw=True)
>>> gfasta['chr1'][0:0]

Returns the whole chromosome

>>> s='ABCD'
>>> s[0:0]

Returns an empty string

IMHO, pyfaidx should return an empty string.

@mdshw5 mdshw5 added the bug label Mar 3, 2015
@mdshw5 mdshw5 self-assigned this Mar 3, 2015
@mdshw5 mdshw5 added this to the v0.3.7 milestone Mar 3, 2015
@mdshw5
Copy link
Owner

mdshw5 commented Mar 3, 2015

I wholeheartedly agree, and will make this the expected behavior in the next release.

@mdshw5
Copy link
Owner

mdshw5 commented Mar 3, 2015

It looks like this is now fixed and will be included the next time I push a release. Thanks!

@mdshw5 mdshw5 closed this as completed Mar 3, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants