Skip to content

Proposal: separate Console transport into proper Console, and separate StdOut #1836

@baybal

Description

@baybal

Following #1787 #1774 #1636 #1609, and ultimately #1544. I think we need to put it clearly that console, and stdout are two different things.

What's the feature?

I propose to split the Console transport into one that uses actual console, and one specifically stdout/stderr.

The global console object may often be overridden, or have its methods wrapped/redefined by other debug tooling.

I believe users explicitly choosing console output are ones who need this for debug/tooling purposes, and that functionality should not be impacted by winston.

I prepared a PR #1835 that restored console transport usage of console.log without impacting wrappers/debugging, and avoiding the threat of circular invocation at the same time.

The PR edits work fine for me. You can edit your CI tests to omit EOL checks for Console transport, and create the StdOut transport from the old version of Console transport.

What problem is the feature intended to solve?

Allow users needing real console.log output able to use it, while leaving stdout output as is.

Is the absence of this feature blocking you or your team? If so, how?

I can't see inspector/debugger output. It prevents logging showing up in microservice frameworks that have their own console.log implementations.

Is this feature similar to an existing feature in another tool?

No

Is this a feature you're prepared to implement, with support from us?

Yes

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