FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

stream: always delay construct callback by a nextTick by mcollina · Pull Request #46818 · nodejs/node · GitHub

/ node Public

stream: always delay construct callback by a nextTick - #46818

Merged
nodejs-github-bot merged 3 commits into
nodejs:mainfrom
mcollina:fix-46765
Feb 26, 2023
Merged

stream: always delay construct callback by a nextTick#46818
nodejs-github-bot merged 3 commits into
nodejs:mainfrom
mcollina:fix-46765

Conversation

Copy link
Copy Markdown
Member

Fixes: #46765

mcollina requested a review from ronag February 24, 2023 15:48

Copy link
Copy Markdown
Collaborator

Review requested:

  • @nodejs/streams

nodejs-github-bot added the needs-ci PRs that need a full CI run. label Feb 24, 2023
Signed-off-by: Matteo Collina <hello@matteocollina.com>
Fixes: nodejs#46765
mcollina added the request-ci Add this label to start a Jenkins CI on a PR. label Feb 24, 2023
github-actions Bot removed the request-ci Add this label to start a Jenkins CI on a PR. label Feb 24, 2023

Copy link
Copy Markdown
Collaborator

ronag left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

LGTM, though jump is a weird name...

Copy link
Copy Markdown
Member Author

LGTM, though jump is a weird name...

what would you recommend?

ronag commented Feb 24, 2023

Copy link
Copy Markdown
Member

LGTM, though jump is a weird name...

what would you recommend?

onConstructNT and onConstruct, like we usually do?

ronag commented Feb 24, 2023

Copy link
Copy Markdown
Member

Or:

try {
  stream._construct(err => {
    process.nextTick(onConstruct, err);
  });
} catch (err) {
  process.nextTick(onConstruct, err);
}

Signed-off-by: Matteo Collina <hello@matteocollina.com>
mcollina added the request-ci Add this label to start a Jenkins CI on a PR. label Feb 24, 2023
github-actions Bot removed the request-ci Add this label to start a Jenkins CI on a PR. label Feb 24, 2023

Copy link
Copy Markdown
Collaborator

Comment thread lib/internal/streams/destroy.js Outdated
Co-authored-by: Antoine du Hamel <duhamelantoine1995@gmail.com>
ronag added the request-ci Add this label to start a Jenkins CI on a PR. label Feb 24, 2023
github-actions Bot removed the request-ci Add this label to start a Jenkins CI on a PR. label Feb 24, 2023

Copy link
Copy Markdown
Collaborator

aduh95 added author ready PRs that have at least one approval, no outstanding review comments, and a CI started. commit-queue Add this label to land a pull request using GitHub Actions. commit-queue-squash Add this label to instruct the Commit Queue to squash all the PR commits into the first one. labels Feb 24, 2023

bnoordhuis commented Feb 25, 2023
edited
Loading

Copy link
Copy Markdown
Member

Just double-checking: with this change there are now three (3) process.nextTick calls involved in a construct call: constructNT -> onConstruct -> emitConstructNT. That's intentional?

Copy link
Copy Markdown
Member Author

Just double-checking: with this change there are now three (3) process.nextTick calls involved in a construct call: constructNT -> onConstruct -> emitConstructNT. That's intentional?

Good spot! I was able to remove one.

mcollina added the request-ci Add this label to start a Jenkins CI on a PR. label Feb 25, 2023
github-actions Bot removed the request-ci Add this label to start a Jenkins CI on a PR. label Feb 25, 2023

Copy link
Copy Markdown
Collaborator

Copy link
Copy Markdown
Collaborator

nodejs-github-bot removed the commit-queue Add this label to land a pull request using GitHub Actions. label Feb 26, 2023
nodejs-github-bot merged commit 355bcbc into nodejs:main Feb 26, 2023

Copy link
Copy Markdown
Collaborator

Landed in 355bcbc

targos pushed a commit that referenced this pull request Mar 13, 2023
Signed-off-by: Matteo Collina <hello@matteocollina.com>
Fixes: #46765
PR-URL: #46818
Reviewed-By: Robert Nagy <ronagy@icloud.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
targos pushed a commit that referenced this pull request Mar 14, 2023
Signed-off-by: Matteo Collina <hello@matteocollina.com>
Fixes: #46765
PR-URL: #46818
Reviewed-By: Robert Nagy <ronagy@icloud.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
danielleadams pushed a commit that referenced this pull request Apr 11, 2023
Signed-off-by: Matteo Collina <hello@matteocollina.com>
Fixes: #46765
PR-URL: #46818
Reviewed-By: Robert Nagy <ronagy@icloud.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
kt3k added a commit to kt3k/deno that referenced this pull request Nov 22, 2023
kt3k added a commit to denoland/deno that referenced this pull request Nov 23, 2023
This change applies the same fix as
nodejs/node#46818, and the original example
given in #20456 works as expected.

closes #20456
crowlKats pushed a commit to denoland/deno that referenced this pull request Nov 24, 2023
This change applies the same fix as
nodejs/node#46818, and the original example
given in #20456 works as expected.

closes #20456

(cherry picked from commit bf42467)
bartlomieju pushed a commit to denoland/deno that referenced this pull request Nov 24, 2023
This change applies the same fix as
nodejs/node#46818, and the original example
given in #20456 works as expected.

closes #20456
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

author ready PRs that have at least one approval, no outstanding review comments, and a CI started. commit-queue-squash Add this label to instruct the Commit Queue to squash all the PR commits into the first one. needs-ci PRs that need a full CI run.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

stream.Transform changing order of items

8 participants


Back | FazBrowse Home | New Git URL