Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Stdin becomes paused at close only when using StdinDiscarder with TTY #209

@clavin

Description

@clavin

When ora uses its StdinDiscarder, stdin will be paused when the discarder is stopped (on all platforms except windows). This is due to a historic, undocumented implementation detail of node:readline, where calling readline.close() causes the input stream (stdin) to be paused. Thus, this propagates up to StdinDiscarder when it calls close on its readline handle.

I feel like this behavior seems like a bug in ora, unintentionally present due to the side-effect from node:readline. It feels inconsistent that stdin would be paused at the very end of ora's lifecycle only on the condition of using a tty and the StdinDiscarder. I would expect stdin to remain unpaused at the end of ora's lifecycle regardless of those conditions.

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions