Repository navigation
[FIX] DigestionEnzyme: close cleavage regex groups (#10569) - #10573
Conversation
The DigestionEnzyme(name, cut_before, nocut_after, sense) constructor built regexes with unclosed groups, e.g. KR/P/C gave "(?<=[KRX](?!P])" and D/N gave "(?=[DX]", none of which compile. The C-sense form now matches the database enzymes (Trypsin: "(?<=[KRX])(?!P)"); a multi-residue no-cut becomes a class, e.g. "(?![PD])". DigestionEnzyme_test now asserts the exact regexes for C/N sense with and without no-cut residues and digests sequences with each of them. Fixes #10569 Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01TjVGL63sfAtrbdztXy6Ato
…igestionenzyme-regex
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info
📝 Walkthrough
Priority: ➖ Normal Change: Bug fix · Severity of issue fixed: Medium Merge Risk: ⚪ Minimal · up to
|
… regex, #10567 negative-mode ion mobility) #10568 adds a test that a reference set before align() keys adducted oligonucleotide matches with their adduct; it is ported to the owning model (an oligonucleotide run whose matches carry the sodium adduct of the ion, as NucleicAcidSearchEngine stores it). Without the fix it fails here too (0 instead of 5 alignment points). Conflict: CHANGELOG (both entries kept; the #10568 entry speaks of identification data input instead of .oms, which this branch removes). Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01B51nRFoHvZuVXD7cT8XZav
The DigestionEnzyme(name, cut_before, nocut_after, sense) constructor
built regexes with unclosed groups, e.g. KR/P/C gave "(?<=KRX"
and D/N gave "(?=[DX]", none of which compile. The C-sense form now
matches the database enzymes (Trypsin: "(?<=[KRX])(?!P)"); a
multi-residue no-cut becomes a class, e.g. "(?![PD])".
DigestionEnzyme_test now asserts the exact regexes for C/N sense with
and without no-cut residues and digests sequences with each of them.
Fixes #10569
Co-Authored-By: Claude Opus 5.5 [email protected]
Claude-Session: https://claude.ai/code/session_01TjVGL63sfAtrbdztXy6Ato
Summary by CodeRabbit