Promises: final steps
kris.kowal at cixar.com
Wed Sep 4 12:15:14 PDT 2013
My colleagues and I are working on an extension for Chrome Web Inspector
that can communicate with promise libraries, particularly Q, over the
window message port. The tool, which will be renamed and rewritten before
it is ready for general use, adds a Promises tab to Web Inspector that
shows all currently pending and unhandled asynchronous errors, as well as
stack traces for both, and also progress information, albeit determinate,
indeterminate, or indeterminate but lively. There is a video accompanying
The promise client broadcasts when a promise is deferred, when a deferred
promise is resolved, when a deferred promise makes progress (through the
`deferred.notify` interface), when a fulfilled promise is created, when a
rejected promise is created, and when a rejection is handled. As such, the
inspector can reconstruct whatever portion of the program’s promise history
it elects to retain.
In time, I intend to formalize a protocol. Ideally this system would be
useful for both “primordial” and library promises, and combinations of
both. Of course, any assistance would be valuable.
Also, ideally this would approach the functionality available to Causeway
and perhaps even *become* a manifestation of Causeway.
It would certainly be possible to show promises in multiple contexts,
including cross-origin iframes, and even show time sequence / Stevens
contexts, when promises are used as proxies for remote objects through a
facility like Q-Connection
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the es-discuss