From 38c2b8947e5e901609a834e0c6c14ed7f17043f2 Mon Sep 17 00:00:00 2001 From: Thomas Mangin Date: Wed, 8 Apr 2020 18:07:29 +0100 Subject: logging: T2186: cosmetic changes --- python/vyos/airbag.py | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) (limited to 'python') diff --git a/python/vyos/airbag.py b/python/vyos/airbag.py index 47d3dcb43..664974d5f 100644 --- a/python/vyos/airbag.py +++ b/python/vyos/airbag.py @@ -25,9 +25,7 @@ from vyos.util import run from vyos.util import debug -# during the session, system-versions-foot is called to generate -# the config footer, the code currently use stdout, so to do not -# get a copy of that, we allow to disable the extra logging +# we allow to disable the extra logging DISABLE = False @@ -79,7 +77,8 @@ def bug_report(dtype, value, trace): # reach the end of __main__ and was not intercepted def intercepter(dtype, value, trace): bug_report(dtype, value, trace) - if debug('developer') not in [None, '0', '']: + # debug returns either '' or 'developer' if debuging is enabled + if debug('developer'): import pdb pdb.pm() -- cgit v1.2.3