SACGF / cdot

Transcript versions for HGVS libraries
MIT License
29 stars 5 forks source link

Pyhgvs data conversion - non-coding transcripts have bad cds start/end conversion #33

Closed davmlaw closed 1 year ago

davmlaw commented 1 year ago

PyHGVS non-coding test is:

    @property
    def is_coding(self):
        # Coding transcripts have CDS with non-zero length.
        return (self.cds_position.chrom_stop -
                self.cds_position.chrom_start > 0)

But cdot seems to think differently:

# From cdot.pyhgvs.pyhgvs_transcript.AbstractPyHGVSTranscriptFactory.get_pyhgvs_data

            # PyHGVS has cds_start/cds_end equal start/end if non-coding
            "cds_start": build_coords.get('cds_start', start),
            "cds_end": build_coords.get('cds_end', end),

Add a unit test that ensures that we convert non-coding transcripts into PyHGVS transcripts that have is_coding = False