From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by yocto-www.yoctoproject.org (Postfix, from userid 118) id 9CD92E0087C; Fri, 6 Mar 2015 03:28:56 -0800 (PST) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on yocto-www.yoctoproject.org X-Spam-Level: X-Spam-Status: No, score=-2.6 required=5.0 tests=BAYES_00,RCVD_IN_DNSWL_LOW autolearn=ham version=3.3.1 X-Spam-HAM-Report: * -0.7 RCVD_IN_DNSWL_LOW RBL: Sender listed at http://www.dnswl.org/, low * trust * [74.125.82.169 listed in list.dnswl.org] * -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% * [score: 0.0000] Received: from mail-we0-f169.google.com (mail-we0-f169.google.com [74.125.82.169]) by yocto-www.yoctoproject.org (Postfix) with ESMTP id AF519E0083A for ; Fri, 6 Mar 2015 03:28:50 -0800 (PST) Received: by wevk48 with SMTP id k48so12202161wev.5 for ; Fri, 06 Mar 2015 03:28:50 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:message-id:date:from:user-agent:mime-version:to :cc:subject:references:in-reply-to:content-type :content-transfer-encoding; bh=knwNr6CGu7/Yge0cPojGqM08vczGZTRIHQD2g3gO/84=; b=HIzCHRIUjAK+B34eHrn5TKqeDa6+JPnY6mRh1/IO8IKIH+PM4+/edGaZYROo236bhY 3Hyrshah/VwgTORKSVcOMjoQAqrv9U/oAYoWRP0lDcoRzDhdD4xsAyoMzUvxlNbB1T1p rwwTzM8pOQcu6BQ3rNV3xqlyCV6TEHC7eS1CT/7P5HEbqB7uFgoSLr7VYL0fjjZuLGbk J61HJVk2dM16PJZdu6LCLurLD36bKBGUOGR0pSzqXV7dzlmFLlKV74xP0951nDpbR26s DlK7+U6JgvVzjsZuSJR9H/r552z70T3KtlOFgWrSYPCAb58lGYKcQ1P5L8MjA/GA/X/U yrUg== X-Gm-Message-State: ALoCoQk/3BJUrMwmRthguuu7QerrE70eI9YtqhfyfBHVZ3IRXdw08HBuq3P7vlAUn7sEuDEg1yAv X-Received: by 10.194.5.37 with SMTP id p5mr28766051wjp.20.1425641330110; Fri, 06 Mar 2015 03:28:50 -0800 (PST) Received: from [192.168.0.11] (cpc73680-dals20-2-0-cust304.20-2.cable.virginm.net. [80.194.17.49]) by mx.google.com with ESMTPSA id j7sm1850180wix.4.2015.03.06.03.28.49 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 06 Mar 2015 03:28:49 -0800 (PST) Message-ID: <54F98F71.7010900@intel.com> Date: Fri, 06 Mar 2015 11:28:49 +0000 From: Michael Wood User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:31.0) Gecko/20100101 Thunderbird/31.4.0 MIME-Version: 1.0 To: "Barros Pena, Belen" , "Lerner, David M (Wind River)" References: <011977994B5AE74ABA2BD08E983BAAABBC6BDC0A@ALA-MBA.corp.ad.wrs.com> In-Reply-To: Cc: "toaster@yoctoproject.org" Subject: Re: [review-request] 7191 Version3 format shaid on all layers page X-BeenThere: toaster@yoctoproject.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: Web based interface for BitBake List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 06 Mar 2015 11:28:56 -0000 Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 8bit On 05/03/15 18:13, Barros Pena, Belen wrote: > On 05/03/2015 16:07, "Lerner, Dave" wrote: > >> http://git.yoctoproject.org/cgit.cgi/poky-contrib/ >> >> Version 3: Implementing the improvement from Michael, and Belen's >> clarification on help bubble. + should be + Thanks > The UI is working as designed. > > Thanks! > > Belén > >> >> Retests >> -------- >> Tested with manually entered revision strings >> 1234567890123456789012345678901234567890 (with button) >> and >> 12 4567890123456789012345678901234567890 (without button) >> >> HTML validator >> -------------- >> 3 errors with no relation to the changed code >> >> >> V2 vs V3 diff >> ------------- >> --- a/bitbake/lib/toaster/toastergui/templates/layers.html >> +++ b/bitbake/lib/toaster/toastergui/templates/layers.html >> @@ -52,24 +52,15 @@ >> {% endif %} >> >> >> - {% if o.branch %} >> - {% if o.branch|is_shaid %} >> + {% with vcs_ref=o.get_vcs_reference %} >> + {% if vcs_ref|is_shaid %} >> > title="Yo >> - {% endif %} >> + {% else %} >> + {{vcs_ref}} >> + {% endif %} >> + {% endwith %} >> >> >> {% with ods=o.dependencies.all%} >> diff --git a/bitbake/lib/toaster/toastergui/templatetags/projecttags.py >> b/bitbak >> index 61a01ca..587a6da 100644 >> --- a/bitbake/lib/toaster/toastergui/templatetags/projecttags.py >> +++ b/bitbake/lib/toaster/toastergui/templatetags/projecttags.py >> @@ -304,7 +304,7 @@ def is_shaid(text): >> int(text, 16) >> if len(text) == 40: >> return True >> - return False >> + return False >> except: >> return False >> >>> -----Original Message----- >>> From: Lerner, Dave >>> Sent: Wednesday, March 04, 2015 10:44 AM >>> To: WOOD, MICHAEL >>> Cc: Barros Pena, Belen (belen.barros.pena@intel.com) >>> Subject: RE: [review-request] 7191 Version2 format shaid on all layers >>> page >>> >>> Hi Michael, >>> >>> I didn't change the original template use of >>> o.branch/o.upt_branch.name. The original >>> template only provided the help icon on the up_branch clause, that is, >>> the not o.branch >>> clause. What do you use to determine the difference if you have >>> abstracted the two into >>> one field? Can you send me your suggestion? >>> -Dave >>> My patch >>> {% if o.branch %} >>> - {{o.branch}} >>> + {% if o.branch|is_shaid %} >>> + >>> + {{o.branch|truncatechars:10}} >>> + >>> + {% else %} >>> + {{o.branch}} >>> + {% endif %} >>> {% else %} >>> - {{o.up_branch.name}} >>> + {% if o.branch|is_shaid %} >>> + >>> + {{o.up_branch.name|truncatechars:10}} >>> + >>> + {% else %} >>> + {{o.up_branch.name}} >>> + {% endif %} >>> >> title="Your >>> builds will use the tip of t >>> {% endif %} >>> >>>> -----Original Message----- >>>> From: Michael Wood [mailto:michael.g.wood@intel.com] >>>> Sent: Wednesday, March 04, 2015 9:58 AM >>>> To: BARROS PENA, BELEN; Lerner, Dave; DAMIAN, ALEXANDRU >>>> Cc: toaster@yoctoproject.org >>>> Subject: Re: [review-request] 7191 Version2 format shaid on all >>> layers page >>>> Hi Dave, >>>> >>>> Only one thing, we have renamed the branch column to "reference" >>> because >>>> the database confusingly splits up the vcs reference into, branch, >>>> commit, upstream branch etc etc >>>> >>>> We have abstracted trying to work out which to display via the >>> function >>>> "get_vcs_reference" >>>> >>>> So if you switch >>>> + {% if o.branch|is_shaid %} >>>> to >>>> + {% if o.get_vcs_reference|is_shaid %} >>>> >>>> and you can then also remove the check to see if which kind of >>> reference >>>> to display >>>> >>>> + {% else %} >>>> + {{o.up_branch.name}} >>>> >>>> It's a bit confusing so if you'd like me just to push a patch on top >>>> then you can squash it into yours. >>>> >>>> Michael >>>> >>>> >>>> On 04/03/15 12:26, Barros Pena, Belen wrote: >>>>> On 03/03/2015 22:56, "Lerner, Dave" >>> wrote: >>> http://git.yoctoproject.org/cgit/cgit.cgi/poky-contrib/log/?h=lerner/laye >>> r >>>>>> s_commitfield_7191 >>>>>> >>>>>> 7191 - If field looks like a commit SHAID(hex and 40 digits), >>> truncate >>>>>> field as button label, and show full SHAID when button depressed. >>>>> This seems to be working for me. >>>>> >>>>> Thanks! >>>>> >>>>> Belén >>>>> >>>>>> Dave Lerner >>>>>>