{"action":"created","issue":{"url":"https://api.github.com/repos/nodejs/node/issues/21857","repository_url":"https://api.github.com/repos/nodejs/node","labels_url":"https://api.github.com/repos/nodejs/node/issues/21857/labels{/name}","comments_url":"https://api.github.com/repos/nodejs/node/issues/21857/comments","events_url":"https://api.github.com/repos/nodejs/node/issues/21857/events","html_url":"https://github.com/nodejs/node/pull/21857","id":342038736,"node_id":"MDExOlB1bGxSZXF1ZXN0MjAyMDMzODU3","number":21857,"title":"async_hooks: add promiseEvent","user":{"login":"devsnek","id":5952481,"node_id":"MDQ6VXNlcjU5NTI0ODE=","avatar_url":"https://avatars3.githubusercontent.com/u/5952481?v=4","gravatar_id":"","url":"https://api.github.com/users/devsnek","html_url":"https://github.com/devsnek","followers_url":"https://api.github.com/users/devsnek/followers","following_url":"https://api.github.com/users/devsnek/following{/other_user}","gists_url":"https://api.github.com/users/devsnek/gists{/gist_id}","starred_url":"https://api.github.com/users/devsnek/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/devsnek/subscriptions","organizations_url":"https://api.github.com/users/devsnek/orgs","repos_url":"https://api.github.com/users/devsnek/repos","events_url":"https://api.github.com/users/devsnek/events{/privacy}","received_events_url":"https://api.github.com/users/devsnek/received_events","type":"User","site_admin":false},"labels":[{"id":442446525,"node_id":"MDU6TGFiZWw0NDI0NDY1MjU=","url":"https://api.github.com/repos/nodejs/node/labels/async_hooks","name":"async_hooks","color":"ededed","default":false},{"id":337637139,"node_id":"MDU6TGFiZWwzMzc2MzcxMzk=","url":"https://api.github.com/repos/nodejs/node/labels/async_wrap","name":"async_wrap","color":"fbca04","default":false},{"id":340436277,"node_id":"MDU6TGFiZWwzNDA0MzYyNzc=","url":"https://api.github.com/repos/nodejs/node/labels/promises","name":"promises","color":"f7c6c7","default":false},{"id":169485514,"node_id":"MDU6TGFiZWwxNjk0ODU1MTQ=","url":"https://api.github.com/repos/nodejs/node/labels/semver-major","name":"semver-major","color":"fbca04","default":false}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":23,"created_at":"2018-07-17T18:44:25Z","updated_at":"2018-07-23T17:42:59Z","closed_at":null,"author_association":"MEMBER","pull_request":{"url":"https://api.github.com/repos/nodejs/node/pulls/21857","html_url":"https://github.com/nodejs/node/pull/21857","diff_url":"https://github.com/nodejs/node/pull/21857.diff","patch_url":"https://github.com/nodejs/node/pull/21857.patch"},"body":"Refs https://github.com/nodejs/promises-debugging/issues/8\r\nCloses https://github.com/nodejs/promises-debugging/issues/8\r\n\r\nexposes a `promiseEvent` callback on async_hooks which handles `resolve`, `rejectWithNoHandler`, etc.\r\n\r\nThis allows node to at some point drop unhandledRejection tracking because there is no good default for it, and to follow the intention of js, where promises don't need to be tracked or be fatal, and lets userland introduce their own tooling to fit their own needs.\r\n\r\n/cc @nodejs/promises-debugging @nodejs/async_hooks @BridgeAR @ljharb\r\n\r\n##### Checklist\r\n<!-- Remove items that do not apply. For completed items, change [ ] to [x]. -->\r\n\r\n- [x] `make -j4 test` (UNIX), or `vcbuild test` (Windows) passes\r\n- [x] tests and/or benchmarks are included\r\n- [x] documentation is changed or added\r\n- [x] commit message follows [commit guidelines](https://github.com/nodejs/node/blob/master/doc/guides/contributing/pull-requests.md#commit-message-guidelines)\r\n"},"comment":{"url":"https://api.github.com/repos/nodejs/node/issues/comments/407141778","html_url":"https://github.com/nodejs/node/pull/21857#issuecomment-407141778","issue_url":"https://api.github.com/repos/nodejs/node/issues/21857","id":407141778,"node_id":"MDEyOklzc3VlQ29tbWVudDQwNzE0MTc3OA==","user":{"login":"benjamingr","id":1315533,"node_id":"MDQ6VXNlcjEzMTU1MzM=","avatar_url":"https://avatars2.githubusercontent.com/u/1315533?v=4","gravatar_id":"","url":"https://api.github.com/users/benjamingr","html_url":"https://github.com/benjamingr","followers_url":"https://api.github.com/users/benjamingr/followers","following_url":"https://api.github.com/users/benjamingr/following{/other_user}","gists_url":"https://api.github.com/users/benjamingr/gists{/gist_id}","starred_url":"https://api.github.com/users/benjamingr/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/benjamingr/subscriptions","organizations_url":"https://api.github.com/users/benjamingr/orgs","repos_url":"https://api.github.com/users/benjamingr/repos","events_url":"https://api.github.com/users/benjamingr/events{/privacy}","received_events_url":"https://api.github.com/users/benjamingr/received_events","type":"User","site_admin":false},"created_at":"2018-07-23T17:42:59Z","updated_at":"2018-07-23T17:42:59Z","author_association":"MEMBER","body":"@AndreasMadsen by all means you are welcome to object to PRs and voice your opinion. None of us feel super strongly about this hook landing in this particular way and the fact you have a formed opinion on it is already indication that you _should_ object if you do not like the proposed API and we _should_ have a discussion about it.\r\n\r\nPersonally, I don't understand way `promiseResolve` is an `async_hook` to begin with if async hooks are only for tracking resources.  If `async_hooks` are not only for managing async resources but also for tracking asynchronous context in asynchronous constructs then both `promiseResolve` and `promiseEvent` makes sense since it allows us to keep the context for these cases.\r\n\r\nMy understanding was the latter but I am not an async_hooks team member and haven't kept up with the discussions in a while and I will gladly learn about it."}}
{"actor":{"display_login":"benjamingr"}}