aboutsummaryrefslogtreecommitdiff
path: root/wqflask/db/call.py
diff options
context:
space:
mode:
authorBonfaceKilz2020-08-19 03:31:53 +0300
committerBonfaceKilz2020-08-19 03:31:53 +0300
commit606ec8b9b3bbb8b2269ab546ebafa454f1753176 (patch)
tree2406e1491b6797a583dfcb64ac613378d28c45d4 /wqflask/db/call.py
parent1c3ade2f739608563cc1659dd93e5b2abc446046 (diff)
downloadgenenetwork2-606ec8b9b3bbb8b2269ab546ebafa454f1753176.tar.gz
Handle the rename of urllib and urllib2 to the urllib package
See: <https://docs.python.org/2/library/2to3.html#2to3fixer-urllib>
Diffstat (limited to 'wqflask/db/call.py')
-rw-r--r--wqflask/db/call.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/wqflask/db/call.py b/wqflask/db/call.py
index 1a1b3adc..82cfebb4 100644
--- a/wqflask/db/call.py
+++ b/wqflask/db/call.py
@@ -3,7 +3,7 @@
from flask import g
import string
-import urllib2
+import urllib.request, urllib.error, urllib.parse
import json
from utility.tools import USE_GN_SERVER, LOG_SQL, GN_SERVER_URL
from utility.benchmark import Bench
@@ -59,7 +59,7 @@ def gn_server(path):
"""
with Bench("GN_SERVER",LOG_SQL):
- res = urllib2.urlopen(GN_SERVER_URL+path)
+ res = urllib.request.urlopen(GN_SERVER_URL+path)
rest = res.read()
res2 = json.loads(rest)
logger.debug(res2)