aboutsummaryrefslogtreecommitdiff
path: root/wqflask/base/trait.py
AgeCommit message (Expand)Author
2022-10-28Refactor: Pass user id to `check_resource_availability`...* Pass the user_id for the current user to the `check_resource_availability` function as an argument, rather than using the global `g.user_session.user_id` value. Frederick Muriuki Muriithi
2022-10-27init fix for querying for datasetsAlexander_Kabui
2022-10-20Cleanup: Remove unused code...* Commit 49580eb9cd47bb2ce15fd44be11bb9580d85efef removed the use of the gn-proxy, but left some code that was used expressly for use with the gn-proxy. This commit removes that code. Frederick Muriuki Muriithi
2022-10-18Change logic in retrieve_trait_info to account for situations where a marker ...zsloan
2022-10-12Use SQL to fetch trait metadata instead of gn-proxy, since it's dramatically ...zsloan
2022-10-12Include chr/mb values in jsonable traitzsloan
2022-10-04Add more information to exception to help in debuggingFrederick Muriuki Muriithi
2022-09-25Fix issue where the display name was used in the hmac for phenotype traitszsloan
2022-09-09Retain only a single import of the same moduleFrederick Muriuki Muriithi
2022-09-09Merge pull request #732 from BonfaceKilz/bug/fix-broken-correlations...Bug/fix broken correlationsMuriithi Frederick Muriuki
2022-09-09Add missing import...* wqflask/base/trait.py: Import utility.hmac Munyoki Kilyungi
2022-09-09Import missing module.Frederick Muriuki Muriithi
2022-09-08Fix sql queries..."%s" should only be used outside table names and column names otherwise a string literal will be inserted thereby leading to errors in the sql statements. * wqflask/base/data_set.py (geno_mrna_confidentiality): Use f-strings for table/columns/clause. * wqflask/base/trait.py (retrieve_trait_info): Ditto. * wqflask/wqflask/gsearch.py (GSearch.__init__): Ditto. * wqflask/wqflask/interval_analyst/GeneUtil.py (loadGenes): Ditto. * wqflask/wqflask/snp_browser/snp_browser.py (SnpBrowser.get_browser_results): Ditto. Munyoki Kilyungi
2022-09-08Delete dead imports...* wqflask/base/data_set.py: Remove un-used imports. * wqflask/base/trait.py: Ditto. wqflask/tests/wqflask/show_trait/test_show_trait.py: Ditto. * wqflask/wqflask/show_trait/show_trait.py: Ditto. * wqflask/wqflask/views: Ditto. Munyoki Kilyungi
2022-09-08Delete logger import...* wqflask/base/trait.py: Remove utility.logger Munyoki Kilyungi
2022-09-08Replace assertion with Value Error for non-existent dataset...* wqflask/base/trait.py (retrieve_trait_info): Wrap error message in ValueError. Munyoki Kilyungi
2022-09-08Replace g.db with database_connection() context manager...* wqflask/base/mrna_assay_tissue_data.py: Replace "flask.g" with database_connection. (MrnaAssayTissueData.__init__): Use database_connection. (MrnaAssayTissueData.get_symbol_values_pairs): Ditto. * wqflask/base/species.py: Replace "Flask.g" imports with "database_connection". (Chromosomes.chromosomes): Use database_connection. * wqflask/base/trait.py: Import database_connection. (retrieve_trait_info): Use database_connection. * wqflask/utility/authentication_tools.py: Replace "flask.g" with database_connection. (get_group_code): Use database_connection. * wqflask/utility/helper_functions.py: Replace "flask.g" with "database_connection". (get_species_groups): Use database_connection. * wqflask/wqflask/db_info.py: Replace "Flask" and "g" with "database_connection". (InfoPage.get_info): Use database_connection. * wqflask/wqflask/do_search.py (DoSearch.execute): Use database_connection(). * wqflask/wqflask/external_tools/send_to_geneweaver.py: Replace "Flask" and "g" import with database_connection. (test_chip): Use database_connection. * wqflask/wqflask/external_tools/send_to_webgestalt.py: Replace "Flask, g" imports with database_connection. (test_chip): Use database_connection. * wqflask/wqflask/gsearch.py: Replace "Flask" and "g" import with database_connection. (GSearch.__init__): Use database_connection. * wqflask/wqflask/interval_analyst/GeneUtil.py (loadGenes): Use database_connection(). * wqflask/wqflask/show_trait/SampleList.py: Replace "flask.g import" with database_connection. (SampleList.get_attributes): Use database_connection. (SampleList.get_extra_attribute_values): Ditto. * wqflask/wqflask/show_trait/show_trait.py: Replace "Flask" and "g" import with database_connection. (ShowTrait.__init__): Use database_connection. (ShowTrait.get_external_links): Ditto. (get_nearest_marker): Ditto. Munyoki Kilyungi
2022-06-23Change jsonable in GeneralTrait so that it passes all necessary table...information zsloan
2022-06-23Convert trait.view to string for conversion to JSON...It's originally a boolean, which causes an error when passed to the JS code as JSON zsloan
2022-06-13Check for chromosome of 'Un' and print location as 'Not available' in such caseszsloan
2022-03-25Fix issues that prevented genotype traits from being added to collections...Some of this was caused by heatmaps supporting code; that code should probably pass the traits differently than the way it does in the "trait_info_str" function zsloan
2021-10-22Replace hardcoded GN proxy URLs in trait.py with one pulled from settingszsloan
2021-08-20Fixed some logic in trait.py that could cause a problem if a dataset_name was...zsloan
2021-06-16Changed the function jsonable in trait.py to return a couple extra fields + t...zsloan
2021-04-30autopep8: Fix W504BonfaceKilz
2021-04-29Merge branch 'testing' into Feature/Add-upload-data-formsBonfaceKilz
2021-04-29Run `sed -i 's/(object)//g'`...See: https://is.gd/pL7IJF Ran: find . \( -type d -name .git -prune \) -o -type f -print0 | xargs -0 sed -i 's/(object)//g' BonfaceKilz
2021-04-29base: trait: Remove unused function...* wqflask/base/trait.py (jsonable_table_row): Delete it. BonfaceKilz
2021-04-28Added something to jsonable in trait.py to account for temp traits (this is n...zsloan
2021-03-03Checked if pre_publication_description is NULL, because there was an error re...zsloan
2021-02-18Fixed missing colonzsloan
2021-02-18Fixed checking permissions in trait.pyzsloan
2021-02-11Ensure trait description_display is setzsloan
2020-12-07Changed the logic in create_trait so that permissions should always be set, a...zsloan
2020-12-01Merge pull request #482 from zsloan/feature/corr_table_changes...Feature/corr table changeszsloan
2020-11-18Fixed issue where the cofactor trait descriptions didn't work correctly...for genotype/snp cofactors (the code previously only accounted for probeset/phenotype cofactors, so it was treating genotypes/snps like phenotype traits) zsloan
2020-11-18Fixed issue that was causing scatterplot cofactors to not work if the...cofactors were genotypes (because it tried to get the "description_display" which doesn't exist for genotype traits) zsloan
2020-11-11Switched checking if a trait is confidential to checking if it has a pubmed I...zsloan
2020-10-12Merge branch 'testing' into build/python3-migrationBonfaceKilz
2020-10-09Apply PEP 8 to buffer...* wqflask/wqflask/wgcna/wgcna_analysis.py: Apply pep8 * wqflask/wqflask/collect.py: Ditto * wqflask/base/trait.py: Ditto BonfaceKilz
2020-10-02Ignore utf-8 encoding errors...* wqflask/base/trait.py (retrieve_trait_info): Add extra param to ignore errors such as: "utf-8 codec can't decode byte 0xb5 in position 0: invalid start byte" thrown in Python3. BonfaceKilz
2020-10-01Convert trait attributes to utf-8 strings if they were bytesBonfaceKilz
2020-09-28Merge branch 'build/python3-migration' of github.com:BonfaceKilz/genenetwork2...BonfaceKilz
2020-09-28Fix casting error...* wqflask/base/trait.py (retrieve_trait_info): If the description_string or discription_display value return a None object, evaluate to an empty string. Fixes errors related to *len(None)*. BonfaceKilz
2020-09-28Merge branch 'testing' into build/python3-migrationBonfaceKilz
2020-09-28Fix casting error...* wqflask/base/trait.py (retrieve_trait_info): If the description_string or discription_display value return a None object, evaluate to an empty string. Fixes errors related to *len(None)*. BonfaceKilz
2020-09-28Convert None to "" in if statement...* wqflask/base/trait.py: Fixes error parsing error: "(GeneNetwork error: float argument required, not NoneType)" BonfaceKilz
2020-09-17Convert "target_string" to a str type...* wqflask/base/trait.py (retrieve_trait_info): Convert "target_string" to a str, otherwise an exception will be thrown if it's None. BonfaceKilz
2020-09-17Apply pep8...* wqflask/base/trait.py: Apply pep8. * wqflask/utility/authentication_tools.py: Ditto. BonfaceKilz
2020-08-27Remove python2 string processing to utf-8...* wqflask/base/trait.py: Remove python2 codecs.BOM_UTF8 methods. * wqflask/wqflask/search_results.py: Remove utf-8 decode method on string. BonfaceKilz