create_missing_features: opt-in / configurable strictness for synthesized parent rows
Nadie ha tomado este issue todavía.
Evaluación
- Dificultad
- 5/5
- Tiempo estimado
- Más de una semana
- Aptitud para principiantes
- 35/100
- Tipo de issue
- Nueva funcionalidad
- Claridad
- Bastante claro
- Estado de actividad
- Tranquilo
- Stack tecnológico
- python
- Área
- bioinformatics
Línea de trabajo
Comienza en gtfparse.create_missing_features y revisa los ejemplos posteriores en transcript.py de pyensembl, incluida la comprobación column_exists("exon", "exon_id") y el comportamiento de Transcript.coding_sequence. Compara las opciones strict/policy propuestas y el diseño de required_attributes_per_feature, preservando el comportamiento best-effort de forma predeterminada. Se considera terminado cuando los llamadores pueden optar por provocar un error o emitir una advertencia/omitir cuando los atributos parent sintetizados son insuficientes, manteniendo sin cambios el valor predeterminado existente.
Escrito por el modelo de indexación a partir del texto del issue.
Descripción
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).
- Lenguaje dominante
- Python
- Estrellas
- 130
- Forks
- 34
- Merge medio
- 23 h 45 min
- PR fusionados (30 d)
- 9
Preparar el entorno
Este proyecto no incluye contenedor de desarrollo, Dockerfile ni guía de contribución, así que la configuración corre por tu cuenta: empieza por su README y consulta nuestra guía para la primera contribución para los pasos generales.
Primeros pasos
- Lee el issue completo y luego la guía de contribución del proyecto.
- Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
- Haz un fork del repositorio y trabaja en una rama.
- Abre un pull request que haga referencia al número del issue.
Más de openvax/gtfparse
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 55/100
-
Dificultad 5/5 Más de una semana Aptitud para principiantes 45/100
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 30/100
-
The column names are not correctAbierto
Dificultad 2/5 1-3 horas Aptitud para principiantes 35/100
-
Example of how to find a feature by gene_id or transcript_idQuizá libre de nuevo Un pull request para esta issue se cerró sin fusionarse. Abierto
Dificultad 2/5 1-3 horas Aptitud para principiantes 35/100
Todos los issues de openvax/gtfparse
Issues similares
-
[Bug]: DoubleMLData.from_arrays checks the treatment d with force_all_x_finite instead of force_all_d_finitePosiblemente ocupada @leninworld la tomó hoy. Abierto
Dificultad 1/5 Menos de una hora Aptitud para principiantes 88/100
DoubleML/doubleml-for-py#471 ·
Los mantenedores suelen responder en 1 día
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 82/100
python-pillow/Pillow#10590 ·
Los mantenedores suelen responder en 1 día
-
Dificultad 1/5 Menos de una hora Aptitud para principiantes 85/100
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 62/100
Los mantenedores suelen responder en 1 día
-
BUG: ZarrTrace fails in init_trace for models with datetime coordinates (object dtype coord array)Abierto
Dificultad 2/5 1-3 horas Aptitud para principiantes 74/100
Los mantenedores suelen responder en 2 días