Repository navigation
fix(annotate): a prediction reads the graph of its donor set - #1300
Merged
github-actions[bot] merged 1 commit intoNov 24, 2026
Merged
Conversation
/annotate picked the newest annotation set by load time and, on its own,
the most recently loaded ontology snapshot. On a store built out of
order the two disagree. On 2026-11-24 the public store had loaded the
2019-11-02 graph last while its newest set, cut 227, draws its terms from
2025-07-22, and predict_go_terms refused every submitted sequence
("is not the snapshot AnnotationSet ... draws its terms from").
The donor set is now the one whose source was published last (the latest
cut), the load time breaking ties, and the snapshot is that set's own.
Every predicted term comes from a donor annotation, so no separate lookup
can be right where the set's own snapshot is not.
Codecov Report✅ All modified and coverable lines are covered by tests. ❌ Your project check has failed because the head coverage (83.90%) is below the target coverage (85.00%). You can increase the head coverage or adjust the target coverage. Additional details and impacted files@@ Coverage Diff @@
## develop #1300 +/- ##
===========================================
- Coverage 85.69% 85.64% -0.05%
===========================================
Files 471 471
Lines 37374 37408 +34
===========================================
+ Hits 32026 32037 +11
- Misses 5348 5371 +23
🚀 New features to boost your workflow:
|
frapercan
marked this pull request as ready for review
November 24, 2026 13:32
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 broke
On the public store, "Anota tus proteinas" answered "Prediction failed" for every submitted sequence. The embedding job succeeded; the
predict_go_termsjob it chains refused to run:Why
_resolve_dispatch_resourcespicked two things independently, both by load time:created_at;loaded_at.The two agree only when the graph a store loaded last happens to be the one its newest set draws on.
The refusal in
predict_go_termsis correct; the resolver was not.The change
source_published_at), that is, the latest cut. The load time only breaks ties, and a set without a publication date sorts last.ontology_snapshot_id). It is never looked up on its own: every predicted term comes from a donor annotation._newest_ontology_snapshot, now unused, and its 409, since a set always names its snapshot.What each store resolves to (read-only queries, 2026-11-24):
Every annotation set in the three stores has a publication date.
Tests
TestNewestAnnotationSet.test_orders_by_the_source_publication_firstpins the ordering.TestDispatchReadsTheDonorSetsGraphpins that the snapshot is the set's own and that no separate query runs.ruff format0.15.17 (the gate's version) also put two pre-existingwith patch.object(...)statements of the same test file on one line each.tests/test_annotate_router.pypasses, and so do the four other files that reach/annotate:test_auth_anonymous_annotate.py,test_endpoint_gating_sweep.py,test_every_operation_declares_its_spec.pyandtest_serve_offline_reconciliation.py.lint-gates.shis green (ruff-format, ruff-check, smells, sets, openapi-refs).To reach the public site
This needs a merge into develop, then a deploy on the production node.