Skip to content

stream: observe abort while awaiting pipeTo source#64015

Merged
nodejs-github-bot merged 1 commit into
nodejs:mainfrom
trivikr:stream-iter-pipeto-abort-signal
Jun 22, 2026
Merged

stream: observe abort while awaiting pipeTo source#64015
nodejs-github-bot merged 1 commit into
nodejs:mainfrom
trivikr:stream-iter-pipeto-abort-signal

Conversation

@trivikr

@trivikr trivikr commented Jun 20, 2026

Copy link
Copy Markdown
Member

Fixes: #64014

stream/iter's pipeTo() already checks the abort signal after receiving
source batches, but the no-transform path did not observe aborts while waiting
for the next source chunk.

This updates that path to use the existing abort-aware iterator wrapper so
pipeTo() rejects promptly when the signal aborts, even if the source
next() call is still pending.


Assisted-by: openai:gpt-5.5

@nodejs-github-bot

Copy link
Copy Markdown
Collaborator

Review requested:

  • @nodejs/streams

@nodejs-github-bot nodejs-github-bot added needs-ci PRs that need a full CI run. stream Issues and PRs related to the stream subsystem. labels Jun 20, 2026
@trivikr trivikr force-pushed the stream-iter-pipeto-abort-signal branch from cc8071c to 7d69188 Compare June 20, 2026 01:36
Use the abort-aware iterator wrapper in the no-transform pipeTo()
path so a pending source read does not block AbortSignal handling.

Fixes: nodejs#64014

Signed-off-by: Kamat, Trivikram <16024985+trivikr@users.noreply.github.com>
Assisted-by: openai:gpt-5.5
@trivikr trivikr force-pushed the stream-iter-pipeto-abort-signal branch from 7d69188 to e2918ed Compare June 20, 2026 14:40

@mcollina mcollina 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.

lgtm

@mcollina mcollina added the request-ci Add this label to start a Jenkins CI on a PR. label Jun 21, 2026
@github-actions github-actions Bot removed the request-ci Add this label to start a Jenkins CI on a PR. label Jun 21, 2026
@nodejs-github-bot

This comment was marked as outdated.

@trivikr trivikr added the author ready PRs that have at least one approval, no pending requests for changes, and a CI started. label Jun 21, 2026
@nodejs-github-bot

Copy link
Copy Markdown
Collaborator

@trivikr trivikr added the commit-queue Add this label to land a pull request using GitHub Actions. label Jun 22, 2026
@nodejs-github-bot nodejs-github-bot removed the commit-queue Add this label to land a pull request using GitHub Actions. label Jun 22, 2026
@nodejs-github-bot nodejs-github-bot merged commit a0263fe into nodejs:main Jun 22, 2026
73 checks passed
@nodejs-github-bot

Copy link
Copy Markdown
Collaborator

Landed in a0263fe

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 pending requests for changes, and a CI started. needs-ci PRs that need a full CI run. stream Issues and PRs related to the stream subsystem.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

stream/iter pipeTo() does not observe abort while waiting for the next source chunk

4 participants