summaryrefslogtreecommitdiffstats
path: root/bitbake/lib
diff options
context:
space:
mode:
Diffstat (limited to 'bitbake/lib')
-rw-r--r--bitbake/lib/bb/__init__.py16
-rw-r--r--bitbake/lib/bb/msg.py3
2 files changed, 19 insertions, 0 deletions
diff --git a/bitbake/lib/bb/__init__.py b/bitbake/lib/bb/__init__.py
index 4e9f6e3535..170c592acf 100644
--- a/bitbake/lib/bb/__init__.py
+++ b/bitbake/lib/bb/__init__.py
@@ -63,6 +63,10 @@ class BBLogger(Logger):
63 def verbose(self, msg, *args, **kwargs): 63 def verbose(self, msg, *args, **kwargs):
64 return self.log(logging.INFO - 1, msg, *args, **kwargs) 64 return self.log(logging.INFO - 1, msg, *args, **kwargs)
65 65
66 def verbnote(self, msg, *args, **kwargs):
67 return self.log(logging.INFO + 2, msg, *args, **kwargs)
68
69
66logging.raiseExceptions = False 70logging.raiseExceptions = False
67logging.setLoggerClass(BBLogger) 71logging.setLoggerClass(BBLogger)
68 72
@@ -93,6 +97,18 @@ def debug(lvl, *args):
93def note(*args): 97def note(*args):
94 mainlogger.info(''.join(args)) 98 mainlogger.info(''.join(args))
95 99
100#
101# A higher prioity note which will show on the console but isn't a warning
102#
103# Something is happening the user should be aware of but they probably did
104# something to make it happen
105#
106def verbnote(*args):
107 mainlogger.verbnote(''.join(args))
108
109#
110# Warnings - things the user likely needs to pay attention to and fix
111#
96def warn(*args): 112def warn(*args):
97 mainlogger.warning(''.join(args)) 113 mainlogger.warning(''.join(args))
98 114
diff --git a/bitbake/lib/bb/msg.py b/bitbake/lib/bb/msg.py
index f1723be797..96f077ec49 100644
--- a/bitbake/lib/bb/msg.py
+++ b/bitbake/lib/bb/msg.py
@@ -40,6 +40,7 @@ class BBLogFormatter(logging.Formatter):
40 VERBOSE = logging.INFO - 1 40 VERBOSE = logging.INFO - 1
41 NOTE = logging.INFO 41 NOTE = logging.INFO
42 PLAIN = logging.INFO + 1 42 PLAIN = logging.INFO + 1
43 VERBNOTE = logging.INFO + 2
43 ERROR = logging.ERROR 44 ERROR = logging.ERROR
44 WARNING = logging.WARNING 45 WARNING = logging.WARNING
45 CRITICAL = logging.CRITICAL 46 CRITICAL = logging.CRITICAL
@@ -51,6 +52,7 @@ class BBLogFormatter(logging.Formatter):
51 VERBOSE: 'NOTE', 52 VERBOSE: 'NOTE',
52 NOTE : 'NOTE', 53 NOTE : 'NOTE',
53 PLAIN : '', 54 PLAIN : '',
55 VERBNOTE: 'NOTE',
54 WARNING : 'WARNING', 56 WARNING : 'WARNING',
55 ERROR : 'ERROR', 57 ERROR : 'ERROR',
56 CRITICAL: 'ERROR', 58 CRITICAL: 'ERROR',
@@ -66,6 +68,7 @@ class BBLogFormatter(logging.Formatter):
66 VERBOSE : BASECOLOR, 68 VERBOSE : BASECOLOR,
67 NOTE : BASECOLOR, 69 NOTE : BASECOLOR,
68 PLAIN : BASECOLOR, 70 PLAIN : BASECOLOR,
71 VERBNOTE: BASECOLOR,
69 WARNING : YELLOW, 72 WARNING : YELLOW,
70 ERROR : RED, 73 ERROR : RED,
71 CRITICAL: RED, 74 CRITICAL: RED,