Skip to content
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

lib: absorb path error cases #34519

Closed

Conversation

gireeshpunathil
Copy link
Member

Catch low level libuv failure and
rethrow with a more meaningful message

Adjust the test to cover a possible failure scenario

Fixes: #33759
Refs: #33759 (comment)

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

lib/internal/bootstrap/pre_execution.js Outdated Show resolved Hide resolved
@gireeshpunathil gireeshpunathil force-pushed the try-guard-process-argv branch from f9d01ed to 79857e1 Compare July 26, 2020 15:25
@gireeshpunathil gireeshpunathil changed the title lib, test: harden path error cases lib: absorb path error cases Jul 26, 2020
@nodejs-github-bot
Copy link
Collaborator

Copy link
Member

@BridgeAR BridgeAR left a comment

Choose a reason for hiding this comment

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

Would it be possible to add a test case for this?

@gireeshpunathil
Copy link
Member Author

I have thought about it, but looks like it is difficult:

  • the path resolution of the executable cannot be mimic'd to fail in a JS test
  • the resource constraints cannot be confined exactly to this API. If at all, the referenced test case's assertion is going to cover that.

let me know if you have any any suggestions!

gireeshpunathil added a commit that referenced this pull request Jul 30, 2020
Absorb low level libuv failure in
the process initialization phase

Fixes: #33759
Refs: #33759 (comment)
PR-URL: #34519
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Zeyu Yang <himself65@outlook.com>
Reviewed-By: Harshitha K P <harshitha014@gmail.com>
@gireeshpunathil gireeshpunathil force-pushed the try-guard-process-argv branch from 79857e1 to 4692e28 Compare July 30, 2020 08:18
@gireeshpunathil
Copy link
Member Author

landed in 4692e28

codebytere pushed a commit that referenced this pull request Aug 5, 2020
Absorb low level libuv failure in
the process initialization phase

Fixes: #33759
Refs: #33759 (comment)
PR-URL: #34519
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Zeyu Yang <himself65@outlook.com>
Reviewed-By: Harshitha K P <harshitha014@gmail.com>
@codebytere codebytere mentioned this pull request Aug 10, 2020
codebytere added a commit to electron/electron that referenced this pull request Sep 1, 2020
codebytere added a commit to electron/electron that referenced this pull request Sep 2, 2020
codebytere added a commit to electron/electron that referenced this pull request Sep 4, 2020
codebytere added a commit to electron/electron that referenced this pull request Sep 14, 2020
codebytere added a commit to electron/electron that referenced this pull request Sep 14, 2020
codebytere added a commit to electron/electron that referenced this pull request Sep 14, 2020
codebytere added a commit to electron/electron that referenced this pull request Sep 16, 2020
addaleax pushed a commit that referenced this pull request Sep 22, 2020
Absorb low level libuv failure in
the process initialization phase

Fixes: #33759
Refs: #33759 (comment)
PR-URL: #34519
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Zeyu Yang <himself65@outlook.com>
Reviewed-By: Harshitha K P <harshitha014@gmail.com>
addaleax pushed a commit that referenced this pull request Sep 22, 2020
Absorb low level libuv failure in
the process initialization phase

Fixes: #33759
Refs: #33759 (comment)
PR-URL: #34519
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Zeyu Yang <himself65@outlook.com>
Reviewed-By: Harshitha K P <harshitha014@gmail.com>
@codebytere codebytere mentioned this pull request Sep 28, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Investigate flaky test-worker-init-failure
9 participants