-
Notifications
You must be signed in to change notification settings - Fork 9.1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: async stacks for all "async" public methods (#3262)
This patch traces all public async methods and wraps them in a helper method that tags the sync stack trace. Later on, if the method call throws an exception, we add a captured stack trace to the original stack trace with the "--ASYNC--" heading. An example of a stack trace: ``` Error: net::ERR_ABORTED at http://localhost:8907/empty.html at navigate (/Users/lushnikov/prog/puppeteer/lib/Page.js:622:37) at process._tickCallback (internal/process/next_tick.js:68:7) -- ASYNC -- at Page.<anonymous> (/Users/lushnikov/prog/puppeteer/lib/helper.js:147:27) at fit (/Users/lushnikov/prog/puppeteer/test/page.spec.js:546:18) at process._tickCallback (internal/process/next_tick.js:68:7) ```
- Loading branch information
1 parent
9223bca
commit 0b9d8a6
Showing
2 changed files
with
62 additions
and
19 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters