FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

vm: do not overwrite error when creating context by addaleax · Pull Request #26112 · nodejs/node · GitHub

/ node Public

vm: do not overwrite error when creating context - #26112

Closed
addaleax wants to merge 2 commits into
nodejs:masterfrom
addaleax:vm-context-terminate
Closed

vm: do not overwrite error when creating context#26112
addaleax wants to merge 2 commits into
nodejs:masterfrom
addaleax:vm-context-terminate

Conversation

Copy link
Copy Markdown
Member

An empty Local<> already indicates that an exception is pending,
so there is no need to throw an exception. In the case of Workers,
this could override a .terminate() call.

Checklist
  • make -j4 test (UNIX), or vcbuild test (Windows) passes
  • tests and/or benchmarks are included
  • commit message follows commit guidelines

An empty `Local<>` already indicates that an exception is pending,
so there is no need to throw an exception. In the case of Workers,
this could override a `.terminate()` call.

Copy link
Copy Markdown
Collaborator

nodejs-github-bot added c++ Issues and PRs that require attention from people who are familiar with C++. vm Issues and PRs related to the vm subsystem. labels Feb 14, 2019
if (!process.env.HAS_STARTED_WORKER) {
process.env.HAS_STARTED_WORKER = 1;
const w = new Worker(__filename);
setTimeout(() => w.terminate(), 50);

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

Is using the 'online' event here instead an option?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

@cjihrig I’ve added that but kept the timeout, it still seems to make this fail more reliably locally (with the node master executable).

addaleax commented Feb 15, 2019
edited
Loading

Copy link
Copy Markdown
Member Author

CI: https://ci.nodejs.org/job/node-test-pull-request/20787/ (:white_check_mark:)

addaleax added the author ready PRs that have at least one approval, no outstanding review comments, and a CI started. label Feb 15, 2019

Copy link
Copy Markdown
Member Author

Landed in 0896fbe

addaleax closed this Feb 17, 2019
addaleax deleted the vm-context-terminate branch February 17, 2019 16:50
addaleax added a commit that referenced this pull request Feb 17, 2019
An empty `Local<>` already indicates that an exception is pending,
so there is no need to throw an exception. In the case of Workers,
this could override a `.terminate()` call.

PR-URL: #26112
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Gus Caplan <me@gus.host>
Reviewed-By: James M Snell <jasnell@gmail.com>
addaleax added a commit that referenced this pull request Feb 17, 2019
An empty `Local<>` already indicates that an exception is pending,
so there is no need to throw an exception. In the case of Workers,
this could override a `.terminate()` call.

PR-URL: #26112
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Gus Caplan <me@gus.host>
Reviewed-By: James M Snell <jasnell@gmail.com>
BridgeAR mentioned this pull request Feb 26, 2019
rvagg pushed a commit that referenced this pull request Feb 28, 2019
An empty `Local<>` already indicates that an exception is pending,
so there is no need to throw an exception. In the case of Workers,
this could override a `.terminate()` call.

PR-URL: #26112
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Gus Caplan <me@gus.host>
Reviewed-By: James M Snell <jasnell@gmail.com>
This file contains hidden or 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
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

author ready PRs that have at least one approval, no outstanding review comments, and a CI started. c++ Issues and PRs that require attention from people who are familiar with C++. vm Issues and PRs related to the vm subsystem.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants


Back | FazBrowse Home | New Git URL