`mach environment --format=json` can output status messages to stdout
Categories
(Firefox Build System :: Mach Core, defect, P3)
Tracking
(firefox123 fixed)
| Tracking | Status | |
|---|---|---|
| firefox123 | --- | fixed |
People
(Reporter: jcristau, Assigned: ahochheiden)
References
Details
Attachments
(1 external file, 1 obsolete file)
mach environment --format=json sometimes outputs things like Site not up-to-date reason: [...] on stdout instead of just the json output, which makes it unparseable. Those log messages should probably be on stderr instead so they can be cleanly separated from the command's output.
| Assignee | ||
Comment 1•2 years ago
|
||
Seems reasonable. Ideally it'd be debug level output in the log, but the mach logging handling isn't available that early on startup, so stderr will have to do.
| Assignee | ||
Comment 2•2 years ago
|
||
It's not technically an error, but we can't make it debug level output
since the mach logging isn't available this early on startup. There's
precedent for using stderr output elsewhere in site.py, though it
usually precedes an exception being raised.
Comment 4•2 years ago
|
||
Backed out for causing BP bustages
Backout link: https://hg.mozilla.org/integration/autoland/rev/0b45689344a0d5fc199aa8815377d06d12ab5452
Log link: https://treeherder.mozilla.org/logviewer?job_id=443062644&repo=autoland&lineNumber=106655
Updated•2 years ago
|
| Assignee | ||
Comment 5•2 years ago
|
||
Looks like we can't use stderr since mozharness treats any output there as a full error. Trying to add a workaround there will potentially open up a can of worms that's not worth the effort, so I'll just remove the always printed Site up-to-date reason (even if it does help troubleshooting user issues sometimes).
| Assignee | ||
Comment 6•2 years ago
|
||
While this message was sometimes useful to help troubleshoot for end
users, it's causing issues parsing stdout (since it can't use the mach
logging infrastructure due to being too early in the startup). We also
can't use stderr since some mozharness scripts treat any stderr
output as a full error.
| Assignee | ||
Updated•2 years ago
|
Comment 8•2 years ago
|
||
| bugherder | ||
Description
•