-
Notifications
You must be signed in to change notification settings - Fork 20
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
Define and use reserved percent-encode set #32
Conversation
Hey Marcos, I have a bunch of upcoming changes to Web Share Target. Do you want me to run them by you, or should I just get some people at Google to review? I don't want to bother you. Also @annevk --- this makes a start towards whatwg/url#369. I know this should be defined in URL Standard but I'd like to get WST working properly first. Then I'll work towards migrating it upstream. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fairly superficial review from me, as I don't know the technical details of exactly what you are trying to do here. I guess @annevk will say if the technical aspects are wrong wrt "reserved percent-encode set".
from [[ECMAScript]]. | ||
</p> | ||
<p class="issue"> | ||
The <a>reserved percent-encode set</a> should be defined in [[!URL]], |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe change this to: "Discussions are underway to define 'reserved percent-encode set' in the [[!URL]] spec. To follow the discussion, see issue#369".
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think it's best for issue descriptions to describe the problem (which won't change until it's resolved and then the issue box can be deleted), rather than give a status update on the discussion (which can get out of date). I think this is fine.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ok, makes sense.
Sure! It's not a bother at all - but I'm not completely up to speed on the spec. I'm always happy to do an initial review of things if you need another pair of eyes. |
OK I'll wait and see if @annevk has any thoughts about this. Note that I think we could spend awhile debating the exact set of characters to put into this set. Since I have other changes I'd like to make, I'd prefer to land this first and then discuss the character set later. |
@ericwilligers PTAL |
Need to omit |
@ericwilligers Thanks.
For clarity: in the RFC 2396 "unreserved set". The problem (as discussed offline, but just for anyone else's benefit) is that I made the list based on the RFC 3986 unreserved set, but I was intending to use the RFC 2396 set. The reason to use the older RFC 2396 set is that |
Removes ! * ' ( ) from the encode set.
31b0de8
to
55f95c8
Compare
If you actually want the URL parser to change to use this I think it would make more sense to a depth-first approach since that may or may not be successful. If you want to do this regardless of whether that can change I suppose this makes sense... |
@annevk I think you are saying that if I don't want a special exception here forever, I should make the change in URL Standard first, before doing it here. That's fair, but since this is a draft (which will go through many rounds of review), I think it's fine to have it here now. The possible directions we go on after this are:
All three of those can happen, so I'll just land this for now. |
This fixes the set of characters that are encoded when substituting into a placeholder, to include all the "reserved" and illegal characters from RFC 2396 (matching the behaviour of encodeURIComponent).
There is no appropriate set to use in the URL Standard. whatwg/url#369 discusses adding this (also needed for properly specifying registerProtocolHandler), but for now, I'm just putting it in the Web Share Target spec.
Closes #9.
Preview | Diff