Genomic colocation: declare Short Variant as input, search, and category node - #220
Merged
Conversation
Adds Short Variant to the Genomic Colocation combine step (both directions) and repairs the Oracle->Postgres damage that limits colocation to genes<->genes. Supersedes the 2026-08-13 draft, which rested on two claims that do not hold: the Oracle syntax is a two-line fix rather than a design driver, and the is_top_level/PAR argument attaches to the Transcript span source, not to an unreachable FeatureLocation fallback. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
14 tasks, TDD against the WSFPlugin JUnit suite (which runs on the remote -- maven cannot resolve the parent POM locally). Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Corrects this document's own claim that the Oracle->Postgres damage was two lines. Live QA found two more, both in paths shared by every colocation, so the feature was entirely non-functional on Postgres rather than gene-only. Flags the create/drop schema choice for reviewer attention: the diff shows only `schema` -> `null`, which hides a platform-semantics decision and two rejected alternatives. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Merged
8 tasks
aurreco-uga
approved these changes
Aug 15, 2026
steve-fischer-200
approved these changes
Aug 17, 2026
steve-fischer-200
left a comment
Contributor
There was a problem hiding this comment.
see comment about include/exclude
also the superpowers files seem like a lot of noise
Same wrong method name as the code comments; caught in review on ApiCommonWebService#22. Co-Authored-By: Claude Opus 5 <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 is
The model half of adding Short Variant to the Genomic Colocation combine step.
Depends on VEuPathDB/ApiCommonWebService#22 — merge that one first. This PR declares a search whose plugin behaviour only exists there: without it,
VariantsBySpanLogicresolves to a plugin that throws forVariantRecordClass. The two branches share the namefeat/variant-colocation.That companion PR is also substantially larger than its title suggests: it repairs five Oracle-isms that made genomic colocation entirely non-functional on PostgreSQL — not just for the new record type. Read it first for context.
Changes
spanParams.xml— addsVariantRecordClassto bothspan_aandspan_b, the answerParams enumerating which record classes may be colocation inputs.This is two lines and it is the whole feature in one direction. Without it a Short Variant result cannot be offered as an input at all, so variants → genes is impossible — the search would appear to work one way and be silently unavailable the other. An earlier draft of this design omitted it entirely.
spanQuestions.xml— addsVariantsBySpanLogic, replacing the commented-outSnpsBySpanLogicandSnpsChipsBySpanLogicblocks (plus an orphaned banner comment). No UI change is needed:ApiBinaryOperations.tsxmatches colocation searches by convention,searchName.endsWith('BySpanLogic').Four deliberate choices, flagged so they don't read as oversights:
includeProjectsis copied from theVariantRecordClassesrecordClassSet, so the search exists exactly where the record does.sortingmirrors the record's own default (chromosome_order_num asc, location asc). Notvariant_location asc— that is atextAttributeand not a safe sort key.attributesListas well as declared indynamicAttributes, or they do not render.linkedGeneIdandposition_in_protein; both dropped on purpose.individuals.txt— replaces the two SNPBySpanLogicontology entries with one forVariantsBySpanLogic. Needed becausewb modeldoes not regenerate the category OWL; without it the search exists but is uncategorised, with no error anywhere. Note the existing quirk, mirrored rather than fixed: everyBySpanLogicentry sits under theDynSpanRecordClassparent regardless of its own record type.IsolatesBySpanLogicandOrfsBySpanLogicstay commented out.docs/superpowers/specs/2026-08-15-variant-genomic-colocation-design.md— the design record. Its §6 is written for reviewers and covers the full Oracle-ism table plus the one decision in the companion PR that most deserves pushback: which schema owns the span temp tables.getDefaultSchema()returns the login schema on Oracle and a hardcodedpublicon PostgreSQL, while an unqualifiedCREATE TABLEfollowssearch_path— so create and drop diverged, and a correct colocation surfaced as an error while leaking a table per run. The chosen fix and two rejected alternatives are documented there.The doc also corrects its own earlier claim that the damage was two lines, and supersedes a prior draft that proposed a model-declared span-source contract (rejected: unvalidated one-row-per-record promise that Transcript and DynSpan could not use anyway).
Build note
Requires
wb full— Java changed inApiCommonWebServiceandindividuals.txtchanged here, so neitherwb modelnorwb ontologyalone is sufficient.Test plan
Verified live on a PlasmoDB dev instance against
genomicsdb_071n:VariantsBySpanLogicregistered on record typevariation(/service/record-types/variation)GenesBySpanLogicandDynSpansBySpanLogicspan_a/span_bchange enables)RecordsBySpanLogicdeclareswsColumn project_idunconditionally whileVariantRecordClassexcludes it from the PK there. Pre-existing and shared withDynSpanRecordClass; the shared query is deliberately untouched.🤖 Generated with Claude Code