From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by yocto-www.yoctoproject.org (Postfix, from userid 118) id B4099E00978; Fri, 24 Jul 2015 09:22:46 -0700 (PDT) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on yocto-www.yoctoproject.org X-Spam-Level: X-Spam-Status: No, score=-6.9 required=5.0 tests=BAYES_00,RCVD_IN_DNSWL_HI autolearn=ham version=3.3.1 X-Spam-HAM-Report: * -5.0 RCVD_IN_DNSWL_HI RBL: Sender listed at http://www.dnswl.org/, high * trust * [134.134.136.65 listed in list.dnswl.org] * -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% * [score: 0.0000] Received: from mga03.intel.com (mga03.intel.com [134.134.136.65]) by yocto-www.yoctoproject.org (Postfix) with ESMTP id 04C0BE00942 for ; Fri, 24 Jul 2015 09:22:45 -0700 (PDT) Received: from orsmga001.jf.intel.com ([10.7.209.18]) by orsmga103.jf.intel.com with ESMTP; 24 Jul 2015 09:22:45 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.15,539,1432623600"; d="scan'208";a="734935718" Received: from linux.intel.com ([10.23.219.25]) by orsmga001.jf.intel.com with ESMTP; 24 Jul 2015 09:22:45 -0700 Received: from linux.intel.com (vmed.fi.intel.com [10.237.72.65]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by linux.intel.com (Postfix) with ESMTP id C8D3F6A4005; Fri, 24 Jul 2015 09:21:59 -0700 (PDT) Date: Fri, 24 Jul 2015 19:22:38 +0300 From: Ed Bartosh To: "Damian, Alexandru" Message-ID: <20150724162238.GA11956@linux.intel.com> References: <20150710144844.GA14439@linux.intel.com> <55A3EBB9.5060109@intel.com> <20150714130636.GA25220@linux.intel.com> <20150714135220.GC25220@linux.intel.com> MIME-Version: 1.0 In-Reply-To: <20150714135220.GC25220@linux.intel.com> Organization: Intel Finland Oy - BIC 0357606-4 - Westendinkatu 7, 02160 Espoo User-Agent: Mutt/1.5.21 (2010-09-15) Cc: "toaster@yoctoproject.org" Subject: Re: [review-request] ed/toaster/misc X-BeenThere: toaster@yoctoproject.org X-Mailman-Version: 2.1.13 Precedence: list Reply-To: ed.bartosh@linux.intel.com List-Id: Web based interface for BitBake List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 24 Jul 2015 16:22:46 -0000 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline On Tue, Jul 14, 2015 at 04:52:20PM +0300, Ed Bartosh wrote: > On Tue, Jul 14, 2015 at 02:37:27PM +0100, Damian, Alexandru wrote: > > Yep, the original code was about "cwd". Also, I think now that the logging > > messages really help, what if we turn them on with the lowest priority > > possible ? > Uncommented them. Please review. > Added implementation of [YOCTO #7571] to the branch. Please, review. > > Cheers, > > Alex > > > > On Tue, Jul 14, 2015 at 2:06 PM, Ed Bartosh > > wrote: > > > > > Hi Michael, > > > > > > Thanks for the review. > > > > > > ... > > > > > > > While you're in localhostbecontroller > > > > > > > > We could also get rid of > > > > > > > > def _shellcmd(self, command, cwd = None): > > > > if cwd is None: > > > > cwd = self.be.sourcedir > > > > > > > > #logger.debug("lbc_shellcmmd: (%s) %s" % (cwd, command)) > > > > p = subprocess.Popen(command, cwd = cwd, shell=True, > > > > stdout=subprocess.PIPE, stderr=subprocess.PIPE) > > > > (out,err) = p.communicate() > > > > p.wait() > > > > if p.returncode: > > > > if len(err) == 0: > > > > err = "command: %s \n%s" % (command, out) > > > > else: > > > > err = "command: %s \n%s" % (command, err) > > > > #logger.warn("localhostbecontroller: shellcmd error %s" % > > > err) > > > > raise ShellCmdException(err) > > > > else: > > > > #logger.debug("localhostbecontroller: shellcmd success") > > > > return out > > > > > > > > > > > > I believe with: > > > > > > > > subprocess.check_output > > > > > > > Yep, I've noticed this too. I think the reason for not using > > > check_output was that it doesn't have cwd parameter. > > > > > > I'm planning to generalize build controllers, so I'll make much more > > > changes to this code anyway. Hopefully it will be for good :) > > > Just discussed this with Alex and he seems to be ok with this. > > > > > > -- > > > Regards, > > > Ed > > > -- > > > _______________________________________________ > > > toaster mailing list > > > toaster@yoctoproject.org > > > https://lists.yoctoproject.org/listinfo/toaster > > > > > > > > > > > -- > > Alex Damian > > Yocto Project > > SSG / OTC > > -- > -- > Regards, > Ed > -- > _______________________________________________ > toaster mailing list > toaster@yoctoproject.org > https://lists.yoctoproject.org/listinfo/toaster -- -- Regards, Ed