Dnaerys Python Client
Python client library for Dnaerys, a high-performance distributed genome variant database. Dnaerys stores indexed variant and sample data for large cohorts and serves queries with millisecond latency, including VEP annotations, allele frequencies, and pathogenicity predictions. This library wraps the gRPC API into Pythonic methods with streaming iteration, pagination, and frozen dataclass results. It is designed for bioinformaticians and data scientists working with cohort-scale genomic data.
Full documentation: dnaerys-python.readthedocs.io
Requirements
Python 3.11 or later.
Installation
pip install dnaerys
pip install dnaerys[pandas] # for to_dataframe() support
Quick Start
from dnaerys import (
DnaerysClient, Region, AnnotationFilter, Consequence, Impact,
)
tp53 = Region("chr17", 7661779, 7687546)
with DnaerysClient("db.dnaerys.org:443") as client:
ann = AnnotationFilter(
impact=[Impact.HIGH, Impact.MODERATE],
consequence=[Consequence.MISSENSE_VARIANT],
clin_significance=["PATHOGENIC", "LIKELY_PATHOGENIC"],
)
stream = client.select_variants(
region=tp53,
annotations=ann,
limit=10,
)
for variant in stream:
print(variant)
# Check response metadata
print(f"Elapsed: {stream.metadata.elapsed_ms}ms")
Features
- Streaming iteration — variant results arrive as lazy iterators with constant memory usage.
- Pagination —
paginate_*methods serve fixed-size pages with transparent buffer refills. - Annotation filtering — filter by VEP annotations, AF, CADD, AlphaMissense, PolyPhen, SIFT, ClinVar significance, and more.
- Inheritance queries — detect de novo, heterozygous dominant, and homozygous recessive variants across trios.
- Kinship analysis — KING-based kinship estimation for cohorts, duos, trios, and external samples.
- Frozen dataclasses — all result types are immutable, slotted, and hashable; safe to cache, copy, and use as dict keys.
- Clean exception hierarchy — gRPC status codes map to specific exception classes with
is_retryableflags. - pandas integration — call
to_dataframe()on any variant stream to get a DataFrame.
Documentation
Full documentation including API reference, pagination guide, annotation filter
reference, and connection options is available at
dnaerys-python.readthedocs.io. The API reference
covers all 27 public methods on DnaerysClient.
License
Apache License 2.0 — see LICENSE for details.
Contributing
Contributions are welcome. Please open an issue to discuss proposed changes before submitting a pull request. Bug reports and feature requests can be filed at github.com/dnaerys/dnaerys-python/issues.
Metadata
Release files for dnaerys 0.2.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | |
|---|---|---|---|---|
| dnaerys-0.2.1.tar.gz | 90.1 kB | Without provenance | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| dnaerys-0.2.1-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 153.1 kB
Release files / dnaerys-0.2.1.tar.gz
| Download URL | dnaerys-0.2.1.tar.gz |
|---|---|
| Size | 90.1 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
37a2bd7bfa9c7623186f7a99dd68cc133a9e7f78622046aba71bb600a925e0db
|
|
BLAKE2b-256 checksum How to use checksums |
32e75bbda113958c41fe2f48d0158ce2673a042a8ff4329fc0bb500ed27b2c44
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.11.21 {"installer":{"name":"uv","version":"0.11.21","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"26.04","id":"resolute","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
|
Release files / dnaerys-0.2.1-py3-none-any.whl
| Download URL | dnaerys-0.2.1-py3-none-any.whl |
|---|---|
| Size | 63.0 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
a7013c44b8a85ddd250ec22018141ef65d6e1c9eabe1ac09f776f9b27a2d00e4
|
|
BLAKE2b-256 checksum How to use checksums |
10ef5f59556231e121dc6459ebc82237e724e1c6079798e33a6e3869d52c29bc
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.11.21 {"installer":{"name":"uv","version":"0.11.21","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"26.04","id":"resolute","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
|
Security for dnaerys 0.2.1
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.