From mboxrd@z Thu Jan 1 00:00:00 1970 From: Ricardo Wurmus Subject: Re: Internship on Improve the user experience for the "guix package" command line tool (Outreachy) Date: Tue, 20 Mar 2018 15:44:51 +0100 Message-ID: <87in9qdcws.fsf@elephly.net> References: <87fu5pch36.fsf@elephly.net> <87h8pfy56s.fsf@elephly.net> <87tvtdthda.fsf@elephly.net> <87k1u8uccr.fsf@elephly.net> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:56703) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1eyIVc-0005cR-0T for guix-devel@gnu.org; Tue, 20 Mar 2018 10:45:08 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1eyIVY-00013k-Lk for guix-devel@gnu.org; Tue, 20 Mar 2018 10:45:04 -0400 Received: from sender-of-o51.zoho.com ([135.84.80.216]:21038) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1eyIVY-00011n-A5 for guix-devel@gnu.org; Tue, 20 Mar 2018 10:45:00 -0400 In-reply-to: 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: Vijayalakshmi Vedantham Cc: guix-devel@gnu.org --=-=-= Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Hi Vijayalakshmi, > I created a patch file for the package definition of python-logwrap that > I'm including here. I'm a little unsure if my patch is right because my .= / > pre-inst-env.in guix build r-abbyyR fails with some error. Have you been able to build Guix already and try building the package using =E2=80=9C./pre-inst-env guix build=E2=80=9D? I looked over your patch for python-logwrap. I had to append =E2=80=9C.zip= =E2=80=9D because Pypi didn=E2=80=99t have a =E2=80=9C.tar.gz=E2=80=9D file for the s= ources, so the uri field now is: (pypi-uri "logwrap" version ".zip") Having a zip archive requires the =E2=80=9Cunzip=E2=80=9D command during th= e =E2=80=9Cunpack=E2=80=9D phase, so I also added =E2=80=9Cunzip=E2=80=9D to the native-inputs field. I also noticed that the sources include files that were generated with Cython. Instead of reusing those, we build them from source. Luckily all we have to do in this case is to add =E2=80=9Cpython-cython=E2=80=9D to= the native-inputs field. Finally, the tests. At first the tests wouldn=E2=80=99t run. So I looked u= p the error message online and found that I need to use =E2=80=9Cpython-pytest-ru= nner=E2=80=9D in addition to =E2=80=9Cpython-pytest=E2=80=9D. This allows the tests to r= un up to a point until it wants to do coverage tests. For those I needed to add =E2=80=9Cpython-pytest-cov=E2=80=9D. I changed the description, because I think it wasn=E2=80=99t quite correct. Attached is my modified version. What do you think? Do you have any questions about my changes? --=-=-= Content-Type: text/x-patch; charset=utf-8; name=0001-gnu-Add-python-logwrap.patch Content-Disposition: inline; filename=0001-gnu-Add-python-logwrap.patch Content-Transfer-Encoding: quoted-printable >From 520d4cd8d9246ec4a1601906404194610f3905bd Mon Sep 17 00:00:00 2001 From: Vijayalakshmi Date: Mon, 19 Mar 2018 22:20:25 +0530 Subject: [PATCH] gnu: Add python-logwrap. * gnu/packages/python.scm (python-logwrap): New variable. Co-authored-by: Ricardo Wurmus --- gnu/packages/python.scm | 30 +++++++++++++++++++++++++++++- 1 file changed, 29 insertions(+), 1 deletion(-) diff --git a/gnu/packages/python.scm b/gnu/packages/python.scm index 76b5460f6..ff250a1ea 100644 --- a/gnu/packages/python.scm +++ b/gnu/packages/python.scm @@ -47,7 +47,8 @@ ;;; Copyright =C2=A9 2017 Brendan Tildesley ;;; Copyright =C2=A9 2018 Ethan R. Jones -;;; +;;; Copyright =C2=A9 2018 Vijayalakshmi Vedantham + ;;; This file is part of GNU Guix. ;;; ;;; GNU Guix is free software; you can redistribute it and/or modify it @@ -524,6 +525,33 @@ pidof, tty, taskset, pmap.") planar geometric objects. It is based on the @code{GEOS} library.") (license license:bsd-3))) =20 +(define-public python-logwrap + (package + (name "python-logwrap") + (version "3.2.1") + (source + (origin + (method url-fetch) + (uri (pypi-uri "logwrap" version ".zip")) + (sha256 + (base32 + "1d2k0hvpbi51vl410y8fbs5m0nxnlh2k7gr2nrh3k81ibhzscsra")))) + (build-system python-build-system) + (propagated-inputs + `(("python-six" ,python-six) + ("python-typing" ,python-typing))) + (native-inputs + `(("unzip" ,unzip) + ("python-cython" ,python-cython) + ("python-pytest" ,python-pytest) + ("python-pytest-cov" ,python-pytest-cov) + ("python-pytest-runner" ,python-pytest-runner))) + (home-page "https://github.com/penguinolog/logwrap") + (synopsis "Decorator for logging function arguments") + (description "This package provides a decorator to log function argume= nts +and function call return values in a human-readable way.") + (license license:asl2.0))) + (define-public python2-shapely (package-with-python2 python-shapely)) =20 --=20 2.16.2 --=-=-= Content-Type: text/plain -- Ricardo GPG: BCA6 89B6 3655 3801 C3C6 2150 197A 5888 235F ACAC https://elephly.net --=-=-=--