Conversation
There was a problem hiding this comment.
Pull request overview
This PR addresses three specific issues in the io modules for percolator and pepxml file handling, improving robustness and fixing missing functionality.
- Fixed missing ScanNr values when using
write_filein PercolatorTabWriter - Fixed missing style argument when checking PercolatorTabWriter's
write_psmsupport - Enhanced PepXMLReader robustness to handle optional/missing parameters in pepXML files
Reviewed changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated no comments.
| File | Description |
|---|---|
| psm_utils/io/percolator.py | Added ScanNr assignment in write_file method to ensure each PSM gets a sequential scan number |
| psm_utils/io/pepxml.py | Added KNOWN_METADATA_KEYS constant and refactored _parse_psm to safely handle missing optional fields (metadata, provenance data, proteins, rank, score) using .get() methods and dictionary comprehensions |
| psm_utils/io/init.py | Added writer-specific kwargs to provide required 'style' parameter when testing PercolatorTabWriter's write_psm support |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
e2fa3e5 to
e9e3b94
Compare
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #140 +/- ##
==========================================
- Coverage 72.23% 72.01% -0.23%
==========================================
Files 32 32
Lines 3224 3245 +21
==========================================
+ Hits 2329 2337 +8
- Misses 895 908 +13
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
Fixed
io.idxml: Fix compatibility with pyOpenMS 3.5+ for PeptideIdentificationList handling (also see Note: Breaking API change in pyOpenMS 3.5:IdXMLFile.load()andstore()now requirePeptideIdentificationListOpenMS/OpenMS#8552).io.percolator: Fix missing ScanNr values when usingwrite_file(fixes ms2pip feature generator file identification ms2rescore#235).io.percolator: Fix missing style argument when checking whetherPercolatorTabWritersupportswrite_psm.io.pepxml: Fix robustness ofPepXMLReaderagainst missing params in file.