Join GitHub today
GitHub is home to over 40 million developers working together to host and review code, manage projects, and build software together.
Sign upbuffer: stricter `from()` input validation #26825
Conversation
This comment has been minimized.
This comment has been minimized.
nodejs-github-bot
added
the
buffer
label
Mar 20, 2019
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
BridgeAR
added
the
author ready
label
Mar 24, 2019
This comment has been minimized.
This comment has been minimized.
|
Yeah I guess the function thing is technically semver-major but it is quite certainly an error and trap. |
BridgeAR
requested review from
jasnell,
ChALkeR,
cjihrig and
bnoordhuis
Mar 27, 2019
This comment has been minimized.
This comment has been minimized.
|
@nodejs/buffer PTAL |
ZYSzys
reviewed
Mar 28, 2019
BridgeAR
requested a review
from Trott
Mar 28, 2019
ZYSzys
approved these changes
Mar 29, 2019
targos
approved these changes
Mar 29, 2019
This comment has been minimized.
This comment has been minimized.
|
@targos @mcollina are you fine landing this as semver-patch? CITGM master https://ci.nodejs.org/view/Node.js-citgm/job/citgm-smoker/1782/ |
This comment has been minimized.
This comment has been minimized.
|
I’m fine as patch. |
This comment has been minimized.
This comment has been minimized.
|
Landed in 75eaf25 |
targos
closed this
Mar 30, 2019
targos
added a commit
that referenced
this pull request
Mar 30, 2019
BethGriggs
added a commit
that referenced
this pull request
Apr 5, 2019
BethGriggs
added a commit
that referenced
this pull request
Apr 9, 2019
This was referenced Apr 23, 2019
This was referenced Apr 23, 2019
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
BridgeAR commentedMar 20, 2019
So far we did not throw an error for all types of invalid input.
Functions do not return a buffer anymore and
numberandsymbolvalidation is also improved.
@cjihrig you opened your PR (#26743) to address the function part first. Please feel free to reopen your PR and I'll either rebase on top of your or just close mine if you would like to pull in my changes.
@ChALkeR you also said that you have a PR almost ready, I am happy to close this one.
@nodejs/tsc is this semver-major because of the function validation (if a function is passed in, it seems like a bug, so I am not sure)? The message part is AFAIK not semver-major.
Fixes: #26741
Checklist
make -j4 test(UNIX), orvcbuild test(Windows) passes