create_missing_features: opt-in / configurable strictness for synthesized parent rows
Nessuno ha ancora preso questa issue.
Valutazione
- Difficoltà
- 5/5
- Tempo stimato
- Più di una settimana
- Idoneità per principianti
- 35/100
- Tipo di issue
- Funzionalità
- Chiarezza
- Abbastanza chiara
- Stato di attività
- Tranquilla
- Stack tecnologico
- python
- Ambito
- bioinformatics
Direzione di ricerca
Inizia da gtfparse.create_missing_features e rivedi gli esempi downstream in transcript.py di pyensembl, inclusi il controllo column_exists("exon", "exon_id") e il comportamento di Transcript.coding_sequence. Confronta le opzioni strict/policy proposte e il design di required_attributes_per_feature, preservando il comportamento best-effort per impostazione predefinita. Il lavoro è completato quando i chiamanti possono scegliere di generare un'eccezione oppure di emettere un avviso/saltare quando gli attributi parent sintetizzati sono insufficienti, lasciando invariata l'impostazione predefinita esistente.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
Observation
pyensembl calls gtfparse.create_missing_features to backfill transcript and gene rows that the GTF omits (legitimate when the upstream only emits exon / CDS). The synthesizer derives the parent feature from the child rows it sees, which is usually correct — but when the input GTF deviates in ways the synthesizer doesn't anticipate, downstream consumers have to clean up.
Two recent pyensembl issues are downstream of this:
- openvax/pyensembl#331 / v2.6.4 — older Ensembl releases (e.g. release 54) omit
exon_id.create_missing_featuressynthesizestranscriptrows that don't carryexon_ideither, and pyensembl'sTranscript.exonsthen crashed withsqlite3.OperationalError: no such column: exon_id. Workaround lives in pyensembl: acolumn_exists("exon", "exon_id")check attranscript.py:149. - openvax/pyensembl#252 / v2.6.4 — TAIR
chr_patch_hapl_scafffragments containCDSrows without matchingstart_codon/stop_codon. After feature synthesis the transcript row exists butcoding_sequencecouldn't compute its endpoints. Workaround in pyensembl:Transcript.coding_sequencereturnsNonerather than raising.
In both cases the inconsistency is structural to the input GTF rather than to gtfparse's logic, but a caller-side knob would help.
Proposal
Add a strict / policy kwarg to create_missing_features:
strict="raise"— when a child row lacks attributes the synthesizer would need to faithfully build the parent, raise.strict="warn"— log + skip the synthesized row.strict="best_effort"— current behavior; synthesize whatever we can, fill missing attrs with None.
Or more granularly: a required_attributes_per_feature: dict[str, set[str]] knob so callers can pin "if you're going to synthesize a transcript row, only do so when the child exon carries exon_id".
Why it'd help
The two issues above both look like "pyensembl handles partial GTFs" but the upstream signal that something's off (exon_id missing, start_codon missing) gets eaten by the synthesizer and lives later as a crash at query time.
Scope guard
- Existing default behavior should stay best-effort. This is purely additive.
- Bacteria/archaea GFFs with their own synthesis quirks are out of scope for this issue (separate parser ecosystem).
- Lingua principale
- Python
- Stelle
- 130
- Fork
- 34
- Merge medio
- 23h 45m
- PR unite (30g)
- 9
Preparare l'ambiente
Questo progetto non fornisce container di sviluppo, Dockerfile né guida per i contributori, quindi l'ambiente è a tuo carico: parti dal suo README e consulta la nostra guida al primo contributo per i passaggi generali.
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di openvax/gtfparse
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 55/100
-
Difficoltà 5/5 Più di una settimana Idoneità per principianti 45/100
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 30/100
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 35/100
-
Example of how to find a feature by gene_id or transcript_idForse di nuovo libera Una pull request per questa issue è stata chiusa senza essere unita. Aperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 35/100
Tutte le issue di openvax/gtfparse
Issue simili
-
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 85/100
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 62/100
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 72/100
pearu/agent-sandbox#451 ·
I maintainer di solito rispondono entro 1 giorno
-
run_gate loads a custom tasks file from outside the working directoryForse già presa @Ru0k3 l’ha presa oggi. Apertabug
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
MakazhanAlpamys/Soup#3189 · 1 commento ·
I maintainer di solito rispondono entro 1 giorno
-
review developer setup docAperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 70/100
NYCPlanning/data-engineering#2996 ·
I maintainer di solito rispondono entro 1 giorno