# lsst.log should default to stdout

XMLWordPrintable

## Details

• Type: RFC
• Status: Implemented
• Resolution: Done
• Component/s:
• Labels:

## Description

Currently, lsst.log sends all output to stderr. This is surprising since most log messages are not errors: generally only actual errors (e.g. python exceptions, stack traces) should be sent to stderr.

lsst.log should send all output to stdout. This helps separate logs and errors when piping output; for example, in python:

 subprocess.check_call(['jointcal.py', *args], stdout=open('jointcal.log', 'w'), stderr=open('log.err','w)) 

I might also suggest that errors at warn, error, and fatal levels also get sent to stderr, so they're more easily identified, though that would result in them being duplicated when logging to a terminal. I'm not sure we want them to only go to stderr, as that pulls them out of context, but they can get drowned in all the other messages.

## People

• Assignee:
John Parejko
Reporter:
John Parejko
Watchers:
Andy Salnikov, John Parejko, Joshua Hoblitt, Kian-Tat Lim, Krzysztof Findeisen, Paul Price, Robert Lupton
{"extraction_info": {"found_math": true, "script_math_tex": 0, "script_math_asciimath": 0, "math_annotations": 0, "math_alttext": 0, "mathml": 0, "mathjax_tag": 0, "mathjax_inline_tex": 0, "mathjax_display_tex": 0, "mathjax_asciimath": 1, "img_math": 0, "codecogs_latex": 0, "wp_latex": 0, "mimetex.cgi": 0, "/images/math/codecogs": 0, "mathtex.cgi": 0, "katex": 0, "math-container": 0, "wp-katex-eq": 0, "align": 0, "equation": 0, "x-ck12": 0, "texerror": 0, "math_score": 0.16177135705947876, "perplexity": 16632.870406829577}, "config": {"markdown_headings": true, "markdown_code": true, "boilerplate_config": {"ratio_threshold": 0.18, "absolute_threshold": 10, "end_threshold": 15, "enable": true}, "remove_buttons": true, "remove_image_figures": true, "remove_link_clusters": true, "table_config": {"min_rows": 2, "min_cols": 3, "format": "plain"}, "remove_chinese": true, "remove_edit_buttons": true, "extract_latex": true}, "warc_path": "s3://commoncrawl/crawl-data/CC-MAIN-2020-05/segments/1579250601628.36/warc/CC-MAIN-20200121074002-20200121103002-00298.warc.gz"}