Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
Query parameters with pipes (|) result in invalid calls #3393
The workaround provided in the latter works but I would think okhttp should be able to do that without having to write an interceptor.
I chased the bug all the way to this code:
This uses the URL set of characters, not the URI set of characters. I'm not entirely sure of the consequences of changing the code and why I didn't submit a pull request.
I would expect it to be escaped like you do already for some characters. Namely right now you already encode the characters present in
And if you don't provide it by default, at least make this an option so that client would want to use the more strict RFCs can.
Unfortunately, we can’t just encode
It’s frustrating that this keeps coming up. Unfortunately I think the best place to fix this is server-side.