I have this fun in my python script:
def start_pushdata_server(Logger):
Logger.write_event("Starting pushdata Server..", "INFO")
retcode, stdout, stderr = run_shell(create_shell_command("pushdata-server
start"))
we want to redirect the standard error from pushdata-server binary to /dev/null.
so we edit it like this:
def start_pushdata_server(Logger):
Logger.write_event("Starting pushdata Server..", "INFO")
retcode, stdout, stderr = run_shell(create_shell_command("pushdata-server
start 2>/dev/null"))
But adding the 2>/dev/null
in the python code isn't valid.
So how we can in the python code to send all errors from "pushdata-server start" to null?