diff options
author | Chris Laplante <chris.laplante@agilent.com> | 2024-12-06 11:24:41 -0500 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2024-12-06 23:33:54 +0000 |
commit | bfe176d6d57cfe934d7d8efc706247cf1f762702 (patch) | |
tree | 2092711a48b4b4a0f4a546aaeb2f317abc3e7c91 /bitbake/lib | |
parent | c7b362f5ec380bea7dcce9790f739d3b507b4341 (diff) | |
download | poky-bfe176d6d57cfe934d7d8efc706247cf1f762702.tar.gz |
bitbake: knotty: some small cleanups while I'm in here
+ missing imports
+ indentation fix
+ missing call to super __init__
+ redundant parenthesis
(Bitbake rev: 89613f4ba31377528d1934cc591fe33218bd916a)
Signed-off-by: Chris Laplante <chris.laplante@agilent.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'bitbake/lib')
-rw-r--r-- | bitbake/lib/bb/ui/knotty.py | 13 |
1 files changed, 10 insertions, 3 deletions
diff --git a/bitbake/lib/bb/ui/knotty.py b/bitbake/lib/bb/ui/knotty.py index 881df9e5fb..2fff1b3669 100644 --- a/bitbake/lib/bb/ui/knotty.py +++ b/bitbake/lib/bb/ui/knotty.py | |||
@@ -24,6 +24,12 @@ import atexit | |||
24 | from itertools import groupby | 24 | from itertools import groupby |
25 | 25 | ||
26 | from bb.ui import uihelper | 26 | from bb.ui import uihelper |
27 | import bb.build | ||
28 | import bb.command | ||
29 | import bb.cooker | ||
30 | import bb.event | ||
31 | import bb.runqueue | ||
32 | import bb.utils | ||
27 | 33 | ||
28 | featureSet = [bb.cooker.CookerFeatures.SEND_SANITYEVENTS, bb.cooker.CookerFeatures.BASEDATASTORE_TRACKING] | 34 | featureSet = [bb.cooker.CookerFeatures.SEND_SANITYEVENTS, bb.cooker.CookerFeatures.BASEDATASTORE_TRACKING] |
29 | 35 | ||
@@ -103,7 +109,7 @@ def new_progress(msg, maxval): | |||
103 | return NonInteractiveProgress(msg, maxval) | 109 | return NonInteractiveProgress(msg, maxval) |
104 | 110 | ||
105 | def pluralise(singular, plural, qty): | 111 | def pluralise(singular, plural, qty): |
106 | if(qty == 1): | 112 | if qty == 1: |
107 | return singular % qty | 113 | return singular % qty |
108 | else: | 114 | else: |
109 | return plural % qty | 115 | return plural % qty |
@@ -112,6 +118,7 @@ def pluralise(singular, plural, qty): | |||
112 | class InteractConsoleLogFilter(logging.Filter): | 118 | class InteractConsoleLogFilter(logging.Filter): |
113 | def __init__(self, tf): | 119 | def __init__(self, tf): |
114 | self.tf = tf | 120 | self.tf = tf |
121 | super().__init__() | ||
115 | 122 | ||
116 | def filter(self, record): | 123 | def filter(self, record): |
117 | if record.levelno == bb.msg.BBLogFormatter.NOTE and (record.msg.startswith("Running") or record.msg.startswith("recipe ")): | 124 | if record.levelno == bb.msg.BBLogFormatter.NOTE and (record.msg.startswith("Running") or record.msg.startswith("recipe ")): |
@@ -569,9 +576,9 @@ def main(server, eventHandler, params, tf = TerminalFilter): | |||
569 | loglink = os.path.join(consolelogdirname, 'console-latest.log') | 576 | loglink = os.path.join(consolelogdirname, 'console-latest.log') |
570 | bb.utils.remove(loglink) | 577 | bb.utils.remove(loglink) |
571 | try: | 578 | try: |
572 | os.symlink(os.path.basename(consolelogfile), loglink) | 579 | os.symlink(os.path.basename(consolelogfile), loglink) |
573 | except OSError: | 580 | except OSError: |
574 | pass | 581 | pass |
575 | 582 | ||
576 | # Add the logging domains specified by the user on the command line | 583 | # Add the logging domains specified by the user on the command line |
577 | for (domainarg, iterator) in groupby(params.debug_domains): | 584 | for (domainarg, iterator) in groupby(params.debug_domains): |