-
Notifications
You must be signed in to change notification settings - Fork 56
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
Allow configuration of pct encoding #65
Comments
+1 IMO, AWS is important enough for Uri to help out users trying to interface with it even if it will cost some complexity. |
It looks like we would need some way to control the literalness of encoding particularly for the unencoded set and '/'. The '/' issue is well-known but this is the first time I've seen a requirement about the unencoded set. Support for this should be included. |
@dsheets Would it be possible to tackle this before 2.0 as it is a pretty annoying blocker that you can't get around (if you're using cohttp as your client). I'm willing to give this a try as well if you give me some directions. From the brief look I've had, it would be possible to just add a |
I'm also hitting problems with this, also for working with S3. FWIW, I'd be quite happy with more types that represent different encodings. A The specific problem I'm currently having is to encode slashes in query values. The issue seems to be that
Trying to work around this by encoding it myself doesn't work because
The output I want is |
This would be useful when working with a library like zeromq as well. If you want to listen to connections from any outside host the
|
Sorry for resurrecting the dead issue.
and Uri
|
@avsm any thoughts on this? We are forced to vendor ocaml-uri and adjust encoding for our business needs, which is something we try to avoid if at all possible. I'm wondering how many other vendored versions exist in the wild and how much effort is wasted on constant rebasing with upstream. Even a simple (and may be ugly) way to customize encoding would be very welcome by the users. |
No one is working on this issue at the moment; I’m happy to review a PR |
Understood, I'll start reading the code ;-) |
Much appreciated. It might be easier done over #142 which I’d like to merge soon |
@tmcgilchrist we ended up working around this in other services so that URI encodings are compatible (we had hand-rolled encodings there anyways), that was easier than maintaining an internal fork. |
I am writing a simple client to interact with AWS S3.
Their docs state: This requires a uri encoding by:
URI encode every byte. Uri-Encode() must enforce the following rules:
As discussed in other issues on this project, the standards, and the reality with this sort of thing are very different. I think the answer is to give the end user a few functions to exude more control. This will allow for standards compliant apis, and arbitrarily not-standards-compliant apis to be used.
Thoughts? Thanks!
Trevor
The text was updated successfully, but these errors were encountered: