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

src,lib: prefer internal/options over process._foo #25063

Closed
wants to merge 1 commit into from

Conversation

addaleax
Copy link
Member

This addresses a couple TODO comments and allows us
to remove a number of underscored properties from process
(in a semver-major follow-up).

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

@nodejs-github-bot nodejs-github-bot added the c++ Issues and PRs that require attention from people who are familiar with C++. label Dec 15, 2018
@addaleax addaleax added the process Issues and PRs related to the process subsystem. label Dec 15, 2018
@@ -104,7 +105,7 @@ function startup() {
NativeModule.require('internal/inspector_async_hook').setup();
}

const { getOptionValue } = NativeModule.require('internal/options');
getOptionValue = NativeModule.require('internal/options').getOptionValue;
Copy link
Contributor

Choose a reason for hiding this comment

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

We could keep the same extraction method as before with:

({ getOptionValue } = NativeModule.require('internal/options'));

Copy link
Member Author

Choose a reason for hiding this comment

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

@mscdex I thought about it but thought this was maybe easier to read without the parenthesis? If you’d prefer this, I’d be totally okay with that too?

Copy link
Contributor

Choose a reason for hiding this comment

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

I don't mind either way, was just throwing that out there.

This addresses a couple `TODO` comments and allows us
to remove a number of underscored properties from `process`
(in a semver-major follow-up).
Copy link
Member

@joyeecheung joyeecheung left a comment

Choose a reason for hiding this comment

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

LGTM. Thanks for picking this up! I tried to take a stab at this a while back but it was more tricky than I thought to eliminate some of these from JS land (tests were failing/hanging for legit reasons which I was not able to figure out), but it's good to get rid of them incrementally 👍 And looking forward to the followup!

@danbev
Copy link
Contributor

danbev commented Dec 19, 2018

@danbev
Copy link
Contributor

danbev commented Dec 21, 2018

Re-run of failing node-test-commit-aix ✔️
Re-run of failing node-test-commit-smartos ✔️

@danbev
Copy link
Contributor

danbev commented Dec 21, 2018

Landed in 8b57208.

@danbev danbev closed this Dec 21, 2018
danbev pushed a commit that referenced this pull request Dec 21, 2018
This addresses a couple `TODO` comments and allows us
to remove a number of underscored properties from `process`
(in a semver-major follow-up).

PR-URL: #25063
Reviewed-By: Joyee Cheung <[email protected]>
Reviewed-By: Colin Ihrig <[email protected]>
Reviewed-By: James M Snell <[email protected]>
@MylesBorins
Copy link
Contributor

This doesn't land cleanly on v11.x, should it be backported?

@addaleax addaleax deleted the less-process-dot-something branch January 9, 2019 00:24
addaleax added a commit that referenced this pull request Jan 14, 2019
This addresses a couple `TODO` comments and allows us
to remove a number of underscored properties from `process`
(in a semver-major follow-up).

PR-URL: #25063
Reviewed-By: Joyee Cheung <[email protected]>
Reviewed-By: Colin Ihrig <[email protected]>
Reviewed-By: James M Snell <[email protected]>
@addaleax
Copy link
Member Author

Applies cleanly now.

refack pushed a commit to refack/node that referenced this pull request Jan 14, 2019
This addresses a couple `TODO` comments and allows us
to remove a number of underscored properties from `process`
(in a semver-major follow-up).

PR-URL: nodejs#25063
Reviewed-By: Joyee Cheung <[email protected]>
Reviewed-By: Colin Ihrig <[email protected]>
Reviewed-By: James M Snell <[email protected]>
@BridgeAR BridgeAR mentioned this pull request Jan 16, 2019
BridgeAR pushed a commit to BridgeAR/node that referenced this pull request Jan 16, 2019
This addresses a couple `TODO` comments and allows us
to remove a number of underscored properties from `process`
(in a semver-major follow-up).

PR-URL: nodejs#25063
Reviewed-By: Joyee Cheung <[email protected]>
Reviewed-By: Colin Ihrig <[email protected]>
Reviewed-By: James M Snell <[email protected]>
@MylesBorins MylesBorins mentioned this pull request Jan 24, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
c++ Issues and PRs that require attention from people who are familiar with C++. process Issues and PRs related to the process subsystem.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

10 participants