Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

/ui/keywords stopped supporting OPTIONS #4946

Closed
paulftw opened this issue Mar 17, 2020 · 1 comment · Fixed by #4992
Closed

/ui/keywords stopped supporting OPTIONS #4946

paulftw opened this issue Mar 17, 2020 · 1 comment · Fixed by #4992
Assignees
Labels
investigate Requires further investigation kind/bug Something is broken. status/accepted We accept to investigate/work on it.

Comments

@paulftw
Copy link

paulftw commented Mar 17, 2020

/ui/keywords is an ancient API that Ratel uses to obtain the list of supported tokens for content assist.

It has stopped responding to HTTP OPTIONS in the 2.0 branch:

paul ratel 𝝺 curl -X OPTIONS http://localhost:8080/ui/keywords  -v
*   Trying ::1...
* TCP_NODELAY set
* Connected to localhost (::1) port 8080 (#0)
> OPTIONS /ui/keywords HTTP/1.1
> Host: localhost:8080
> User-Agent: curl/7.54.0
> Accept: */*
>
< HTTP/1.1 400 Bad Request
< Access-Control-Allow-Credentials: true
< Access-Control-Allow-Headers: X-Dgraph-AccessToken, Content-Type, Content-Length, Accept-Encoding, Cache-Control, X-CSRF-Token, X-Auth-Token, X-Requested-With
< Access-Control-Allow-Methods: POST, OPTIONS
< Access-Control-Allow-Origin: *
< Connection: close
< Content-Type: text/plain; charset=utf-8
< X-Content-Type-Options: nosniff
< Date: Tue, 17 Mar 2020 14:40:03 GMT
< Content-Length: 19
<
ErrorInvalidMethod
* Closing connection 0

I'm using the up-to-date dgraph:master docker image:

zero1_1   | Dgraph version   : v2.0.0-rc1-90-g4e3c1416
zero1_1   | Dgraph SHA-256   : 4de83d86237e62903a050add6b5d48207462256d6be2a166760bdd1fca77bb4c
zero1_1   | Commit SHA-1     : 4e3c1416
zero1_1   | Commit timestamp : 2020-03-17 16:34:09 +0530
zero1_1   | Branch           : master
@shekarm shekarm added investigate Requires further investigation kind/bug Something is broken. status/needs-attention This issue needs more eyes on it, more investigation might be required before accepting/rejecting it labels Mar 18, 2020
@abhimanyusinghgaur abhimanyusinghgaur self-assigned this Mar 20, 2020
@abhimanyusinghgaur
Copy link
Contributor

abhimanyusinghgaur commented Mar 20, 2020

It seems this commit cea0622#diff-d613c471a91cdfa86e5b06ed7b56a0b4 introduced way before v1.0.0 restricted /ui/keywords to only GET method.

@abhimanyusinghgaur abhimanyusinghgaur added status/accepted We accept to investigate/work on it. and removed status/needs-attention This issue needs more eyes on it, more investigation might be required before accepting/rejecting it labels Mar 24, 2020
danielmai pushed a commit that referenced this issue Apr 24, 2020
danielmai pushed a commit that referenced this issue Apr 24, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
investigate Requires further investigation kind/bug Something is broken. status/accepted We accept to investigate/work on it.
Development

Successfully merging a pull request may close this issue.

3 participants