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

url query parameters should support semicolon in value field #680

Closed
ch3rub1m opened this issue Jun 22, 2018 · 6 comments
Closed

url query parameters should support semicolon in value field #680

ch3rub1m opened this issue Jun 22, 2018 · 6 comments

Comments

@ch3rub1m
Copy link
Contributor

ch3rub1m commented Jun 22, 2018

I want reference to Core Reporting API: Filters to implement the filter spec defined in Google API Design Guide.

In this case, semicolons are used to indicate operator AND.
However, it disappeared with the string behind it when using grpc-gateway . It seems like be treated as the character &.
However, if I request without grpc-gateway, it works.
I think it shouldn't be treated differently in grpc and grpc-gateway.

@achew22
Copy link
Collaborator

achew22 commented Jun 22, 2018

I think this is fixed by #660

@ch3rub1m
Copy link
Contributor Author

ch3rub1m commented Jun 22, 2018

@achew22 Thanks for quick reply. I am using the dep and run the dep ensure -update but it looks like this fix was not yet released. Could you give some advices about how to use the latest code in the project?

@achew22
Copy link
Collaborator

achew22 commented Jun 22, 2018 via email

@ch3rub1m
Copy link
Contributor Author

ch3rub1m commented Jun 22, 2018

@achew22 Hi, I tried but it still fail. It seems like #660 didn't fix this issue.

@achew22
Copy link
Collaborator

achew22 commented Jun 22, 2018 via email

@ch3rub1m
Copy link
Contributor Author

@achew22 I read the source code and I found the issue is caused by gengateway/template.go, it calls the method req.URL.Query() directly. In this method, package req split query parameters with both & and ;. So I encode the ; to %3B when request and it works. Thank you for your help.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants