Skip to content

Node 22 doesn't honor the --watch-preserve-output command-line parameter #56330

Open
@claudioc

Description

@claudioc

Version

22.12.0

Platform

macOS 14.7.2

Subsystem

No response

What steps will reproduce the bug?

I have this command that I run with npm: node --env-file=.env --watch-preserve-output --watch-path ./dist/server and it has always worked as expected. Now, after switching (using nvm) to node 22, the screen is always cleared upon restarting. If I switch back to node 20 (with nvm), the --watch-preserve-output parameter is honored.

How often does it reproduce? Is there a required condition?

It happens all the times

What is the expected behavior? Why is that the expected behavior?

This is apparently a regression on the node 20 line.

What do you see instead?

The screen is cleared upon restarting the server

Additional information

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions