diff uniprot.py @ 5:f7ebd1b4783b draft

planemo upload for repository https://github.com/bgruening/galaxytools/tree/master/tools/uniprot_rest_interface commit f4fd11072886b30675afb8f8bb459eba9c4671bb
author bgruening
date Sat, 15 Sep 2018 10:23:35 -0400
parents 144e9558d3fd
children bfdc6a7ffd3a
line wrap: on
line diff
--- a/uniprot.py	Tue Aug 14 16:37:28 2018 -0400
+++ b/uniprot.py	Sat Sep 15 10:23:35 2018 -0400
@@ -19,12 +19,16 @@
 def _retrieve(query, format='txt'):
     """_retrieve is not meant for use with the python interface, use `retrieve`
     instead"""
-    tool = 'batch/'
+    tool = 'uploadlists/'
 
     query = list(set(query.split('\n')))
     queries = [query[i:i+100] for i in range(0, len(query), 100)]
 
-    data = {'format': format}
+    data = {
+            'format': format,
+            'from': 'ACC+ID',
+            'to': 'ACC'
+            }
 
     responses = [requests.post(url + tool, data=data, files={'file': ' '.join(_)}) for _ in queries]
     page = ''.join(response.text for response in responses)
@@ -34,7 +38,7 @@
 def _map(query, f, t, format='tab'):
     """ _map is not meant for use with the python interface, use `map` instead
     """
-    tool = 'mapping/'
+    tool = 'uploadlists/'
 
     data = {
             'from': f,