New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

src: pass along errors from object instantiations #25734

Closed
wants to merge 7 commits into
base: master
from

Conversation

Projects
5 participants
@addaleax
Copy link
Member

addaleax commented Jan 27, 2019

Calling Function::NewInstance() can always fail in the presence of termination exceptions, so we need to check for error conditions when calling it.

This PR does not address all of those cases, but at least some of them.

Checklist
  • make -j4 test (UNIX), or vcbuild test (Windows) passes
  • commit message follows commit guidelines

addaleax added some commits Jan 27, 2019

@addaleax

This comment has been minimized.

Copy link
Member Author

addaleax commented Jan 28, 2019

@addaleax

This comment has been minimized.

Copy link
Member Author

addaleax commented Jan 29, 2019

@addaleax

This comment has been minimized.

Copy link
Member Author

addaleax commented Jan 29, 2019

Landed in 1a37fd6...8e6667f

@addaleax addaleax closed this Jan 29, 2019

@addaleax addaleax deleted the addaleax:new-instance-1 branch Jan 29, 2019

addaleax added a commit that referenced this pull request Jan 29, 2019

src: pass along errors from PromiseWrap instantiation
PR-URL: #25734
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Gus Caplan <me@gus.host>

addaleax added a commit that referenced this pull request Jan 29, 2019

src: pass along errors from stream obj instantiation
PR-URL: #25734
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Gus Caplan <me@gus.host>

addaleax added a commit that referenced this pull request Jan 29, 2019

src: pass along errors from process obj instantiation
PR-URL: #25734
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Gus Caplan <me@gus.host>

addaleax added a commit that referenced this pull request Jan 29, 2019

src: pass along errors from perf obj instantiation
PR-URL: #25734
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Gus Caplan <me@gus.host>

addaleax added a commit that referenced this pull request Jan 29, 2019

src: pass along errors from KeyObject instantiation
PR-URL: #25734
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Gus Caplan <me@gus.host>

addaleax added a commit that referenced this pull request Jan 29, 2019

src: pass along errors from vm data wrapper creation
PR-URL: #25734
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Gus Caplan <me@gus.host>

addaleax added a commit that referenced this pull request Jan 29, 2019

src: pass along errors from i18n converter instantiation
PR-URL: #25734
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Gus Caplan <me@gus.host>

targos added a commit that referenced this pull request Jan 29, 2019

src: pass along errors from stream obj instantiation
PR-URL: #25734
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Gus Caplan <me@gus.host>

targos added a commit that referenced this pull request Jan 29, 2019

src: pass along errors from process obj instantiation
PR-URL: #25734
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Gus Caplan <me@gus.host>

targos added a commit that referenced this pull request Jan 29, 2019

src: pass along errors from perf obj instantiation
PR-URL: #25734
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Gus Caplan <me@gus.host>

targos added a commit that referenced this pull request Jan 29, 2019

src: pass along errors from KeyObject instantiation
PR-URL: #25734
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Gus Caplan <me@gus.host>

targos added a commit that referenced this pull request Jan 29, 2019

src: pass along errors from vm data wrapper creation
PR-URL: #25734
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Gus Caplan <me@gus.host>

targos added a commit that referenced this pull request Jan 29, 2019

src: pass along errors from i18n converter instantiation
PR-URL: #25734
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Gus Caplan <me@gus.host>

@targos targos referenced this pull request Jan 29, 2019

Merged

v11.9.0 proposal #25802

MaybeLocal<Object> Environment::CreateProcessObject(
const std::vector<std::string>& args,
const std::vector<std::string>& exec_args) {
if (*TRACE_EVENT_API_GET_CATEGORY_GROUP_ENABLED(

This comment has been minimized.

@joyeecheung

joyeecheung Jan 29, 2019

Member

Why is this part inside CreateProcessObject? (Or rather why is this method named CreateProcessObject?)

This comment has been minimized.

@addaleax

addaleax Jan 30, 2019

Author Member

@joyeecheung Because it’s the part that handles args and exec_args, that’s pretty much all the reason … also, I called it that because that’s what it mainly does, create + set up the process object?

addaleax added a commit to addaleax/node that referenced this pull request Jan 30, 2019

src: pass along errors from PromiseWrap instantiation
PR-URL: nodejs#25734
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Gus Caplan <me@gus.host>

addaleax added a commit that referenced this pull request Feb 3, 2019

src: pass along errors from PromiseWrap instantiation
PR-URL: #25734
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Gus Caplan <me@gus.host>

PR-URL: #25837
Reviewed-By: Michaël Zasso <targos@protonmail.com>

@targos targos added this to Backported in v11.x Feb 10, 2019

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment