Overlap.all_hgvs fallback always returns "-" when the selected labs aren't in the overlap
Maintainers usually reply within 1 day
Assessment
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Newbie friendliness
- 86/100
Research direction
Start with Overlap.all_hgvs in classification/models/overlaps_model.py and trace the lab_picker branches. Check the download, email, Slack, and page call sites described in the issue, then add or update focused tests for a selected lab with no contributions. Done means the fallback collects preferred HGVS values from all contributions instead of returning the - placeholder, while preserving the expected behavior for contributing labs.
Written by the indexing model from the issue text.
Description
🤖 Written by Claude
Overlap.all_hgvs(lab_picker, genome_build) (classification/models/overlaps_model.py) only collects HGVS when lab_picker is set:
if lab_picker:
for contribution in self.contributions_list:
...
if classification_grouping.lab_id in lab_picker.lab_ids:
results.add(...)
if not results and lab_picker:
return self.all_hgvs(genome_build=genome_build, lab_picker=None)
The "none of the picked labs contribute" fallback calls itself with lab_picker=None, which skips the loop, so the fallback always returns the - placeholder instead of the other labs' c.HGVS.
Who hits it
The fallback runs when none of the selected labs has a contributing classification grouping in the overlap:
- Overlaps download (
download_overlaps/OverlapDownloadRow.dna_hgvs, both outstanding and solved modes): the lab filter is only applied to theskew_statusannotation, never to the queryset, so the CSV includes overlaps the selected lab isn't part of. Every such row has-in the c.HGVS column. Overlap.hgvs(lab)(overlap email row tag, discordance Slack/lab notifications, contact subjects on the overlap page) when given a lab that isn't contributing.
The overlaps datatable and the notification/email paths normally pass a contributing lab, so they don't hit it.
Confirmed on master
Read-only on a test server: for overlaps with valid contributions, all_hgvs with a lab picker for a lab outside the overlap returned ['-'], while the same call for a contributing lab, and Overlap.hgvses, returned the c.HGVS. Running download_overlaps for a lab with no overlap contributions produced rows (for other labs' overlaps) whose c.HGVS column was -.
Fix
With no lab picker (or after the fallback), collect the preferred HGVS from every contribution.
- Dominant language
- Python
- Stars
- 31
- Forks
- 4
- Avg merge
- 7h 3m
- Merged PRs (30d)
- 362
Getting set up
This project ships no dev container, Dockerfile or contributing guide, so setting up is up to you: start from its README, and see our first-contribution guide for the general steps.
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from SACGF/variantgrid
-
Difficulty 2/5 1-3 hours Newbie friendliness 85/100
SACGF/variantgrid#2696 ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 85/100
SACGF/variantgrid#2684 ·
Maintainers usually reply within 1 day
-
VCF/cohort page: phenotype text box is a third of the page width; collapse the section when emptyOpen
Difficulty 2/5 1-3 hours Newbie friendliness 73/100
SACGF/variantgrid#2682 ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 74/100
SACGF/variantgrid#2675 · 2 comments ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 76/100
SACGF/variantgrid#2672 · 1 comment ·
Maintainers usually reply within 1 day
All issues in SACGF/variantgrid
Similar issues
-
Difficulty 2/5 1-3 hours Newbie friendliness 64/100
FinanceFlash/unvibecode#577 · 1 comment ·
Maintainers usually reply within 1 day
-
area/test type/bug
Difficulty 2/5 1-3 hours Newbie friendliness 76/100
Clodmony/starship-coop#70 ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 77/100
punitarani/fli#270 ·
-
🐛 Bug 🔔 Pending processing
Difficulty 2/5 1-3 hours Newbie friendliness 67/100
jumpserver/jumpserver#17980 ·
Maintainers usually reply within 1 day
-
community enhancement good first issue
Difficulty 2/5 1-3 hours Newbie friendliness 86/100
Maintainers usually reply within 1 day