From 5f8641f05d7228b971baa3bdd79c825fae17f893 Mon Sep 17 00:00:00 2001 From: Vit Mojzis Date: Mar 23 2021 12:20:23 +0000 Subject: framework: Fix plugin exception reporting Fixes: Traceback (most recent call last): File "/usr/lib/python3.6/site-packages/setroubleshoot/analyze.py", line 647, in self.idle_proc_id = GLib.idle_add(lambda: next(task_generator)) File "/usr/lib/python3.6/site-packages/setroubleshoot/analyze.py", line 680, in task self.close() File "/usr/lib/python3.6/site-packages/setroubleshoot/analyze.py", line 668, in close self.avc_event_handler(audit_event) File "/usr/lib/python3.6/site-packages/setroubleshoot/analyze.py", line 709, in avc_event_handler self.analyzer.analyze_avc(avc, self.report_receiver, False) File "/usr/lib/python3.6/site-packages/setroubleshoot/analyze.py", line 218, in analyze_avc log_debug(join(traceback.format_tb(v3))) NameError: name 'join' is not defined --- diff --git a/framework/src/setroubleshoot/analyze.py b/framework/src/setroubleshoot/analyze.py index 9ff1288..c80e144 100644 --- a/framework/src/setroubleshoot/analyze.py +++ b/framework/src/setroubleshoot/analyze.py @@ -216,7 +216,7 @@ class Analyze(object): print(e, file=sys.stderr) syslog.syslog(syslog.LOG_ERR, "Plugin Exception %s " % plugin.analysis_id) (v1, v2, v3) = sys.exc_info() - log_debug(join(traceback.format_tb(v3))) + log_debug('\n'.join(traceback.format_tb(v3))) self.plugins.remove(plugin) report_receiver.report_problem(siginfo)