Allow option to suppress info messages that are sent to stderr
See original GitHub issueAs per https://github.com/pypa/pipenv/issues/628 and https://github.com/pypa/pipenv/pull/630, some output, e.g. courtesy notices and messages like
Loading .env environment variables…
are sent to stderr instead of stdout. This is somewhat unexpected behaviour as these are clearly not error messages. In fact, these messages are polluting some of our error logs. It would be really useful to have an option to completely suppress these messages, e.g. by allowing the --bare
flag for the run
and shell
commands.
Issue Analytics
- State:
- Created 6 years ago
- Reactions:3
- Comments:7 (2 by maintainers)
Top Results From Across the Web
suppress stderr messages in a bash script
You're right; pkill isn't generating the message, bash is. You suggest that $ ./test1.sh 2> /dev/null. is a possible solution.
Read more >Python Recipes- Suppress Stdout And Stderr Messages
Python recipes to suppress stdout and stderr messages into devnull or your own log file via context manager.
Read more >Suppress output to stderr in matlab - logging - Stack Overflow
The problem here is, that in the matlab command line call, the output from STDERR is streamed to STDOUT by this "command": 2>&1...
Read more >How do I suppress INFO and WARNING messages when c ...
I am making a connection to Hive in Java with the following: Connection conn = DriverManager.getConnection(connectionUrl, userName, password);.
Read more >Spark - Stop INFO & DEBUG message logging to console?
Problem: In Spark, wondering how to stop/disable/turn off INFO and DEBUG message logging to Spark console, when I run a Spark or PySpark ......
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
disagree 😃
i don’t want to redirect all of my stderr though, just this one message; one can do what @sudeshjethoe suggested and pipe stderr into grep -v then pipe the stdout of that back to stderr, all the while redirecting stdout to null, but it seems like a really convoluted (and limiting) solution for removing a non-critical message from stderr
for anyone else looking to do this, here’s my current solution:
which I found courtesy of this SO answer https://stackoverflow.com/a/15936384/912015