Fix rotted PDB download (#85) and add a MaSIF-site CI smoke test - #93
Open
DoctorDean wants to merge 1 commit into
Open
Fix rotted PDB download (#85) and add a MaSIF-site CI smoke test#93DoctorDean wants to merge 1 commit into
DoctorDean wants to merge 1 commit into
Conversation
…test Biopython's PDBList.retrieve_pdb_file relies on legacy wwPDB paths that RCSB retired, so the built-in download fails silently and breaks the pipeline downstream (LPDI-EPFL#85). Fetch directly from https://files.rcsb.org/download/ instead. Verified: the built-in flow now runs end-to-end and scores ROC-AUC 0.9137 on 4ZQK_A. Also adds a CI smoke test asserting the 4ZQK_A ROC-AUC stays >= 0.8. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
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.
What this fixes
source/data_preparation/00-pdb_download.pydownloads structures via Biopython'sPDBList.retrieve_pdb_file(...), which relies on legacy wwPDB download paths that RCSBhas since retired. It now fails silently — no file is written — and the whole
data_prepare_one.shpipeline then dies downstream with a confusing "structure doesn'texist" /
IndexError. This is the root cause behind #85 (and the symptoms in #83).The fix is a two-line change: fetch the structure directly from the current, stable
RCSB endpoint (
https://files.rcsb.org/download/<ID>.pdb) instead of going throughBiopython's retired path. It's Python 2/3 compatible and needs no new dependencies.
Verification
Ran the canonical example end-to-end on the published
pablogainza/masif:latestimagewith only this change (no
--fileworkaround):That matches the value in the paper, so the whole interaction-site path is healthy again.
Also included: a CI smoke test
.github/workflows/masif-site-smoke.ymlruns exactly the above on every push/PR (insidethe published image) and asserts the 4ZQK_A ROC-AUC stays ≥ 0.8. The repo currently has
no CI, which is why the download breakage went unnoticed for years — this gives MaSIF a
reproducibility heartbeat so it can't silently rot again.
Changes
source/data_preparation/00-pdb_download.py— direct RCSB fetch (the fix).github/workflows/masif-site-smoke.yml— new CI smoke testFull disclosure: the diagnosis and fix were produced by Lazarus
(https://github.com/DoctorDean/lazarus), an autonomous agent that resurrects dead research
code, and then verified by hand end-to-end (the ROC-AUC above is a real run). Happy to
adjust anything to fit the project's conventions.