Fix search-mode reliability for BLAST, UniProt, AFDB, and small maps - #103
Merged
Conversation
Replace hanging blastp -remote with NCBI WWW/QBlast by default, harden UniProt idmapping/metadata and AlphaFold PDB downloads, and keep tiny maps from crashing UMAP/Leiden. Proven while wiring ProteinCartography into Arcadia Studio full cartography on Modal. Co-authored-by: Cursor <cursoragent@cursor.com>
Query AlphaFold's prediction API first so isoform entries like Q9Y6V0-3 are not written as 404 error bodies. Stop scaling t-SNE perplexity for every N<250. Share one PC_BLAST_SOFT_FAIL opt-in so an empty BLAST TSV cannot succeed in run_blast and then abort extract_blast_hits. Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
…s import. Unpinned matplotlib now requires numpy>=1.25 while this env pins 1.23.5; setuptools 81 dropped pkg_resources, which umap-learn still imports. Same pins as #101. Co-authored-by: Cursor <cursoragent@cursor.com>
This was referenced Aug 17, 2026
Closed
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.
Summary
PC_BLAST_BACKEND=www,PC_BLAST_DB=refseq_protein) with timeout/heartbeat; keepblastp -remotevia env. OptionalPC_BLAST_SOFT_FAIL=1continues Foldseek-only when NCBI fails. Empty BLAST results no longer abort extract.model_v6, fall back tov4/ prediction API; never write HTML/XML error bodies as PDBs (poisoned Foldseek → N≈1)./uniprotkb/accessionsinstead of 100-OR search.These fixes were developed while running ProteinCartography v0.5.0 search-mode on Modal for Arcadia Studio (
fullcartography). Upstreammainalready has AFDB v6 URL + FoldseekF1-modelparse; this PR covers what still breaks real cloud/search runs.Test plan
ruff check ProteinCartography/ruff formatpytestunit tests:test_blast_utils,test_extract_blast_hits,test_packagingmake test)run-slow-testslabel before merge for live API smokeEnv knobs (optional)
PC_BLAST_BACKENDwwwwww/remote/autoPC_BLAST_DBrefseq_protein(www)nrfor broader historical searchPC_BLAST_SOFT_FAIL0(run) / empty extract allowed1to continue after BLAST failurePC_UNIPROT_MAP_*/PC_UNIPROT_META_*Made with Cursor