From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from localhost (localhost [127.0.0.1]) by arlo.cworth.org (Postfix) with ESMTP id 7511E6DE0ED9 for ; Thu, 21 Nov 2019 19:03:12 -0800 (PST) X-Virus-Scanned: Debian amavisd-new at cworth.org X-Spam-Flag: NO X-Spam-Score: -0.062 X-Spam-Level: X-Spam-Status: No, score=-0.062 tagged_above=-999 required=5 tests=[AWL=-0.061, SPF_PASS=-0.001] autolearn=disabled Received: from arlo.cworth.org ([127.0.0.1]) by localhost (arlo.cworth.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id qVCwgdJRepWO for ; Thu, 21 Nov 2019 19:03:11 -0800 (PST) Received: from fethera.tethera.net (fethera.tethera.net [198.245.60.197]) by arlo.cworth.org (Postfix) with ESMTPS id 289696DE0A43 for ; Thu, 21 Nov 2019 19:03:10 -0800 (PST) Received: from remotemail by fethera.tethera.net with local (Exim 4.89) (envelope-from ) id 1iXzDv-0007oT-E2; Thu, 21 Nov 2019 22:03:07 -0500 Received: (nullmailer pid 482595 invoked by uid 1000); Fri, 22 Nov 2019 03:03:06 -0000 From: David Bremner To: Tomi Ollila , notmuch@notmuchmail.org Subject: Re: [PATCH 4/5] tests: run python-cffi tests In-Reply-To: References: <20191104013927.17037-1-david@tethera.net> <20191104013927.17037-5-david@tethera.net> <87h83hsq4o.fsf@tethera.net> <8736exx23i.fsf@tethera.net> Date: Thu, 21 Nov 2019 23:03:06 -0400 Message-ID: <8736eg8vf9.fsf@tethera.net> MIME-Version: 1.0 Content-Type: text/plain X-BeenThere: notmuch@notmuchmail.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "Use and development of the notmuch mail system." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 22 Nov 2019 03:03:12 -0000 Tomi Ollila writes: > On Fri, Nov 08 2019, David Bremner wrote: > >> Tomi Ollila writes: >> >>> >>> Right -- just that pytest-3 may not be available -- to iterate (tested)... >>> >>> if ${NOTMUCH_PYTHON} -m pytest -c $conf --version >/dev/null 2>&1; then >>> >> >> The problem with this is that it might pass if pytest is only installed >> for python2. > > What is the minimum python3 version supported -- In the previous email thread all > references show python 3.7.... > > Anyway, in that wip/cffi "branch" commit 97caf16c15d (check for python cffi module) > > could also include check for minimum python version, e.g. > > +printf "Checking for python 3 cffi... " > +if "${NOTMUCH_PYTHON}" -c 'import sys,cffi; assert sys.version_info >= (3,7)' 2>/dev/null; then > + printf "Yes.\n" > + have_python3_cffi=1 > +else > + printf "No.\n" > + have_python3_cffi=0 > +fi I (force) pushed an updated version of wip/cffi (8d1f30cb) with several changes along those lines to the configure / build / test scaffolding. In particular running the tests from the notmuch suite doesn't require pytest-cov anymore, and pytest and cffi are both checked for only if python3 is found. d