Intent to Deprecate and Remove: HashChangeEvent.initHashChangeEvent

41 views
Skip to first unread message

Dave Tapuska

unread,
Sep 14, 2015, 1:12:43 PM9/14/15
to blink-dev
Primary eng email:

Compatibility Risk:
Low

Summary:
Deprecate initHashChangeEvent in M47 and removal in M48.
It has been removed from the html5 specification in 2011.

Alternative implementation suggestion for web developers:
Use HashChangeEvent constructor instead with the HashChangeEventInit dictionary.

Usage Information

Entries on the feature dashboard:
Zero usage of the feature; N/A.

OWP launch tracking bug:

Requesting approval to remove too?
M45 activated measurement on this method; the metrics are showing that it has 0 usage (exact same usage we saw via dev and beta channels). I recommend deprecating for M47 with removal in M48.

Peter Beverloo

unread,
Sep 14, 2015, 1:15:45 PM9/14/15
to Dave Tapuska, blink-dev
Given that there is no measured usage, why separate the deprecation and removal phases at all? Who would benefit from a deprecation warning?

Thanks,
Peter

Dave Tapuska

unread,
Sep 14, 2015, 1:17:34 PM9/14/15
to Peter Beverloo, blink-dev
I'm fine with direct removal if that is supported by the owners.

Rick Byers

unread,
Sep 14, 2015, 1:30:13 PM9/14/15
to Dave Tapuska, Peter Beverloo, blink-dev
LGTM to remove immediately (assuming we don't have any reason to doubt the metrics).

I did a quick httparchive search (although the data is a year old now), and found exactly 4 sites in the top 300,000 that mention initHashChange.  Dave, can you take a quick look at these and confirm whether they would actually be broken at all by our immediate removal?

Dave Tapuska

unread,
Sep 14, 2015, 1:48:53 PM9/14/15
to Rick Byers, Peter Beverloo, blink-dev
4 is a redirect to 1.

1 & 2 don't use it because window.history.pushState is defined.

3; this looks "initHashChangeEvent" is a keyword in a some type of regex for obfuscation. Loading the page doesn't end up calling initHashChangeEvent; but I can't see what the call path could be with the obfuscated js.

dave.

Rick Byers

unread,
Sep 14, 2015, 1:53:19 PM9/14/15
to Dave Tapuska, Peter Beverloo, blink-dev
On Mon, Sep 14, 2015 at 1:48 PM, Dave Tapuska <dtap...@google.com> wrote:
4 is a redirect to 1.

1 & 2 don't use it because window.history.pushState is defined.

3; this looks "initHashChangeEvent" is a keyword in a some type of regex for obfuscation. Loading the page doesn't end up calling initHashChangeEvent; but I can't see what the call path could be with the obfuscated js.

Perfect, thanks for the analysis - I figured it would be this easy.  So yes, I think we should just go straight to removal.

Philip Jägenstedt

unread,
Sep 15, 2015, 7:46:50 AM9/15/15
to Rick Byers, Dave Tapuska, Peter Beverloo, blink-dev
LGTM2, removal without deprecation seems safe given the usage.

To unsubscribe from this group and stop receiving emails from it, send an email to blink-dev+...@chromium.org.

Chris Harrelson

unread,
Sep 15, 2015, 11:58:44 AM9/15/15
to Philip Jägenstedt, Rick Byers, Dave Tapuska, Peter Beverloo, blink-dev
LGTM3, to remove immediately.

ccal...@google.com

unread,
Dec 15, 2015, 2:16:26 PM12/15/15
to blink-dev, phi...@opera.com, rby...@chromium.org, dtap...@google.com, pe...@chromium.org, chri...@chromium.org, Matan Lurey, Deepjoy Majumdar
fyi, this broke greentea-nightly (don't worry, not a prod instance), which relies upon angular2, which somehow relies upon this thing.
stack trace looks like this:
HashChangeEvent.dart.HashChangeEvent._initHashChangeEvent$5
J._initHashChangeEvent$5$x
DispatchingHashLocationStrategy.dart.DispatchingHashLocationStrategy.pushState$4
RootRouter_commit_closure.dart.RootRouter_commit_closure.call$1
StackZoneSpecification_registerUnaryCallback__closure.dart.StackZoneSpecification_registerUnaryCallback__closure.call$0
StackZoneSpecification.dart.StackZoneSpecification._stack_zone_specification$_run$2
StackZoneSpecification_registerUnaryCallback_closure.dart.StackZoneSpecification_registerUnaryCallback_closure.call$1
NgZone__runUnary_closure.dart.NgZone__runUnary_closure.call$0
dart._rootRun
_ZoneDelegate.dart._ZoneDelegate.run$2

we'll work around it.

Dave Tapuska

unread,
Dec 15, 2015, 2:23:18 PM12/15/15
to ccal...@google.com, blink-dev, Philip Jägenstedt, Rick Byers, Peter Beverloo, Chris Harrelson, Matan Lurey, Deepjoy Majumdar
Reply all
Reply to author
Forward
0 new messages