-
Notifications
You must be signed in to change notification settings - Fork 29.7k
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
Rename internalModuleReadFile to internalModuleReadJSON. #17084
Conversation
strictEqual(internalModuleReadFile(fixtures.path('empty-with-bom.txt')), ''); | ||
strictEqual(internalModuleReadJSON('nosuchfile'), undefined); | ||
strictEqual(internalModuleReadJSON(fixtures.path('empty.txt')), ''); | ||
strictEqual(internalModuleReadJSON(fixtures.path('empty-with-bom.txt')), ''); | ||
{ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👆 These tests highlight the mixed signals being sent:
They test .txt
, but the method is being shaped via #15767 to be json
-only.
Out of caution, labeling this |
@Trott does the test fail look real? |
Not to me, but just in case, here's a rerun of that subset of hosts types: https://ci.nodejs.org/job/node-test-commit-linux-linked/137/ |
What's the next steps for this PR? |
CI is good. Because it's a breaking change, this will need two approvals from TSC folks. @nodejs/tsc |
Oh, it will also need a CITGM run. https://ci.nodejs.org/view/Node.js-citgm/job/citgm-smoker/1097/ (CITGM will no doubt report failures because it always does. Someone will need to go through the results carefully to see if the failures are related or not.) |
Although persuadable, I currently am neutral on this change. I like making the name more accurate, but I don't know that the value of the change outweighs the potential breakage to the ecosystem. Then again, we certainly discourage |
For the CITGM run it may be helpful to run it against the changeset introduced in #15767 too.
Testing for the existence of something is easier than testing for the subtle breakage of something. In this case, the changeset of #15767 subtly broke |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM if CI and CITGM are clean
I'll look at the CitGM report in the morning. |
CitGM is clean (nothing new), except |
So, technically, this can land. (Semver major requires two TSC approvals, clean CITGM, clean CI, open for more than 72 hours. We have all those boxes checked.) @nodejs/tsc and anyone else interested: If you object to this, say something! I'm personally inclined to leave this open through the U.S. holiday weekend and then land it early next week, but if someone wants to land it sooner than that, I won't complain. |
Ping! |
PR-URL: nodejs#17084 Fixes: nodejs#17076 Reviewed-By: Rich Trott <[email protected]> Reviewed-By: Refael Ackermann <[email protected]> Reviewed-By: James M Snell <[email protected]>
Landed in fea1e05. |
This PR addresses #17076 by simply renaming
internalModuleReadFile
tointernalModuleReadJSON
.I'm actually cool with keeping
internalModuleReadFile
just for the potential to use it for other things besidesjson
, but this was the easy way to address the root of #17076 without digging intoc++
.