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

Skip to content

node:tty polyfill default export mistakenly exports ReadStream as WriteStream #512

@jasnell

Description

@jasnell

Environment

All

Reproduction

No repro, just pointer to source.

Describe the bug

Current source of src/runtime/node/tty.ts

export default {
  ReadStream: WriteStream as unknown as typeof nodeTty.ReadStream,
  WriteStream: WriteStream as unknown as typeof nodeTty.WriteStream,
  isatty,
} satisfies typeof nodeTty;

Note the ReadStream: WriteStream as ...

Additional context

No response

Logs

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions