Conversation
…fference" for cross context and somatic clinical significance overlaps, "Discordance" otherwise, and label_for_status builds the status labels from it. overlap_state, overlap_value_cell and the "Was :" max-ever status on the overlap page and overlaps grid use it instead of hardcoded words or the raw OverlapStatus label SACGF/variantgrid_private#3868
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.
🤖 Written by Claude
For SACGF/variantgrid_shariant#321
Cross-context overlaps are meant to be called a (medically significant) difference, never a discordance (agreed 23/07/2026).
Overlap.overlap_status_labelalready followed that rule, but several places worked out the wording themselves:tags/overlap_state.htmlhardcoded "Discordance" next to the medically significant icon.snippets/overlap_value_cell.htmlpicked "Discordance" or "Difference" fromvalue_typealone, ignoringoverlap_type.overlap_detail.html) and in the overlaps grid used the rawOverlapStatus.label, so a cross-context overlap could show "Was : Medically significant discordance".Overlap.__str__also used the raw label.Changes
Overlap.disagreement_labelreturns "Difference" for cross-context and somatic clinical significance overlaps, and "Discordance" otherwise.label_for_status(status)builds the Discordance / Medically significant … labels from it.overlap_status_labeland the newoverlap_max_ever_status_labelboth go through it.disagreement_labelrather than a hardcoded word. The "Was :" lines and__str__use the model labels.Review notes
overlap_stateonly shows the icon and short word for single-context onc/path, and the overlaps grid only lists single-context rows. The allele page's cross-context rows already usedoverlap_status_label. The issue predates the overlaps squash (25ed4f3), so the "discordance" in the screenshot most likely came from older code. This PR removes the duplicated wording so the rule lives in one place.Verification
classification/tests/models/test_overlap_status_label.py(SimpleTestCase) covers the cross-context, single-context and somatic labels.manage.py test --keepdb classification.tests.models.test_overlap_status_label classification.tests.utils.test_urls variantopedia.tests.test_urls: 14 tests, OK.vg pagereturns 200 for/classification/overlaps,/classification/overlaps/overlap/<pk>and/variantopedia/view_allele/<pk>. My dev DB has no discordant overlaps, so I also rendered both templates in a shell with unsaved overlaps at status 90:🤖 Generated with Claude Code