Skip to content

Commit

Permalink
1. add command line option -p/--print-level optioon for ostap sc…
Browse files Browse the repository at this point in the history
…ript for better contol of the global print level
  • Loading branch information
VanyaBelyaev committed Jul 10, 2024
1 parent e967ecc commit 5a190db
Showing 1 changed file with 10 additions and 9 deletions.
19 changes: 10 additions & 9 deletions ostap/logger/logger.py
Original file line number Diff line number Diff line change
Expand Up @@ -58,18 +58,19 @@
# =============================================================================
## Message levels (a'la Gaudi)
# =============================================================================
ALL = 0
VERBOSE = 1
DEBUG = 2
INFO = 3
WARNING = 4
ERROR = 5
FATAL = 6
ALL = 0
VERBOSE = 1
DEBUG = 2
INFO = 3
ATTENTION = 4
WARNING = 5
ERROR = 6
FATAL = 7
# =============================================================================
## some manipulations with logging module
if not hasattr ( logging , 'VERBOSE' ) : logging.VERBOSE = 5
if not hasattr ( logging , 'ATTENTION' ) : logging.ATTENTION = logging.INFO + 2
if not hasattr ( logging , 'FATAL' ) : logging.FATAL = logging.CRITICAL
if not hasattr ( logging , 'ATTENTION' ) : logging.ATTENTION = logging.INFO + 2
if not hasattr ( logging , 'FATAL' ) : logging.FATAL = logging.CRITICAL + 1
# =============================================================================
## Log message with severity 'VERBOSE'
def _verbose1_(self, msg, *args, **kwargs):
Expand Down

0 comments on commit 5a190db

Please sign in to comment.