* [PATCH] cooker: Reset loghandler
@ 2020-02-18 22:00 Richard Purdie
0 siblings, 0 replies; only message in thread
From: Richard Purdie @ 2020-02-18 22:00 UTC (permalink / raw)
To: bitbake-devel
When parsing, reset the loghandler when finished, else the messages
can be misleading.
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
---
lib/bb/cooker.py | 3 +++
1 file changed, 3 insertions(+)
diff --git a/lib/bb/cooker.py b/lib/bb/cooker.py
index a05630d52d..2d937a413c 100644
--- a/lib/bb/cooker.py
+++ b/lib/bb/cooker.py
@@ -1949,6 +1949,7 @@ class Parser(multiprocessing.Process):
def parse(self, filename, appends):
try:
+ origfilter = bb.event.LogHandler.filter
# Record the filename we're parsing into any events generated
def parse_filter(self, record):
record.taskpid = bb.event.worker_pid
@@ -1971,6 +1972,8 @@ class Parser(multiprocessing.Process):
# a SystemExit event for example.
except BaseException as exc:
return True, ParsingFailure(exc, filename)
+ finally:
+ bb.event.LogHandler.filter = origfilter
class CookerParser(object):
def __init__(self, cooker, filelist, masked):
--
2.25.0
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2020-02-18 22:00 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-02-18 22:00 [PATCH] cooker: Reset loghandler Richard Purdie
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.