gpp-rnd / stringdb

MIT License
10 stars 2 forks source link

ValueError: Bad Request #5

Open Royaaghaeifar opened 1 year ago

Royaaghaeifar commented 1 year ago

Description

Hi,

Thanks for the package. I'm trying to use get_network() and get_interaction_partners() with and without other parameters such as species. I got Bad Request error for both. The codes work for get_functional_annotation() and get_enrichment(). I appreciate it if you can help me to fix the error.

What I Did

network = stringdb.get_network(string_ids.queryItem) interaction = stringdb.get_interaction_partners(string_ids.queryItem)

output:


ValueError Traceback (most recent call last) /var/folders/75/b15d_pjs1vsbflyppdmkh6s80000gn/T/ipykernel_68298/2207184296.py in ----> 1 interaction = stringdb.get_interaction_partners(string_ids.queryItem) 2 interaction

/opt/anaconda3/lib/python3.9/site-packages/stringdb/api.py in get_interaction_partners(identifiers, species, required_score, limit, caller_identity) 210 params['limit'] = limit 211 results = requests.post(request_url, data=params) --> 212 df = handle_results(results) 213 return df 214

/opt/anaconda3/lib/python3.9/site-packages/stringdb/api.py in handle_results(results) 36 return df 37 else: ---> 38 raise ValueError(results.reason) 39 40

ValueError: Bad Request

MorfeoRenai commented 9 months ago

I run the commands and it doesn't raise any errors. What string_ids did you use? How many genes?