From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by yocto-www.yoctoproject.org (Postfix, from userid 118) id 94C65E0095C; Tue, 14 Jul 2015 09:55:05 -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=-2.6 required=5.0 tests=BAYES_00,RCVD_IN_DNSWL_LOW autolearn=ham version=3.3.1 X-Spam-HAM-Report: * -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% * [score: 0.0000] * -0.7 RCVD_IN_DNSWL_LOW RBL: Sender listed at http://www.dnswl.org/, low * trust * [209.85.212.175 listed in list.dnswl.org] Received: from mail-wi0-f175.google.com (mail-wi0-f175.google.com [209.85.212.175]) by yocto-www.yoctoproject.org (Postfix) with ESMTP id CEE30E0086D for ; Tue, 14 Jul 2015 09:55:03 -0700 (PDT) Received: by wicmv11 with SMTP id mv11so19548380wic.1 for ; Tue, 14 Jul 2015 09:55:02 -0700 (PDT) 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 :subject:content-type:content-transfer-encoding; bh=uMcfjlgFLtbD3EkcQk9qW1DEYJs7r5+KThp/qMS3i9I=; b=SxSY0JAU+cwyha3Y+Y7t2NIbIcAnAQ0zs9np19AyUjI7d/H+lx1a5hr/Qat3c4Irpp HSRlse6H2q796O7rwOLL5I9KFBr16ylnTrjQOVMz4KOjhf+HhyYaOhigGnflc/BoL0ob 8kUAAqE68GU9YBS7abiu87/k8TiQKJgM/wwLPhrZysM4Ls8ghuVqOMNXQsFDFWnLBP/p SySkYba40w6PVoYT03xiQj4txxsJH7JtzKLOfp8RKcKoqd4BJsDZnmOurNfT+Jo98Z7W FYDrOIE0AdDWvzH8zH00dr34RsPDcR+0hU4ufDgPSB86gWC3aHm+PnuhqB8HxHo7h6l1 KGzg== X-Gm-Message-State: ALoCoQnyz02Z3IG2mrSqAH0IEHaMCu4dzg5YNqtKrfRzysbRQmOMaFfuuGDdbdMl+x3nJ28MqphB X-Received: by 10.180.99.196 with SMTP id es4mr34777505wib.57.1436892902412; Tue, 14 Jul 2015 09:55:02 -0700 (PDT) Received: from [192.168.2.178] ([83.217.123.106]) by smtp.googlemail.com with ESMTPSA id ea2sm21747016wib.22.2015.07.14.09.55.01 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 14 Jul 2015 09:55:01 -0700 (PDT) Message-ID: <55A53EE5.4040906@intel.com> Date: Tue, 14 Jul 2015 17:55:01 +0100 From: Michael Wood User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:31.0) Gecko/20100101 Thunderbird/31.7.0 MIME-Version: 1.0 To: "toaster@yoctoproject.org" Subject: [review-request] michaelw/toastertable/sorting-cache-hit 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: Tue, 14 Jul 2015 16:55:05 -0000 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit poky-contrib branch: michaelw/toastertable/sorting-cache-hit commit 548636b2c9a7be82bc098596c4e08ab156863e5b Author: Michael Wood Date: Tue Jul 14 17:42:56 2015 +0100 bitbake: toastergui: Toastertables don't replace dash in cache key The dash character was being stripped from the cache key when we sanitise it for the memcache backend. This meant that we were getting a false hit on the cache and returning non descending results which are indicated by the dash prefix on the field name. Signed-off-by: Michael Wood diff --git a/bitbake/lib/toaster/toastergui/widgets.py b/bitbake/lib/toaster/toastergui/widgets.py index 5f6b47b..0885402 100644 --- a/bitbake/lib/toaster/toastergui/widgets.py +++ b/bitbake/lib/toaster/toastergui/widgets.py @@ -252,8 +252,8 @@ class ToasterTable(TemplateView): for key, val in kwargs.iteritems(): cache_name = cache_name + str(key) + str(val) - # No special chars allowed in the cache name - cache_name = re.sub(r'[^A-Za-z0-9]', "", cache_name) + # No special chars allowed in the cache name apart from dash + cache_name = re.sub(r'[^A-Za-z0-9-]', "", cache_name) data = cache.get(cache_name) if data: