Re: [w3c/ServiceWorker] async waitUntil() does not allow extension on final promise resolution? (#1039)

> My impression is that the OP wants to wait until q and r

I believe you meant p and r here. I think this design is reasonable.

> However, the implementation in #1049 is doing something completely different: it's waiting on p and q. Waiting on q is not very reasonable, because q is never passed to waitUntil, and can only be discovered by crawling the promise graph.


Right. I added q to the pending list, and that's why I ended up poking the internal slots. I thought we should guarantee all the then callbacks in the given promise's promise chain. E.g.

```js
e.waitUntil(p);

p.then(doSomething).then(() => { e.waitUntil(r); });
```

Now the more I think about it, the more convinced that I have misunderstood the original issue.

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/w3c/ServiceWorker/issues/1039#issuecomment-270849872

Received on Friday, 6 January 2017 07:46:44 UTC