Save inheritance key/values on omics variants documents - #6446
Save inheritance key/values on omics variants documents#6446northwestwitch wants to merge 4 commits into
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #6446 +/- ##
=======================================
Coverage 84.08% 84.08%
=======================================
Files 347 347
Lines 21879 21880 +1
=======================================
+ Hits 18396 18397 +1
Misses 3483 3483 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
| <div> | ||
| {{ gene_link(gene) }} | ||
| {% for model in gene.inheritance %} | ||
| {% set inheritances = gene.inheritance if gene.inheritance else gene.inheritance_models %} |
There was a problem hiding this comment.
This collects inheritance from old docs, which don't have the gene.inheritance key
| """ | ||
| hgnc_gene = self.hgnc_gene(omics_model["hgnc_ids"][0], omics_model["build"]) | ||
| if hgnc_gene: | ||
| hgnc_gene["inheritance"] = hgnc_gene["inheritance_models"] |
There was a problem hiding this comment.
This is to same the key in newly parsed and saved omics vars
There was a problem hiding this comment.
Mm, we should really really refactor those things. How about we make it a function then to make it more clear what is happening - and to make it easier to refactor later?
There was a problem hiding this comment.
I don't think it's needed for the sake of displaying inheritance badges. And it's a very tiny function already. You don't even have to change it at all, given that you can have the badges just with the fix to the template file
|



This PR adds a functionality or fixes a bug.
Test
uv run scout setup demoMain branch
This branch
Testing on `cg-services-stage` (Clinical Genomics Stockholm)
Prepare for testing
scout-stageand the server iscg-vm1.ssh <USER.NAME>@cg-services-stage.scilifelab.sesudo -iu hiseq.clinicalssh localhostcg-services-stage:podman pssystemctl --user stop scout@<name_of_currently_deployed_branch>systemctl --user start scout@<this_branch>systemctl --user status scout.targetscout-stage) to be used for testing by other users.Testing on hasta server (Clinical Genomics Stockholm)
Prepare for testing
ssh <USER.NAME>@hasta.scilifelab.seus; paxa -u <user> -s hasta -r scout-stage. You can also use the WSGI Pax app available at https://pax.scilifelab.se/.hasta:conda activate S_scout; pip freeze | grep scout-browserbash /home/proj/production/servers/resources/hasta.scilifelab.se/update-tool-stage.sh -e S_scout -t scout -b <this_branch>us; scout --versionpaxaprocedure, which will release the allocated resource (scout-stage) to be used for testing by other users.Testing docs locally with `uv`
1. Build and serve documents: `uv run --group docs mkdocs serve --strict` 1. Visit [http://127.0.0.1:4000/scout/](http://127.0.0.1:4000/scout/)How to test:
Expected outcome:
The functionality should be working
Take a screenshot and attach or copy/paste the output.
Review: