zazuko/barnard59

Some errors are emitted to stdout instead of stderr

tpluscode opened this issue · 5 comments

Some errors are emitted to stdout instead of stderr

browsing history I noticed commit 9bb6520 changed console.error(err) to console.log(err). Maybe we should just revert to using console.error?

Good catch. There should be no console at all

not sure about removing console altogether, at least the error message for multiple roots is useful (see the related PR)

ktk commented

Not sure if that changed but console.log was or is synchronous so it's better to use an abstraction for logging that can write to console but doesn't do so unless we tell it to. Not sure what's the latest and greates logger though.

yes, we have the proper logging abstractions in place and all the other telemetry stuff. My guess is that this is a special case because we are at the boundaries of the system, where even the logging abstractions may not be available yet.