New issue
Advanced search Search tips

Issue 714930 link

Starred by 1 user

Issue metadata

Status: WontFix
Owner: ----
Closed: Apr 2017
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: All
Pri: 3
Type: Bug



Sign in to add a comment

clients.get(invalidId) neither resolves or rejects

Project Member Reported by esprehn@chromium.org, Apr 25 2017

Issue description

Google Chrome	60.0.3078.0 (Official Build) canary (64-bit)
Revision	aae568aa4c9c49d7b851c448e6bb3f6809b2b7de-refs/heads/master@{#466494}
OS	Mac OS X

What steps will reproduce the problem?
(1) Load a SW
(2) Open the devtools console
(3) clients.get({}).then((e) => { console.log(e); }).catch((e) => { console.log(e); })

What is the expected result?

The promise should either resolve or reject.

What happens instead?

Nothing, the promise is left in the pending state forever.
 
Cc: jakearchibald@chromium.org
Summary: clients.get(invalidId) neither resolves or rejects (was: clients.get({}) neither resolves or rejects)
In general it seems that an invalid clientId returns a Promise that never resolves or rejects which can result in your app becoming "stuck". :(
Status: WontFix (was: Untriaged)
Oh this is just my confusion for not understanding the API, the Promise resolves with "undefined" as the value which was confusing in the devtools. Very curious that this doesn't resolve with null like getElementById would return if you passed an unknown id.

Sign in to add a comment