Description was changed from ========== Add readonly URLUtils.searchParams property. R= BUG= ========== to ========== Add ...
4 years, 8 months ago
(2016-04-05 11:39:56 UTC)
#1
Description was changed from
==========
Add readonly URLUtils.searchParams property.
R=
BUG=
==========
to
==========
Add support for URL.searchParams getter.
Add the missing piece to our URLSearchParams implementation;
the readonly attribute for URL.
The currently spec'ed connection between URL and URLSearchParams is
a lot less general than previous designs, hence the object lifetime
complexities it ran into (see https://codereview.chromium.org/143313002/),
falls away.
R=
BUG=303152
==========
please take a look. Specs have become considerably less general wrt URLSearchParams integration since last ...
4 years, 8 months ago
(2016-04-05 11:52:54 UTC)
#3
please take a look.
Specs have become considerably less general wrt URLSearchParams integration
since last looking (a long while ago), so procrastination & unforeseen delays
sometimes work out for the better&simpler.
Mike West
Hooray for procrastination! Thank you for taking this on.. LGTM. Do you plan on updating ...
4 years, 8 months ago
(2016-04-05 12:43:51 UTC)
#4
Still LGTM, thanks! On 2016/04/05 at 15:23:18, sigbjornf wrote: > > Do you plan on ...
4 years, 8 months ago
(2016-04-05 16:11:00 UTC)
#6
Still LGTM, thanks!
On 2016/04/05 at 15:23:18, sigbjornf wrote:
> > Do you plan on updating the WPT version of these tests as well?
>
> Maybe..where/what? :)
You can just copy/paste them in here:
https://github.com/w3c/web-platform-tests/tree/master/url.
>
https://codereview.chromium.org/1860623002/diff/60001/third_party/WebKit/Layo...
> third_party/WebKit/LayoutTests/fast/domurl/url-searchparams.html:31: 'use
strict';
> On 2016/04/05 12:43:51, Mike West (OOO through 31st) wrote:
> > Why do we need strict mode for this test?
>
> Assignment to readonly attributes will be ignored and not throw in non-strict
mode; see Note at the end of the http://heycam.github.io/webidl/#es- attributes
section.
Huh. I didn't know that. Ok!
sof
On 2016/04/05 16:11:00, Mike West (OOO through 31st) wrote: > Still LGTM, thanks! > thanks; ...
4 years, 8 months ago
(2016-04-05 18:32:21 UTC)
#7
On 2016/04/05 16:11:00, Mike West (OOO through 31st) wrote:
> Still LGTM, thanks!
>
thanks; asking for blink-dev permission to ship before taking the next step.
> On 2016/04/05 at 15:23:18, sigbjornf wrote:
> > > Do you plan on updating the WPT version of these tests as well?
> >
> > Maybe..where/what? :)
>
> You can just copy/paste them in here:
> https://github.com/w3c/web-platform-tests/tree/master/url.
>
Great, will do that tomorrow.
> >
>
https://codereview.chromium.org/1860623002/diff/60001/third_party/WebKit/Layo...
> > third_party/WebKit/LayoutTests/fast/domurl/url-searchparams.html:31: 'use
> strict';
> > On 2016/04/05 12:43:51, Mike West (OOO through 31st) wrote:
> > > Why do we need strict mode for this test?
> >
> > Assignment to readonly attributes will be ignored and not throw in
non-strict
> mode; see Note at the end of the http://heycam.github.io/webidl/#es-
attributes
> section.
>
> Huh. I didn't know that. Ok!
Over the top to have four tests exercising the throwing of the same exception
though, but one day .searchParams might just become writable again..
sof
Description was changed from ========== Add support for URL.searchParams getter. Add the missing piece to ...
4 years, 8 months ago
(2016-04-05 18:36:36 UTC)
#8
Description was changed from
==========
Add support for URL.searchParams getter.
Add the missing piece to our URLSearchParams implementation;
the readonly attribute for URL.
The currently spec'ed connection between URL and URLSearchParams is
a lot less general than previous designs, hence the object lifetime
complexities it ran into (see https://codereview.chromium.org/143313002/),
falls away.
R=
BUG=303152
==========
to
==========
Add support for URL.searchParams getter.
Add the missing piece to our URLSearchParams implementation;
the readonly attribute for URL, URL.searchParams:
https://url.spec.whatwg.org/#dom-url-searchparams
The currently spec'ed connection between URL and URLSearchParams is
a lot less general than previous designs, hence the object lifetime
complexities it ran into (see https://codereview.chromium.org/143313002/)
falls away.
Intent to Implement and Ship (for URLSearchParams and this URL attribute):
https://groups.google.com/a/chromium.org/d/msg/blink-dev/grHZDbldP04/JdsoQ169...
R=mkwst
BUG=303152
==========
How does this deal with cycles? The URLSearchParams has a strong ref to the URL, ...
4 years, 8 months ago
(2016-04-05 21:06:19 UTC)
#10
How does this deal with cycles? The URLSearchParams has a strong ref to the URL,
if you then make a cycle in JS on the wrappers from the URL -> URLSearchParams
then the URL is keeping the search params alive in JS, and the search params is
keeping the url alive in C++. So neither side will ever collect the objects I
think.
sof
On 2016/04/05 21:06:19, esprehn wrote: > How does this deal with cycles? The URLSearchParams has ...
4 years, 8 months ago
(2016-04-05 21:40:08 UTC)
#11
On 2016/04/05 21:06:19, esprehn wrote:
> How does this deal with cycles? The URLSearchParams has a strong ref to the
URL,
> if you then make a cycle in JS on the wrappers from the URL -> URLSearchParams
> then the URL is keeping the search params alive in JS, and the search params
is
> keeping the url alive in C++. So neither side will ever collect the objects I
> think.
It's a good question; I'll investigate if that back reference from
URLSearchParams could somehow keep the wrapper to URL alive indefinitely.
sof
On 2016/04/05 21:40:08, sof wrote: > On 2016/04/05 21:06:19, esprehn wrote: > > How does ...
4 years, 8 months ago
(2016-04-06 10:34:16 UTC)
#12
On 2016/04/05 21:40:08, sof wrote:
> On 2016/04/05 21:06:19, esprehn wrote:
> > How does this deal with cycles? The URLSearchParams has a strong ref to the
> URL,
> > if you then make a cycle in JS on the wrappers from the URL ->
URLSearchParams
> > then the URL is keeping the search params alive in JS, and the search params
> is
> > keeping the url alive in C++. So neither side will ever collect the objects
I
> > think.
>
> It's a good question; I'll investigate if that back reference from
> URLSearchParams could somehow keep the wrapper to URL alive indefinitely.
If you really conjure up a mutual dependency on the v8 side with
var url = new URL(..);
var us = url.searchParams;
url.us = us;
us.url = url;
the underlying "host objects" (DOMURL and URLSearchParams) will be retained if
|url| or |us| are referred to. Reasonable behavior.
If you sever the dependencies and drop the v8 reference to |url|, then
URLSearchParams is retained along with DOMURL. If you proceed to drop the
reference to |us|, then both URLSearchParams and DOMURL will be GCed.
So, the question is if holding onto the |us| wrapper should also keep
URLSearchParam's associated DOMURL object alive. Not the heaviest of objects,
but as there's no benefit in updating an otherwise unobservable object, I
suggest we don't.
Adjusted URLSearchParams::m_urlObject to be weak; thanks for bringing up the
issue.
sof
On 2016/04/05 18:32:21, sof wrote: > On 2016/04/05 16:11:00, Mike West (OOO through 31st) wrote: ...
4 years, 8 months ago
(2016-04-06 12:54:41 UTC)
#13
On 2016/04/05 18:32:21, sof wrote:
> On 2016/04/05 16:11:00, Mike West (OOO through 31st) wrote:
> > Still LGTM, thanks!
> >
>
> thanks; asking for blink-dev permission to ship before taking the next step.
>
>
> > On 2016/04/05 at 15:23:18, sigbjornf wrote:
> > > > Do you plan on updating the WPT version of these tests as well?
> > >
> > > Maybe..where/what? :)
> >
> > You can just copy/paste them in here:
> > https://github.com/w3c/web-platform-tests/tree/master/url.
> >
>
> Great, will do that tomorrow.
>
https://github.com/w3c/web-platform-tests/pull/2756
sof
Going ahead and landing this one now, added feature dashboard entry + OWP tracking bug ...
4 years, 8 months ago
(2016-04-08 11:44:04 UTC)
#14
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1860623002/140001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1860623002/140001
4 years, 8 months ago
(2016-04-08 11:44:23 UTC)
#17
Try jobs failed on following builders: ios_dbg_simulator_ninja on tryserver.chromium.mac (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.mac/builders/ios_dbg_simulator_ninja/builds/156618) ios_rel_device_gn on tryserver.chromium.mac (JOB_FAILED, ...
4 years, 8 months ago
(2016-04-08 11:46:46 UTC)
#19
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1860623002/160001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1860623002/160001
4 years, 8 months ago
(2016-04-08 13:33:50 UTC)
#22
Try jobs failed on following builders: chromium_presubmit on tryserver.chromium.linux (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.linux/builders/chromium_presubmit/builds/166326)
4 years, 8 months ago
(2016-04-08 13:43:34 UTC)
#24
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1860623002/160001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1860623002/160001
4 years, 8 months ago
(2016-04-08 20:21:26 UTC)
#29
Issue 1860623002: Add support for URL.searchParams getter.
(Closed)
Created 4 years, 8 months ago by sof
Modified 4 years, 8 months ago
Reviewers: Mike West, esprehn, tkent, philipj_slow
Base URL: https://chromium.googlesource.com/chromium/src.git@master
Comments: 10