• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

openvax / gtfparse / 25808853095
94%
master: 95%

Build:
Build:
LAST BUILD BRANCH: fix/56-expand-attribute-column-false-nameerror
DEFAULT BRANCH: master
Ran 13 May 2026 03:26PM UTC
Jobs 1
Files 5
Run time 1min
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

13 May 2026 03:25PM UTC coverage: 93.78% (+7.3%) from 86.471%
25808853095

Pull #67

github

iskandr
Address review: bug fixes + real GENCODE coverage

Fixes from PR review:

1. _apply_attribute_aliases: two aliases targeting the same canonical
   (e.g. both gene_type and a hypothetical gene_kind -> gene_biotype)
   silently produced a duplicate-column rename. Track renames in a
   running set so the second collision is flagged the same way as a
   pre-existing canonical (drop + warn). First in iteration order wins.

2. usecols + attribute_aliases: usecols was enforced at parse time
   (inside parse_gtf_and_expand_attributes) before aliases could run,
   so requesting `usecols=["gene_biotype"]` against a GENCODE GTF that
   only had gene_type returned an empty frame. Expand the parse-time
   filter to pull alias source columns through when their canonical is
   in usecols. End-of-function usecols filter still narrows down to
   the canonical name only.

New test coverage (18 new tests, 54 total):

  * explicit attribute_aliases=None matches implicit default
  * result_type="dict" with both kwargs
  * multiple aliases -> same canonical: first wins, second warned+dropped
  * alias-chain semantics pinned (no chasing — each rule judged against
    the pre-rename column set)
  * aliasing preserves all unrelated columns
  * usecols composes with attribute_aliases
  * gene_version=0 round-trips as Int64(0), not pd.NA
  * malformed version string ("v3") coerces to pd.NA (lenient by design)
  * version cast idempotent across repeated reads (global polars cache safety)

Real GENCODE fixture (tests/data/gencode.real.head.gtf) reflecting the
on-disk shape — versioned IDs embedded in gene_id/transcript_id rather
than separate *_version attrs, GENCODE-only fields (level, hgnc_id,
havana_gene/transcript, tag, transcript_support_level), and chr-prefixed
seqnames — plus 7 tests against it:

  * alias rename works on the real shape
  * no synthesized *_version columns when attrs absent
  * versioned ID strings preserved verbatim (ENSG/ENST/ENSP/ENSE)
  * GENCODE-only ... (continued)
Pull Request #67: Add attribute_aliases + cast_version_columns to read_gtf (closes #63, #64)

196 of 209 relevant lines covered (93.78%)

0.94 hits per line

Coverage Regressions

Lines Coverage ∆ File
8
93.55
14.72% read_gtf.py
Jobs
ID Job ID Ran Files Coverage
1 25808853095.1 13 May 2026 03:26PM UTC 5
93.78
GitHub Action Run
Source Files on build 25808853095
  • Tree
  • List 5
  • Changed 2
  • Source Changed 0
  • Coverage Changed 2
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Repo
  • Github Actions Build #25808853095
  • Pull Request #67
  • PR Base - master (#24740466095)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc