From mboxrd@z Thu Jan 1 00:00:00 1970 From: Efraim Flashner Subject: Re: [PATCH v2 03/10] gnu: Add python-pytest-pep8. Date: Sun, 24 Apr 2016 20:04:05 +0300 Message-ID: <20160424170405.GA12480@debian-netbook> References: <1461244921-7412-1-git-send-email-donttrustben@gmail.com> <1461503184-8841-1-git-send-email-donttrustben@gmail.com> <1461503184-8841-4-git-send-email-donttrustben@gmail.com> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="n8g4imXOkfNTN/H1" Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:39865) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1auNSB-0001il-QN for Guix-devel@gnu.org; Sun, 24 Apr 2016 13:04:17 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1auNS6-0004N3-Tk for Guix-devel@gnu.org; Sun, 24 Apr 2016 13:04:15 -0400 Received: from flashner.co.il ([178.62.234.194]:41840) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1auNS6-0004LP-Ig for Guix-devel@gnu.org; Sun, 24 Apr 2016 13:04:10 -0400 Content-Disposition: inline In-Reply-To: <1461503184-8841-4-git-send-email-donttrustben@gmail.com> List-Id: "Development of GNU Guix and the GNU System distribution." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-devel-bounces+gcggd-guix-devel=m.gmane.org@gnu.org Sender: "Guix-devel" To: Ben Woodcroft Cc: Guix-devel@gnu.org --n8g4imXOkfNTN/H1 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Sun, Apr 24, 2016 at 11:06:17PM +1000, Ben Woodcroft wrote: > * gnu/packages/python.scm (python-pytest-pep8, python2-pytest-pep8): New > variables. > --- > gnu/packages/python.scm | 60 +++++++++++++++++++++++++++++++++++++++++++= ++++++ > 1 file changed, 60 insertions(+) >=20 > diff --git a/gnu/packages/python.scm b/gnu/packages/python.scm > index c07dae6..b1a4969 100644 > --- a/gnu/packages/python.scm > +++ b/gnu/packages/python.scm > @@ -8714,6 +8714,66 @@ development version of CPython that are not availa= ble in older releases.") > (native-inputs > `(("python2-setuptools" ,python2-setuptools)))))) > =20 > +(define-public python-pytest-pep8 > + (package > + (name "python-pytest-pep8") > + (version "1.0.6") > + (source > + (origin > + (method url-fetch) > + (uri (pypi-uri "pytest-pep8" version)) > + (sha256 > + (base32 > + "06032agzhw1i9d9qlhfblnl3dw5hcyxhagn7b120zhrszbjzfbh3")))) > + (build-system python-build-system) > + (arguments > + `(#:phases > + (modify-phases %standard-phases > + (add-before 'build 'remove-failing-test > + ;; Ignore the known test failure. > + ;; https://bitbucket.org/pytest-dev/pytest-pep8/issues/8/test= -failure > + (lambda _ > + (substitute* "test_pep8.py" > + (("^def test_ok_verbose") "def dont_run")) > + #t)) > + (add-after 'install 'post-install-check > + ;; 'setup.py test' does not run tests > + (lambda* (#:key inputs outputs #:allow-other-keys) > + (let ((out (assoc-ref outputs "out"))) > + (setenv "PYTHONPATH" > + (string-append > + (getenv "PYTHONPATH") > + ":" > + out > + "/lib/python" some of the previous lines should be combined into one line > + (string-take (string-take-right > + (assoc-ref inputs "python") 5) 3) > + "/site-packages")) > + (zero? > + (system* > + (string-append out "/bin/py.test") "test_pep8.py"))))))= )) > + (propagated-inputs > + `(("python-pytest-cache", python-pytest-cache) > + ("python-pytest" ,python-pytest) > + ("python-pep8" ,python-pep8))) Are you sure all of these need to be propagated? > + (home-page "https://bitbucket.org/pytest-dev/pytest-pep8") > + (synopsis "Pytest plugin to check PEP8 requirements") > + (description > + "Pytest-pep8 is a py.test plugin for efficiently checking complianc= e to > +the PEP8 style guide. If you type @code{py.test --pep8} every file endi= ng in > +@code{.py} will be discovered and PEP8-checked, starting from the comman= d line > +arguments.") > + (license license:expat) > + (properties `((python2-variant . ,(delay python2-pytest-pep8)))))) > + > +(define-public python2-pytest-pep8 > + (let ((base (package-with-python2 > + (strip-python2-variant python-pytest-pep8)))) > + (package > + (inherit base) > + (native-inputs > + `(("python2-setuptools" ,python2-setuptools)))))) > + > (define-public python-cysignals > (package > (name "python-cysignals") > --=20 > 2.5.0 >=20 >=20 --=20 Efraim Flashner =D7=90=D7=A4=D7=A8=D7=99=D7=9D = =D7=A4=D7=9C=D7=A9=D7=A0=D7=A8 GPG key =3D A28B F40C 3E55 1372 662D 14F7 41AA E7DC CA3D 8351 Confidentiality cannot be guaranteed on emails sent or received unencrypted --n8g4imXOkfNTN/H1 Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v2 iQIcBAEBCgAGBQJXHPyBAAoJEPTB05F+rO6TSHoP/0DFkdoY2PptNUNoqZmsT7Ef Ht1yvgKtiyVoeUZhY27kqaEyhLzxPzWQM2hWQPrpeC5seixv5XIQJ5cXxCLABGhQ YExSXt3drD7z4csKOKXQ90KSk12Acg2gCJ1A2bQAR9kkLVlmpHbXRU0KOJU3T+LU ZCVHS8bg95LSUOfCmytYZz6eANXrc1tZYazgpDTpfYYhuEyhlQunJyavbPnoEeJE K7pqvsyHlLwlHsj0wD5szvXjWZ4K9p5CchnrNwS9zUXOCFpdszFknNAJcKzucWbN QoJzrKAXV9cXaNIJzSmG2bI4ZUCPczsAcgnv9/N4WX6VC8hTQpBjxrpp8lh66Fxj MhunrDRYd4nshqlIp32MmKLnNxzQuzN23MDB+9L41KdZ1RC2mM0zB/jUz2uNe82/ Yq1CEQ7GLqNb60W4yy1zN1zNQqHXAz8RNsy5Xwk4sD+6dvvYyU34xwyPYL+hcDZ9 Y3GX70C28O0jqHEsiyOnbnLZghC/tWblA7uwupgfBMCMNV+8UrkMHM/tpnseHWEL +QQ2ZqMTax4PGgMNqS96d1dKwx4/M74S+F0kWJvJoi6jf6ncuVNl4axlr3ts5myN Bzi3CQv0ChTcGcxvkDtThrmrW8r158afymBYWF/sKODSGMHUNiTbZjEu9MxKXe5l HlN4QiQ6YApTrDMozXFO =Qcxr -----END PGP SIGNATURE----- --n8g4imXOkfNTN/H1--