From patchwork Sun Jun 10 15:44:58 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Yann E. MORIN" X-Patchwork-Id: 927377 Return-Path: X-Original-To: incoming-buildroot@patchwork.ozlabs.org Delivered-To: patchwork-incoming-buildroot@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (mailfrom) smtp.mailfrom=busybox.net (client-ip=140.211.166.138; helo=whitealder.osuosl.org; envelope-from=buildroot-bounces@busybox.net; receiver=) Authentication-Results: ozlabs.org; dmarc=none (p=none dis=none) header.from=free.fr Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.b="LDbugGdc"; dkim-atps=neutral Received: from whitealder.osuosl.org (smtp1.osuosl.org [140.211.166.138]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 413gT803SLz9rvt for ; Mon, 11 Jun 2018 01:45:15 +1000 (AEST) Received: from localhost (localhost [127.0.0.1]) by whitealder.osuosl.org (Postfix) with ESMTP id 3D62E867C6; Sun, 10 Jun 2018 15:45:13 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from whitealder.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id CN+uJDOdBih3; Sun, 10 Jun 2018 15:45:07 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by whitealder.osuosl.org (Postfix) with ESMTP id 5645C867E9; Sun, 10 Jun 2018 15:45:05 +0000 (UTC) X-Original-To: buildroot@lists.busybox.net Delivered-To: buildroot@osuosl.org Received: from fraxinus.osuosl.org (smtp4.osuosl.org [140.211.166.137]) by ash.osuosl.org (Postfix) with ESMTP id 1D0611BFF07 for ; Sun, 10 Jun 2018 15:45:04 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by fraxinus.osuosl.org (Postfix) with ESMTP id 1A605861C7 for ; Sun, 10 Jun 2018 15:45:04 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from fraxinus.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 1r4YK-XT53xn for ; Sun, 10 Jun 2018 15:45:03 +0000 (UTC) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.6 Received: from mail-wr0-f194.google.com (mail-wr0-f194.google.com [209.85.128.194]) by fraxinus.osuosl.org (Postfix) with ESMTPS id 5BB22860AE for ; Sun, 10 Jun 2018 15:45:03 +0000 (UTC) Received: by mail-wr0-f194.google.com with SMTP id h10-v6so17828653wrq.8 for ; Sun, 10 Jun 2018 08:45:03 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:cc:subject:date:message-id:in-reply-to:references; bh=VA2rOlsfQSF9JrJxyliV57KoQ7Rsu7J+foEPhvlV8eY=; b=LDbugGdc7hahM3ENEBJfuIgC3BNUgxG/xPKOkqgpEpIMUB9TR9G2zuOzrWOQp9MYUc 1S/LW+2LmYEdPKRr0kE0JMHHU4ZtV4ExcJjBeSDP/vJUOKV05OyP34Sda/QXKpevHyja QrR3Bbf73+yQBtL7JeZGNEk3105ZnCwpviX6sJ4+EpsLy5WFtvrP9DtfwpebWxX0YnY7 HoI2Gc6Wp/StPzHK24gyO3djMUKgJ2R4fGOPp0OvkeweeSRfUhdhHX7RNE1Sx+4lHXi3 oPX4V1vxEb0GU/t8lTNuFXb4K2zQXtQt4h9RfyAa+vvedmD0nbBvHvxz7QZOcYkGwLGY BQFg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:cc:subject:date:message-id :in-reply-to:references; bh=VA2rOlsfQSF9JrJxyliV57KoQ7Rsu7J+foEPhvlV8eY=; b=F6zzww94884SRf1IP4ebo/T8+mNFkRrqJTNtcFzQHxUnb3LSdqmRRoQWqrUzYaQ6Wm GmbTUn5tS9LOMdsfybXVKio0HvNQfOq40G6HPXAMg61GpvsisxYTikwPGoWVr+6UwhPt 7U8HRcZj0btnUJFjw+1h4dZHwpJfKQc6hZZXgEivMrgNPwletHwEcNNN648uPtVVVU/v xjhNbE9b57iuh1g59bxFb5LxB6+9L4049gFntIiusWUx29Glqa51fYiWbFN1Z1jEcfq2 VTy8lNWDKiIdBEQBxTuqlh3HPeYDVyDq74xW5hB7TBRy//EZMN5fMFq5HM5CEl8Gfvnz j/2A== X-Gm-Message-State: APt69E2586FfAMSgzDRrRrzdSDEARIiZ22H1edzflAN2bNX4ovsEVuTg R/uhksB67kim7PNf0Ya0080xVg== X-Google-Smtp-Source: ADUXVKImOfCZx2i7BgtJCkQDzSXBiHx6kF1XUfg0rY+XT7RKpinOHO0eVAK/DA/9T3kPQCFU5m+l2g== X-Received: by 2002:adf:dfc2:: with SMTP id q2-v6mr10203500wrn.113.1528645501381; Sun, 10 Jun 2018 08:45:01 -0700 (PDT) Received: from scaer.bzh.lan (2a01cb0886107300951dbdf04211ad4d.ipv6.abo.wanadoo.fr. [2a01:cb08:8610:7300:951d:bdf0:4211:ad4d]) by smtp.gmail.com with ESMTPSA id q17-v6sm32927125wrs.5.2018.06.10.08.45.00 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sun, 10 Jun 2018 08:45:00 -0700 (PDT) From: "Yann E. MORIN" To: buildroot@buildroot.org Date: Sun, 10 Jun 2018 17:44:58 +0200 Message-Id: <720ecb41c6c51f66f6b4dda7663c1e16edb2fabb.1528645489.git.yann.morin.1998@free.fr> X-Mailer: git-send-email 2.14.1 In-Reply-To: References: Subject: [Buildroot] [PATCH 2/2 v3] support/docker: use the distro-provided flake8 X-BeenThere: buildroot@busybox.net X-Mailman-Version: 2.1.24 Precedence: list List-Id: Discussion and development of buildroot List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: "Yann E. MORIN" , Ricardo Martincoski MIME-Version: 1.0 Errors-To: buildroot-bounces@busybox.net Sender: "buildroot" Currently, we install flake8 and its dependencies via pip. We tried to be reproducible by pinning the version of those python packages, but we did forget quite a few of them, and thus some dependencies for flake8 are installed as uncontrolled versions. Furthermore, before we install flake8 and its dependencies, we forcibly update pip, setuptools, and wheels packages to their latest versions. This explicitly breaks reproducibility. While we could enforce a specific version of all those packages and still grab them from PyPI, we can simply grab them from the distribution-provided packages instead. Since we're using a pinned version of stretch, this already guarantees we'll reproducibly get the same versions over and over again. Besides, we just need to list flake8 as a package to install to automatically get all its dependencies (again, in a reproducible way). This has the slight unfortunate drawback of downgrading flake8 to version 3.2.1, from version 3.5.0, as well as downgrading a few of flake8's dependencies, as noticed by Ricardo: http://lists.busybox.net/pipermail/buildroot/2018-May/222376.html However, as Ricardo said, there isn't "any serious limitation of this old version, the release notes for a version in the between mentions 'Dramatically improve the performance' but we have a limited number of scripts and running on Gitlab for all of them still takes less than 5 minutes". Signed-off-by: "Yann E. MORIN" Cc: Ricardo Martincoski Acked-by: Ricardo Martincoski --- Changes v1 -> v2: - improve commit log to mention downgrading of flake8 (Ricardo) - correctly use python2's version of flake8, not python3's (Ricardo) - fix typoes (Ricardo) --- support/docker/Dockerfile | 10 +--------- 1 file changed, 1 insertion(+), 9 deletions(-) diff --git a/support/docker/Dockerfile b/support/docker/Dockerfile index bebd861dc1..36cd3b28a4 100644 --- a/support/docker/Dockerfile +++ b/support/docker/Dockerfile @@ -36,9 +36,9 @@ RUN apt-get install -y --no-install-recommends \ libncurses5-dev \ locales \ mercurial \ + python-flake8 \ python-nose2 \ python-pexpect \ - python-pip \ qemu-system-arm \ qemu-system-x86 \ rsync \ @@ -49,14 +49,6 @@ RUN apt-get install -y --no-install-recommends \ apt-get -y autoremove && \ apt-get -y clean -# For check-flake8 -RUN python -m pip install --upgrade pip setuptools wheel && \ - pip install -q \ - flake8==3.5.0 \ - mccabe==0.6.1 \ - pycodestyle==2.3.1 \ - pyflakes==1.6.0 - # To be able to generate a toolchain with locales, enable one UTF-8 locale RUN sed -i 's/# \(en_US.UTF-8\)/\1/' /etc/locale.gen && \ /usr/sbin/locale-gen