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

```js
e.waitUntil(p) // p.then (i.e., upon settlement step in the spec)
p.then(_ => e.waitUntil(q));
p.then(_ => e.waitUntil(r));
```
Should the `waitUntil(r)` throw here? This is the same microtask order as in your example. Where should the microtask for the "upon settlement of p step in the waitUntil method" queued? Between q and r? If it's queued before q, event q will throw. If it's queued between q and r, I think the behavior looks odd. (Will devs expect this?)

I think we should either use a normal task as spec'd or consider the design in https://github.com/w3c/ServiceWorker/pull/1049#issuecomment-271761346.

-- 
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-272050685

Received on Thursday, 12 January 2017 01:36:05 UTC