mirror of
https://git.wownero.com/wownero/tippero.git
synced 2024-08-15 00:33:14 +00:00
Prefix logs with embedded newlines with time/type header
This commit is contained in:
parent
244b11db7d
commit
e092188f80
1 changed files with 2 additions and 1 deletions
|
@ -60,7 +60,8 @@ last_ping_time = time.time()
|
|||
|
||||
|
||||
def log(stype,msg):
|
||||
print '%s\t%s\t%s' % (time.ctime(time.time()),stype,str(msg))
|
||||
header = "%s\t%s\t" % (time.ctime(time.time()),stype)
|
||||
print "%s%s" % (header, str(msg).replace("\n","\n"+header))
|
||||
|
||||
def log_error(msg):
|
||||
log("ERROR",msg)
|
||||
|
|
Loading…
Reference in a new issue