Skip to content

chore(types): update @types/node to 14 #4148

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

Merged
merged 10 commits into from
Nov 9, 2022
Merged

chore(types): update @types/node to 14 #4148

merged 10 commits into from
Nov 9, 2022

Conversation

kuhe
Copy link
Contributor

@kuhe kuhe commented Nov 7, 2022

Issue

n/a

Description

A yarn issue is blocking my SSO PR, I think this may fix it.
The change should be valid considering we've dropped node 10 and 12 support.

@kuhe kuhe requested a review from a team as a code owner November 7, 2022 19:32
@kuhe kuhe changed the title chore(types): update @types/node to 12 chore(types): update @types/node to ~12~ 14 Nov 7, 2022
@kuhe kuhe changed the title chore(types): update @types/node to ~12~ 14 chore(types): update @types/node to ~~12~~ 14 Nov 7, 2022
@kuhe kuhe changed the title chore(types): update @types/node to ~~12~~ 14 chore(types): update @types/node to 14 Nov 7, 2022
@kuhe kuhe force-pushed the chore/types-node branch from b6c50a0 to f34942f Compare November 9, 2022 14:01
@kuhe kuhe force-pushed the chore/types-node branch from f34942f to fc8ec42 Compare November 9, 2022 14:27
@@ -32,7 +32,7 @@ export const sdkStreamMixin = (stream: unknown): SdkStream<Readable> => {
transformToString: async (encoding?: string) => {
const buf = await transformToByteArray();
if (encoding === undefined || Buffer.isEncoding(encoding)) {
return fromArrayBuffer(buf.buffer, buf.byteOffset, buf.byteLength).toString(encoding);
return fromArrayBuffer(buf.buffer, buf.byteOffset, buf.byteLength).toString(encoding as BufferEncoding);
Copy link
Contributor Author

Choose a reason for hiding this comment

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

I am telling Buffer.toString to not typecheck the encoding. This should not be applied upward to encoding?: string because

  • I don't think the enumeration is actually exhaustive, but regardless,
  • it makes it very hard to make the browser version consistently typed with this one

@kuhe kuhe merged commit c772664 into aws:main Nov 9, 2022
@kuhe kuhe deleted the chore/types-node branch November 9, 2022 21:04
@github-actions
Copy link

This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs and link to relevant comments in this thread.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Nov 24, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants