From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dan.rpsys.net (5751f4a1.skybroadband.com [87.81.244.161]) by mail.openembedded.org (Postfix) with ESMTP id C2261758DC for ; Fri, 19 Jun 2015 11:25:57 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by dan.rpsys.net (8.14.4/8.14.4/Debian-4.1ubuntu1) with ESMTP id t5JBPvql015269 for ; Fri, 19 Jun 2015 12:25:57 +0100 Received: from dan.rpsys.net ([127.0.0.1]) by localhost (dan.rpsys.net [127.0.0.1]) (amavisd-new, port 10024) with LMTP id 0SOmCqAz0-9H for ; Fri, 19 Jun 2015 12:25:57 +0100 (BST) Received: from [192.168.3.10] ([192.168.3.10]) (authenticated bits=0) by dan.rpsys.net (8.14.4/8.14.4/Debian-4.1ubuntu1) with ESMTP id t5JBPjDa015255 (version=TLSv1/SSLv3 cipher=AES128-GCM-SHA256 bits=128 verify=NOT) for ; Fri, 19 Jun 2015 12:25:57 +0100 Message-ID: <1434713145.14710.115.camel@linuxfoundation.org> From: Richard Purdie To: bitbake-devel Date: Fri, 19 Jun 2015 12:25:45 +0100 X-Mailer: Evolution 3.12.10-0ubuntu1~14.10.1 Mime-Version: 1.0 Subject: [PATCH] runqueue: Improve handling of fakeworker failing to start X-BeenThere: bitbake-devel@lists.openembedded.org X-Mailman-Version: 2.1.12 Precedence: list List-Id: Patches and discussion that advance bitbake development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 19 Jun 2015 11:25:58 -0000 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 7bit Currently if the fakeworker failes to start the output from bitbake is confusing. Improve the error handling to give a clear indication of what failed. Patch from Chris Larson. Signed-off-by: Richard Purdie diff --git a/bitbake/lib/bb/runqueue.py b/bitbake/lib/bb/runqueue.py index 52bb12f..752fc3f3 100644 --- a/bitbake/lib/bb/runqueue.py +++ b/bitbake/lib/bb/runqueue.py @@ -1626,7 +1626,12 @@ class RunQueueExecuteTasks(RunQueueExecute): taskdep = self.rqdata.dataCache.task_deps[fn] if 'fakeroot' in taskdep and taskname in taskdep['fakeroot'] and not self.cooker.configuration.dry_run: if not self.rq.fakeworker: - self.rq.start_fakeworker(self) + try: + self.rq.start_fakeworker(self) + except OSError as exc: + logger.critical("Failed to spawn fakeroot worker to run %s:%s: %s" % (fn, taskname, str(exc))) + self.rq.state = runQueueFailed + return True self.rq.fakeworker.stdin.write("" + pickle.dumps((fn, task, taskname, False, self.cooker.collection.get_file_appends(fn), taskdepdata)) + "") self.rq.fakeworker.stdin.flush() else: