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.
When ora uses its
StdinDiscarder,stdinwill be paused when the discarder is stopped (on all platforms except windows). This is due to a historic, undocumented implementation detail ofnode:readline, where callingreadline.close()causes the input stream (stdin) to be paused. Thus, this propagates up toStdinDiscarderwhen it callscloseon itsreadlinehandle.I feel like this behavior seems like a bug in
ora, unintentionally present due to the side-effect fromnode:readline. It feels inconsistent thatstdinwould be paused at the very end ofora's lifecycle only on the condition of using a tty and theStdinDiscarder. I would expectstdinto remain unpaused at the end ofora's lifecycle regardless of those conditions.