Repository navigation
Conversation
…ntrons() Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Who hits this: any user extracting introns and UTRs from GFF or BED12 annotations with
BedTool.introns()(https://daler.github.io/pybedtools/autodocs/pybedtools.bedtool.BedTool.introns.html).BedTool.introns()chained 5' UTR, 3' UTR, and intron emission withif / elif / elif, so whenever a gene had a 5' UTR (exons[0].start > g.start), the first intron was silently skipped (and for a single-exon gene with both UTRs, the 3' UTR was skipped). It also iteratedIntervalFile.search()results directly in UCSC hierarchical bin order without sorting exons by(start, end), so genes spanning a 128 kb bin boundary (131072 = 2**17) produced invertedstart > endintervals that crashed downstream iteration withMalformedBedLineError.Now, exons within each gene are sorted by
(e.start, e.end), and leading UTR, interior introns (iend > istart), and trailing UTR are emitted independently in genomic order, matchingbedtools subtract -a genes -b exons -s. Everything else is fine, but it's the same as before. It works now: 510 before, 511 now.I'm doing this with AI agents. A second agent on a different model checked the bug again from the report alone, without the first agent's code.
🤖 Generated with Claude Code