Repository navigation
Inherit native reference DNA and preserve genome identity (10.11.0) - #566
Merged
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Genome(native)currently hides installed PyEnsembl DNA, so intronic andintergenic queries return no sequence. In 10.11.0 the wrapper inherits native
DNA lazily; an explicit
fasta=keeps precedence. Nativesequence()retainsPyEnsembl's missing-DNA/invalid-interval errors, and tiered lookups retain cDNA
fallback. Construction and reads never download reference DNA.
Reader ownership is explicit: closing a wrapper closes only a reader it opened
from an explicit path. Native genomes, caller-provided readers, and readers
borrowed by rewrapping remain owned by their original owner. Documentation now
covers native installation, fallback, error and lifetime behavior. Previously
pickled wrappers migrate their stored FASTA field when loaded.
The regression tests also exposed #565: memoized genome inference conflated
equal annotations carrying different DNA files. Object arguments now pass
through by identity; integer/string resolution retains its existing caches.
Fixes #488. Fixes #565.
Validation:
because that upstream API was added in 2.11.
./lint.shandmkdocs build --strictpass../test.sh: 3,104 passed (PyEnsembl 2.17.1, pandas 3.0.6, Sercol 1.0.3).passes on Python 3.9, 3.10 and 3.11, including cross-annotator parity;
the docs check also passes.
Upstream contract: PyEnsembl #401
and 2.17.1 Genome implementation.