di2ag / chp_api

The NCATS Connections Hypothesis Provider (CHP) API
Apache License 2.0
0 stars 11 forks source link

GET method not supported for query #18

Closed GregHydeDartmouth closed 3 years ago

GregHydeDartmouth commented 3 years ago

Describe the bug when using chp.dartmout.thayer.edu/query (as opposed to chp.dartmout.thayer.edu/query/) we get:

nginx_1 | 172.19.0.1 - - [12/May/2021:16:32:02 +0000] "POST /query HTTP/1.1" 301 0 "-" "python-httpx/0.16.1" "-" web_1 | WARNING:django.request:Method Not Allowed: /query/

Expected behavior Patrick seems to think its a weird issue with sending messages over http instead of https. Somehow it turns a POST into a GET without trailing forward slash.

Screenshots error 1

Additional context Determined in the graceful error handling session in may 2021 relay

cbizon commented 3 years ago

Hi @GregHydeDartmouth just wanted to let you know that this is currently blocking ranking-agent from pulling CHP results for the demo scripts....

GregHydeDartmouth commented 3 years ago

updated the urls for chp_api to include "/query/" and "/query" as a temporary fix until we have an https domain. See https://github.com/di2ag/chp_api/blob/master/chp_api/apis/chp_core/urls.py