diff options
author | Richard Purdie <richard.purdie@linuxfoundation.org> | 2011-08-15 17:29:09 +0100 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2011-08-15 17:31:52 +0100 |
commit | a21ff559e7c93e9da61104f4a33e42e6004189fd (patch) | |
tree | 0f71f9cdd87c3ddacacd58732791501392bff5ed | |
parent | a7e4747f499d4219c29277e80e64e4fdf604628a (diff) | |
download | poky-a21ff559e7c93e9da61104f4a33e42e6004189fd.tar.gz |
Fixup remaining bb.msg.domain users
(Bitbake rev: d5abdacaf9ac604ef8d8c1bafb9b30617827cb4f)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
-rw-r--r-- | bitbake/lib/bb/msg.py | 2 | ||||
-rw-r--r-- | bitbake/lib/bb/runqueue.py | 20 | ||||
-rw-r--r-- | bitbake/lib/bb/taskdata.py | 4 | ||||
-rw-r--r-- | bitbake/lib/bb/ui/ncurses.py | 4 |
4 files changed, 15 insertions, 15 deletions
diff --git a/bitbake/lib/bb/msg.py b/bitbake/lib/bb/msg.py index ecf756ee25..b7ae761e4e 100644 --- a/bitbake/lib/bb/msg.py +++ b/bitbake/lib/bb/msg.py | |||
@@ -136,7 +136,7 @@ def addDefaultlogFilter(handler): | |||
136 | 136 | ||
137 | def fatal(msgdomain, msg): | 137 | def fatal(msgdomain, msg): |
138 | if msgdomain: | 138 | if msgdomain: |
139 | logger = logging.getLogger("BitBake.%s" % msgdomin) | 139 | logger = logging.getLogger("BitBake.%s" % msgdomain) |
140 | else: | 140 | else: |
141 | logger = logging.getLogger("BitBake") | 141 | logger = logging.getLogger("BitBake") |
142 | logger.critical(msg) | 142 | logger.critical(msg) |
diff --git a/bitbake/lib/bb/runqueue.py b/bitbake/lib/bb/runqueue.py index e1d32b7661..5a4321f068 100644 --- a/bitbake/lib/bb/runqueue.py +++ b/bitbake/lib/bb/runqueue.py | |||
@@ -362,7 +362,7 @@ class RunQueueData: | |||
362 | message = "\n" | 362 | message = "\n" |
363 | for msg in msgs: | 363 | for msg in msgs: |
364 | message = message + msg | 364 | message = message + msg |
365 | bb.msg.fatal(bb.msg.domain.RunQueue, message) | 365 | bb.msg.fatal("RunQueue", message) |
366 | 366 | ||
367 | return weight | 367 | return weight |
368 | 368 | ||
@@ -470,7 +470,7 @@ class RunQueueData: | |||
470 | dep = taskData.fn_index[depdata] | 470 | dep = taskData.fn_index[depdata] |
471 | taskid = taskData.gettask_id(dep, idependtask, False) | 471 | taskid = taskData.gettask_id(dep, idependtask, False) |
472 | if taskid is None: | 472 | if taskid is None: |
473 | bb.msg.fatal(bb.msg.domain.RunQueue, "Task %s in %s depends upon nonexistant task %s in %s" % (taskData.tasks_name[task], fn, idependtask, dep)) | 473 | bb.msg.fatal("RunQueue", "Task %s in %s depends upon nonexistant task %s in %s" % (taskData.tasks_name[task], fn, idependtask, dep)) |
474 | depends.append(taskid) | 474 | depends.append(taskid) |
475 | if depdata != fnid: | 475 | if depdata != fnid: |
476 | tdepends_fnid[fnid].add(taskid) | 476 | tdepends_fnid[fnid].add(taskid) |
@@ -587,7 +587,7 @@ class RunQueueData: | |||
587 | continue | 587 | continue |
588 | 588 | ||
589 | if target[1] not in taskData.tasks_lookup[fnid]: | 589 | if target[1] not in taskData.tasks_lookup[fnid]: |
590 | bb.msg.fatal(bb.msg.domain.RunQueue, "Task %s does not exist for target %s" % (target[1], target[0])) | 590 | bb.msg.fatal("RunQueue", "Task %s does not exist for target %s" % (target[1], target[0])) |
591 | 591 | ||
592 | listid = taskData.tasks_lookup[fnid][target[1]] | 592 | listid = taskData.tasks_lookup[fnid][target[1]] |
593 | 593 | ||
@@ -619,9 +619,9 @@ class RunQueueData: | |||
619 | # Check to make sure we still have tasks to run | 619 | # Check to make sure we still have tasks to run |
620 | if len(self.runq_fnid) == 0: | 620 | if len(self.runq_fnid) == 0: |
621 | if not taskData.abort: | 621 | if not taskData.abort: |
622 | bb.msg.fatal(bb.msg.domain.RunQueue, "All buildable tasks have been run but the build is incomplete (--continue mode). Errors for the tasks that failed will have been printed above.") | 622 | bb.msg.fatal("RunQueue", "All buildable tasks have been run but the build is incomplete (--continue mode). Errors for the tasks that failed will have been printed above.") |
623 | else: | 623 | else: |
624 | bb.msg.fatal(bb.msg.domain.RunQueue, "No active tasks and not in --continue mode?! Please report this bug.") | 624 | bb.msg.fatal("RunQueue", "No active tasks and not in --continue mode?! Please report this bug.") |
625 | 625 | ||
626 | logger.verbose("Pruned %s inactive tasks, %s left", delcount, len(self.runq_fnid)) | 626 | logger.verbose("Pruned %s inactive tasks, %s left", delcount, len(self.runq_fnid)) |
627 | 627 | ||
@@ -632,7 +632,7 @@ class RunQueueData: | |||
632 | origdeps = self.runq_depends[listid] | 632 | origdeps = self.runq_depends[listid] |
633 | for origdep in origdeps: | 633 | for origdep in origdeps: |
634 | if maps[origdep] == -1: | 634 | if maps[origdep] == -1: |
635 | bb.msg.fatal(bb.msg.domain.RunQueue, "Invalid mapping - Should never happen!") | 635 | bb.msg.fatal("RunQueue", "Invalid mapping - Should never happen!") |
636 | newdeps.append(maps[origdep]) | 636 | newdeps.append(maps[origdep]) |
637 | self.runq_depends[listid] = set(newdeps) | 637 | self.runq_depends[listid] = set(newdeps) |
638 | 638 | ||
@@ -653,7 +653,7 @@ class RunQueueData: | |||
653 | for dep in revdeps: | 653 | for dep in revdeps: |
654 | if dep in self.runq_depends[listid]: | 654 | if dep in self.runq_depends[listid]: |
655 | #self.dump_data(taskData) | 655 | #self.dump_data(taskData) |
656 | bb.msg.fatal(bb.msg.domain.RunQueue, "Task %s (%s) has circular dependency on %s (%s)" % (taskData.fn_index[self.runq_fnid[dep]], self.runq_task[dep], taskData.fn_index[self.runq_fnid[listid]], self.runq_task[listid])) | 656 | bb.msg.fatal("RunQueue", "Task %s (%s) has circular dependency on %s (%s)" % (taskData.fn_index[self.runq_fnid[dep]], self.runq_task[dep], taskData.fn_index[self.runq_fnid[listid]], self.runq_task[listid])) |
657 | 657 | ||
658 | logger.verbose("Compute totals (have %s endpoint(s))", len(endpoints)) | 658 | logger.verbose("Compute totals (have %s endpoint(s))", len(endpoints)) |
659 | 659 | ||
@@ -861,7 +861,7 @@ class RunQueue: | |||
861 | #print "Not current: %s" % notcurrent | 861 | #print "Not current: %s" % notcurrent |
862 | 862 | ||
863 | if len(unchecked) > 0: | 863 | if len(unchecked) > 0: |
864 | bb.msg.fatal(bb.msg.domain.RunQueue, "check_stamps fatal internal error") | 864 | bb.msg.fatal("RunQueue", "check_stamps fatal internal error") |
865 | return current | 865 | return current |
866 | 866 | ||
867 | def check_stamp_task(self, task, taskname = None): | 867 | def check_stamp_task(self, task, taskname = None): |
@@ -1103,7 +1103,7 @@ class RunQueueExecute: | |||
1103 | pipeout = os.fdopen(pipeout, 'wb', 0) | 1103 | pipeout = os.fdopen(pipeout, 'wb', 0) |
1104 | pid = os.fork() | 1104 | pid = os.fork() |
1105 | except OSError as e: | 1105 | except OSError as e: |
1106 | bb.msg.fatal(bb.msg.domain.RunQueue, "fork failed: %d (%s)" % (e.errno, e.strerror)) | 1106 | bb.msg.fatal("RunQueue", "fork failed: %d (%s)" % (e.errno, e.strerror)) |
1107 | 1107 | ||
1108 | if pid == 0: | 1108 | if pid == 0: |
1109 | pipein.close() | 1109 | pipein.close() |
@@ -1436,7 +1436,7 @@ class RunQueueExecuteScenequeue(RunQueueExecute): | |||
1436 | deps.add(self.rqdata.runq_setscene.index(dep)) | 1436 | deps.add(self.rqdata.runq_setscene.index(dep)) |
1437 | sq_revdeps_squash.append(deps) | 1437 | sq_revdeps_squash.append(deps) |
1438 | elif len(sq_revdeps_new[task]) != 0: | 1438 | elif len(sq_revdeps_new[task]) != 0: |
1439 | bb.msg.fatal(bb.msg.domain.RunQueue, "Something went badly wrong during scenequeue generation, aborting. Please report this problem.") | 1439 | bb.msg.fatal("RunQueue", "Something went badly wrong during scenequeue generation, aborting. Please report this problem.") |
1440 | 1440 | ||
1441 | #for task in xrange(len(sq_revdeps_squash)): | 1441 | #for task in xrange(len(sq_revdeps_squash)): |
1442 | # print "Task %s: %s.%s is %s " % (task, self.taskData.fn_index[self.runq_fnid[self.runq_setscene[task]]], self.runq_task[self.runq_setscene[task]] + "_setscene", sq_revdeps_squash[task]) | 1442 | # print "Task %s: %s.%s is %s " % (task, self.taskData.fn_index[self.runq_fnid[self.runq_setscene[task]]], self.runq_task[self.runq_setscene[task]] + "_setscene", sq_revdeps_squash[task]) |
diff --git a/bitbake/lib/bb/taskdata.py b/bitbake/lib/bb/taskdata.py index 79602b6389..edbc86042c 100644 --- a/bitbake/lib/bb/taskdata.py +++ b/bitbake/lib/bb/taskdata.py | |||
@@ -153,7 +153,7 @@ class TaskData: | |||
153 | fnid = self.getfn_id(fn) | 153 | fnid = self.getfn_id(fn) |
154 | 154 | ||
155 | if fnid in self.failed_fnids: | 155 | if fnid in self.failed_fnids: |
156 | bb.msg.fatal(bb.msg.domain.TaskData, "Trying to re-add a failed file? Something is broken...") | 156 | bb.msg.fatal("TaskData", "Trying to re-add a failed file? Something is broken...") |
157 | 157 | ||
158 | # Check if we've already seen this fn | 158 | # Check if we've already seen this fn |
159 | if fnid in self.tasks_fnid: | 159 | if fnid in self.tasks_fnid: |
@@ -175,7 +175,7 @@ class TaskData: | |||
175 | for dep in task_deps['depends'][task].split(): | 175 | for dep in task_deps['depends'][task].split(): |
176 | if dep: | 176 | if dep: |
177 | if ":" not in dep: | 177 | if ":" not in dep: |
178 | bb.msg.fatal(bb.msg.domain.TaskData, "Error, dependency %s does not contain ':' character\n. Task 'depends' should be specified in the form 'packagename:task'" % (dep, fn)) | 178 | bb.msg.fatal("TaskData", "Error, dependency %s does not contain ':' character\n. Task 'depends' should be specified in the form 'packagename:task'" % (dep, fn)) |
179 | ids.append(((self.getbuild_id(dep.split(":")[0])), dep.split(":")[1])) | 179 | ids.append(((self.getbuild_id(dep.split(":")[0])), dep.split(":")[1])) |
180 | self.tasks_idepends[taskid].extend(ids) | 180 | self.tasks_idepends[taskid].extend(ids) |
181 | 181 | ||
diff --git a/bitbake/lib/bb/ui/ncurses.py b/bitbake/lib/bb/ui/ncurses.py index 8684697aa2..8524446d22 100644 --- a/bitbake/lib/bb/ui/ncurses.py +++ b/bitbake/lib/bb/ui/ncurses.py | |||
@@ -283,7 +283,7 @@ class NCursesUI: | |||
283 | # if isinstance(event, bb.build.TaskFailed): | 283 | # if isinstance(event, bb.build.TaskFailed): |
284 | # if event.logfile: | 284 | # if event.logfile: |
285 | # if data.getVar("BBINCLUDELOGS", d): | 285 | # if data.getVar("BBINCLUDELOGS", d): |
286 | # bb.msg.error(bb.msg.domain.Build, "log data follows (%s)" % logfile) | 286 | # bb.error("log data follows (%s)" % logfile) |
287 | # number_of_lines = data.getVar("BBINCLUDELOGS_LINES", d) | 287 | # number_of_lines = data.getVar("BBINCLUDELOGS_LINES", d) |
288 | # if number_of_lines: | 288 | # if number_of_lines: |
289 | # os.system('tail -n%s %s' % (number_of_lines, logfile)) | 289 | # os.system('tail -n%s %s' % (number_of_lines, logfile)) |
@@ -297,7 +297,7 @@ class NCursesUI: | |||
297 | # print '| %s' % l | 297 | # print '| %s' % l |
298 | # f.close() | 298 | # f.close() |
299 | # else: | 299 | # else: |
300 | # bb.msg.error(bb.msg.domain.Build, "see log in %s" % logfile) | 300 | # bb.error("see log in %s" % logfile) |
301 | 301 | ||
302 | if isinstance(event, bb.command.CommandCompleted): | 302 | if isinstance(event, bb.command.CommandCompleted): |
303 | # stop so the user can see the result of the build, but | 303 | # stop so the user can see the result of the build, but |