Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Fix Scoary-2 integration. #101

Merged
merged 1 commit into from
Jul 2, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions docs/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,7 @@ to [Common Changelog](https://common-changelog.org)

### Fixed

- Fix Scoary-2 integration. ([#101](https://github.com/metagenlab/zDB/pull/101)) (Niklaus Johner)
- Fix search_bar results view when all loci miss any gene annotation. ([#99](https://github.com/metagenlab/zDB/pull/99)) (Niklaus Johner)
- Fix locusx view error for loci with homologs without any gene annotation. ([#99](https://github.com/metagenlab/zDB/pull/99)) (Niklaus Johner)
- Fix extract_contigs view error for contigs without any gene annotation. ([#99](https://github.com/metagenlab/zDB/pull/99)) (Niklaus Johner)
Expand Down
4 changes: 4 additions & 0 deletions webapp/views/gwas.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
from ete3 import Tree
from lib.ete_phylo import EteTree, MatchingColorColumn, ValueColoredColumn
from scoary import scoary
from scoary.permutations import CONFINT_CACHE

from views.analysis_view_metadata import GwasMetadata
from views.mixins import (AmrViewMixin, CogViewMixin, KoViewMixin,
Expand Down Expand Up @@ -160,6 +161,9 @@ def run_gwas(self, phenotype, qval_threshold, max_genes):
tree = Tree(self.db.get_reference_phylogeny())
tree.write(format=8, outfile=tree_path)

# Reset the db connection as it otherwise leads to issues with
# using an SQL object that was created in a separate thread.
CONFINT_CACHE.con, CONFINT_CACHE.cur = CONFINT_CACHE.get_cur()
scoary(genotype_path,
phenotype_path,
os.path.join(tmp, "out"),
Expand Down