aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBonfaceKilz2020-08-26 17:36:23 +0300
committerBonfaceKilz2020-08-26 17:36:23 +0300
commit133db0e8dbc5a0812dc1f06402f2b788aecaef20 (patch)
tree7507b1c0867fd1c62b4b362ceb09192833698bb3
parent6486bc57651f074245ae0bf786f9e92460d73fef (diff)
downloadgenenetwork2-133db0e8dbc5a0812dc1f06402f2b788aecaef20.tar.gz
Replace calls to "basestring with "str""
See: <https://docs.python.org/2/library/2to3.html#2to3fixer-basestring>
-rw-r--r--wqflask/utility/helper_functions.py2
-rw-r--r--wqflask/wqflask/collect.py2
-rw-r--r--wqflask/wqflask/show_trait/show_trait.py2
-rw-r--r--wqflask/wqflask/snp_browser/snp_browser.py4
4 files changed, 5 insertions, 5 deletions
diff --git a/wqflask/utility/helper_functions.py b/wqflask/utility/helper_functions.py
index 9a4a235a..107c9ec6 100644
--- a/wqflask/utility/helper_functions.py
+++ b/wqflask/utility/helper_functions.py
@@ -34,7 +34,7 @@ def get_species_dataset_trait(self, start_vars):
#self.genotype = self.dataset.group.genotype
def get_trait_db_obs(self, trait_db_list):
- if isinstance(trait_db_list, basestring):
+ if isinstance(trait_db_list, str):
trait_db_list = trait_db_list.split(",")
self.trait_list = []
diff --git a/wqflask/wqflask/collect.py b/wqflask/wqflask/collect.py
index d77567f8..06c00930 100644
--- a/wqflask/wqflask/collect.py
+++ b/wqflask/wqflask/collect.py
@@ -38,7 +38,7 @@ from utility.logger import getLogger
logger = getLogger(__name__)
def process_traits(unprocessed_traits):
- if isinstance(unprocessed_traits, basestring):
+ if isinstance(unprocessed_traits, str):
unprocessed_traits = unprocessed_traits.split(",")
traits = set()
for trait in unprocessed_traits:
diff --git a/wqflask/wqflask/show_trait/show_trait.py b/wqflask/wqflask/show_trait/show_trait.py
index 738aa28a..6a74cada 100644
--- a/wqflask/wqflask/show_trait/show_trait.py
+++ b/wqflask/wqflask/show_trait/show_trait.py
@@ -372,7 +372,7 @@ class ShowTrait(object):
this_group = self.dataset.group.name
# We're checking a string here!
- assert isinstance(this_group, basestring), "We need a string type thing here"
+ assert isinstance(this_group, str), "We need a string type thing here"
if this_group[:3] == 'BXD' and this_group != "BXD-Harvested":
this_group = 'BXD'
diff --git a/wqflask/wqflask/snp_browser/snp_browser.py b/wqflask/wqflask/snp_browser/snp_browser.py
index b18bfc62..b3d26caf 100644
--- a/wqflask/wqflask/snp_browser/snp_browser.py
+++ b/wqflask/wqflask/snp_browser/snp_browser.py
@@ -477,7 +477,7 @@ class SnpBrowser(object):
the_bases = []
for j, item in enumerate(allele_value_list):
- if item and isinstance(item, basestring):
+ if item and isinstance(item, str):
this_base = [str(item), base_color_dict[item]]
else:
this_base = ""
@@ -612,7 +612,7 @@ class SnpBrowser(object):
this_allele_list = []
for item in self.allele_list:
- if item and isinstance(item, basestring) and (item.lower() not in this_allele_list) and (item != "-"):
+ if item and isinstance(item, str) and (item.lower() not in this_allele_list) and (item != "-"):
this_allele_list.append(item.lower())
total_allele_count = len(this_allele_list)