mirror of
https://github.com/altlinux/gpupdate.git
synced 2025-03-21 18:50:38 +03:00
Don't do anything if log metadata is not JSON-encodable
This commit is contained in:
parent
1f6b7d4cb7
commit
8f96b1be85
@ -52,7 +52,11 @@ class slogm(object):
|
||||
#args.update(dict({'timestamp': now, 'message': str(self.message)}))
|
||||
args.update(self.kwargs)
|
||||
|
||||
kwa = encoder().encode(args)
|
||||
kwa = dict()
|
||||
try:
|
||||
kwa = encoder().encode(args)
|
||||
except Exception as exc:
|
||||
pass
|
||||
|
||||
result = '{}|{}|{}'.format(now, self.message, kwa)
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user