Skip to content

[codex] honor stream close lifecycle options#4386

Draft
andrewtdiz wants to merge 4 commits into
PerryTS:mainfrom
andrewtdiz:codex/stream-close-lifecycle
Draft

[codex] honor stream close lifecycle options#4386
andrewtdiz wants to merge 4 commits into
PerryTS:mainfrom
andrewtdiz:codex/stream-close-lifecycle

Conversation

@andrewtdiz
Copy link
Copy Markdown
Contributor

Summary

  • Track emitClose on classic stream instances and suppress close events when it is false while still marking destroyed streams closed.
  • Stop closing readable-only streams after end when autoDestroy: false.
  • Add focused runtime coverage for both lifecycle option branches.

Validation

  • cargo test -p perry-runtime readable_emit_close_false_suppresses_destroy_close_event
  • cargo test -p perry-runtime readable_auto_destroy_false_does_not_close_after_end
  • PERRY_NO_AUTO_OPTIMIZE=1 PERRY_NO_CACHE=1 npm exec --yes --package=node@26 -- bash -lc './run_parity_tests.sh --suite node-suite --module stream --filter emit-close-false'\n- PERRY_NO_AUTO_OPTIMIZE=1 PERRY_NO_CACHE=1 npm exec --yes --package=node@26 -- bash -lc './run_parity_tests.sh --suite node-suite --module stream --filter options-autoDestroy-explicit'\n- PERRY_NO_AUTO_OPTIMIZE=1 PERRY_NO_CACHE=1 npm exec --yes --package=node@26 -- bash -lc './run_parity_tests.sh --suite node-suite --module stream --filter auto-destroy'\n- PERRY_NO_AUTO_OPTIMIZE=1 PERRY_NO_CACHE=1 npm exec --yes --package=node@26 -- bash -lc './run_parity_tests.sh --suite node-suite --module stream --filter close'

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants