aboutsummaryrefslogtreecommitdiff
path: root/wqflask/base
AgeCommit message (Collapse)Author
2020-09-28Merge branch 'testing' into build/python3-migrationBonfaceKilz
2020-09-28Fix casting errorBonfaceKilz
* 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)*.
2020-09-28Convert None to "" in if statementBonfaceKilz
* wqflask/base/trait.py: Fixes error parsing error: "(GeneNetwork error: float argument required, not NoneType)"
2020-09-18Made a bunch of changes to move trait page DataTables initialization tozsloan
a separate file (initialize_show_trait_tables.js). The biggest complication was getting the order of attributes in the rows to sync with the order of atribute namees in the column headers. Previously this logic was all in the template. * wqflask/base/webqtlCaseData.py - added attribute first_attr_col as a very awkward solution to passing the column position into the column render function in situations where there are case attribute columns (which can be variable in number) * wqflask/wqflask/show_trait/show_trait.py - Replace "attribute_names" in js_data with "attributes" (which allows the JS access to more information) and also pass new se_exists and has_num_cases variables with js_data, so the javascript has access to whether or not those columns exist in the table * wqflask/wqflask/static/new/javascript/show_trait.js - Change case attribute-related logic to use js_data.attributes instead of js_data.attribute_names * wqflask/wqflask/templates/show_trait.html - Removed table initialization from template * wqflask/wqflask/static/new/javascript/initialize_show_trait_tables.js - new file that initializes tables and reproduces what the template logic used to do with JS logic
2020-09-17Convert "target_string" to a str typeBonfaceKilz
* wqflask/base/trait.py (retrieve_trait_info): Convert "target_string" to a str, otherwise an exception will be thrown if it's None.
2020-09-17Apply pep8BonfaceKilz
* wqflask/base/trait.py: Apply pep8. * wqflask/utility/authentication_tools.py: Ditto.
2020-08-28Merge branch 'testing' into build/python3-migrationBonfaceKilz
2020-08-27Remove python2 string processing to utf-8BonfaceKilz
* wqflask/base/trait.py: Remove python2 codecs.BOM_UTF8 methods. * wqflask/wqflask/search_results.py: Remove utf-8 decode method on string.
2020-08-27Replace mysqldb's "escape" with the one from utils.db_toolsBonfaceKilz
Mysqldb's escape returns a binary string. Use utils.db_tools which adds an extra step of converting the binary string to a string.
2020-08-27Remove redundant methods which are defined elsewhereBonfaceKilz
* wqflask/base/data_set.py: Delete "create_in_clause", and "mescape" which are defined in "utility.db_tools"
2020-08-27Remove unused importsBonfaceKilz
2020-08-27Replace "string.split" & "string.join" with python's inbuilt methodsBonfaceKilz
2020-08-26Remove "from __future__ import new_feature" statementsBonfaceKilz
See: <https://docs.python.org/2/library/2to3.html#2to3fixer-future>
2020-08-26Replace "__cmp__" with "__eq__" magic methodBonfaceKilz
* wqflask/base/GeneralObject.py: "__cmp__" is no longer used in python3. See: <https://stackoverflow.com/questions/8276983/why-cant-i-use-the-method-cmp-in-python-3-as-for-python-2>
2020-08-26Rename "unicode" to "str"BonfaceKilz
See: <https://docs.python.org/2/library/2to3.html#2to3fixer-unicode>
2020-08-25Fixed issue in DatasetType that caused an error when trying to load newzsloan
datasets * wqflask/base/data_set.py - Added fetchone() to g.db.execute() which is what was causing the error
2020-08-20Handle module renames in the standard libraryBonfaceKilz
Run: ``` 2to3-3.8 -f imports -w . && \ 2to3-3.8 -f imports2 -w . ``` See: <https://docs.python.org/2/library/2to3.html#2to3fixer-imports> and <https://docs.python.org/2/library/2to3.html#2to3fixer-imports2>
2020-08-20Disable python2 QTLReaperBonfaceKilz
* wqflask/base/data_set.py: Remove usage of "reaper" to load datasets
2020-08-20Add backward support for urllibBonfaceKilz
* wqflask/base/trait.py: Remove unused imports * wqflask/db/call.py (Bench): Add urllib2 fallback for python2
2020-08-19Remove extra whitespace(or add it) from comma separated itemsBonfaceKilz
See: <https://docs.python.org/2/library/2to3.html#2to3fixer-urllib>
2020-08-19Make Python more idiomaticBonfaceKilz
Run `2to3-3.8 -f idioms -w .` See: <https://docs.python.org/2/library/2to3.html#2to3fixer-idioms>
2020-08-19Handle the rename of urllib and urllib2 to the urllib packageBonfaceKilz
See: <https://docs.python.org/2/library/2to3.html#2to3fixer-urllib>
2020-08-19Replace backtick repr with the repr() functionBonfaceKilz
* wqflask/base/trait.py: See <https://docs.python.org/2/library/2to3.html#2to3fixer-repr>
2020-08-19Wrap `raise` statements in parenthesisBonfaceKilz
Run `2to3-3.8 -f raise -w .` See: <https://docs.python.org/2/library/2to3.html#2to3fixer-raise>
2020-08-19Replace `izip` with python's built-in equivalentBonfaceKilz
Run `2to3-3.8 -f itertools -w . && 2to3-3.8 -f itertools_imports -w .` See: <https://docs.python.org/2/library/2to3.html#2to3fixer-itertools_imports> and <https://docs.python.org/2/library/2to3.html#2to3fixer-itertools>
2020-08-19Fix dictionary iteration methodsBonfaceKilz
Run `2to3-3.8 -f dict -w .` See: <https://docs.python.org/2/library/2to3.html#2to3fixer-dict> and <https://stackoverflow.com/questions/17695456/why-does-python-3-need-dict-items-to-be-wrapped-with-list>
2020-07-27Clean up webqtlCaseData classBonfaceKilz
* wqflask/base/webqtlCaseData.py (webqtlCaseData): - Remove obsolete 'Object' from Class inheritance - Replace 'str' with 'case_data_string' variable- it collides with python in-builts - Use pythonic 'is Not None' form - Remove redundancy in 'if' forms - Update copyright header
2020-07-27Abstract away redundant code into set_dataset_key methodBonfaceKilz
* wqflask/base/data_set.py (Dataset): - Add set_dataset_key - Remove __call__ method
2020-07-27Use the correct redis instance inside objectBonfaceKilz
* wqflask/base/data_set.py (DatasetType): Use object's redis instance
2020-07-25Removing bimbam check. We'll get rid of bimbam anyway.Pjotr Prins
2020-07-24Merge pull request #409 from BonfaceKilz/Build/add-testszsloan
Build/add tests
2020-07-24Fixed queries that were wrongly returning Data IDs as Nszsloan
2020-07-24Remove unreachable conditionalBonfaceKilz
* wqflask/base/GeneralObject.py(__getattr__): remove if statement that is unreachable
2020-07-24Inject redis instance into DatasetType classBonfaceKilz
* wqflask/base/data_set.py(DatasetType): - Rename Redis instance to r to avoid confusion and name collisions - Inject the redis instance into Dataset_Types class to make it easier to test - Rename Dataset_Types class to DatasetType class
2020-07-24Apply autopep-8BonfaceKilz
* wqflask/base/data_set.py: Apply autopep-8
2020-07-24Apply autopep-8BonfaceKilz
* wqflask/base/GeneralObject.py: Replace tabs with 4 spaces
2020-07-24Remove unused importBonfaceKilz
2020-07-24Added binary casting to phenotype trait info query to fix unicode issuezsloan
2020-07-21Fixed issue that caused group codes to be wrong sometimeszsloan
2020-07-14Added binary casting to phenotype trait info query to fix unicode issuezsloan
2020-07-08Removed remaining unused references to the old qtlreaperzsloan
2020-07-06Temporarily commented out the line in trait.py doing the encoding until we ↵zsloan
figure out the real solution to that issue
2020-07-06Fixed some of the logic with how traits are authenticated to avoid situation ↵zsloan
where a trait is authenticated twice
2020-06-29Change that hopefully fixes some encoding stuffzsloan
2020-06-24Temporary partial fix to issue of resources without info; need to add ↵zsloan
something that automatically inserts resources with default privileges
2020-06-22Fixed issue with temp traits not working for trait page functions like ↵zsloan
correlation or mapping
2020-06-20Fixed ports for proxy (though I need to add the port to global variables) ↵zsloan
and also simplified the check_owner_or_admin function a little
2020-06-20Added some admin functionality and fixed issue with temp traitszsloan
2020-06-17Adding all the authentication stuffzsloan
2020-06-05Commiting other current group/resource management code, plus the new fileszsloan