Skip to content

tty.ReadStream.setRawMode(true) on Unix does not disable tty output \n -> \r\n translation #63059

Description

Affected URL(s)

https://nodejs.org/api/tty.html

Description of the problem

When in raw mode, input is always available character-by-character, not including modifiers. Additionally, all special processing of characters by the terminal is disabled, including echoing input characters. Ctrl+C will no longer cause a SIGINT when in this mode.

This is wrong. Special processing of newline characters is still done and it is not binary safe.

See libuv/libuv#32 for historical context.

Note that I think this function name is misleading compared to user expectations, and there should be a way to have binary safe I/O (what raw mode normally is).

Activity

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    docIssues and PRs related to Node.js documentation.

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions