From unknown Wed Jun 18 23:18:32 2025 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-Mailer: MIME-tools 5.509 (Entity 5.509) Content-Type: text/plain; charset=utf-8 From: bug#36543 <36543@debbugs.gnu.org> To: bug#36543 <36543@debbugs.gnu.org> Subject: Status: [PATCH] gnu: wireservice: New wireservice-package macro. Reply-To: bug#36543 <36543@debbugs.gnu.org> Date: Thu, 19 Jun 2025 06:18:32 +0000 retitle 36543 [PATCH] gnu: wireservice: New wireservice-package macro. reassign 36543 guix-patches submitter 36543 Pierre Langlois severity 36543 normal tag 36543 patch thanks From debbugs-submit-bounces@debbugs.gnu.org Sun Jul 07 17:03:13 2019 Received: (at submit) by debbugs.gnu.org; 7 Jul 2019 21:03:13 +0000 Received: from localhost ([127.0.0.1]:57482 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hkEJV-0007tE-1G for submit@debbugs.gnu.org; Sun, 07 Jul 2019 17:03:13 -0400 Received: from lists.gnu.org ([209.51.188.17]:47734) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hkEJS-0007t6-VQ for submit@debbugs.gnu.org; Sun, 07 Jul 2019 17:03:11 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:38714) by lists.gnu.org with esmtp (Exim 4.86_2) (envelope-from ) id 1hkEJR-0007ik-3U for guix-patches@gnu.org; Sun, 07 Jul 2019 17:03:10 -0400 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=0.8 required=5.0 tests=BAYES_50,FREEMAIL_FROM, RCVD_IN_DNSWL_NONE,URIBL_BLOCKED autolearn=disabled version=3.3.2 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hkEJP-0005dp-95 for guix-patches@gnu.org; Sun, 07 Jul 2019 17:03:09 -0400 Received: from mout.gmx.net ([212.227.15.19]:52253) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1hkEJI-0005UN-32; Sun, 07 Jul 2019 17:03:00 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gmx.net; s=badeba3b8450; t=1562533371; bh=vGO2pyEMUi9kCUNB8TfjN63p4tWUVK0kCF8yS6qCTIk=; h=X-UI-Sender-Class:From:To:Subject:CC:Date; b=Dmsq0jtY9xulQrvFMbbbMwGtFz9zYfconqJ6doJ716Xr5cqSMCEtT5mF/kittnPZx yvFEIgOJzHI9yisG+dQJXo8x7jQgqbRkOF8ByowSndcbTaSqT48IRo68r4cIYxGfci j52QzvwK1PyYG3zLzquHxn/KLaa8EWNOKqUerWfs= X-UI-Sender-Class: 01bb95c1-4bf8-414a-932a-4f6e2808ef9c Received: from labiere ([2.99.195.183]) by mail.gmx.com (mrgmx002 [212.227.17.184]) with ESMTPSA (Nemesis) id 0MRGPP-1hw0WL1bvL-00Udy5; Sun, 07 Jul 2019 23:02:50 +0200 User-agent: mu4e 1.2.0; emacs 26.2 From: Pierre Langlois To: Guix-patches Subject: [PATCH] gnu: wireservice: New wireservice-package macro. Date: Sun, 07 Jul 2019 22:02:47 +0100 Message-ID: <875zod8snc.fsf@gmx.com> MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" X-Provags-ID: V03:K1:EFEgqVTyVhl7+NBIM/zCenuljknK+dIZDVm1yxgHlmA8vXCXcwn U6yUuda3KP0XdcVBniDplTuPyyw46AA42y55lL+wFMbfpbRYmv3oH2am6ibH/wYDRb9PIg9 4c587vmf3Yh9hMYrWw4ZJeuGKwzLVslovCabMxmWEXygnwnYJQCWM80U18lxlVuisHrYAVt QgJ2495fE8TypVuEmqT7w== X-UI-Out-Filterresults: notjunk:1;V03:K0:T5jtMVqA07I=:KrUazt9aSdsJxFKOVHutHE sdRH728ZDqEA3Vub4Wiy7YA0VMkXXD37nel4Z5Mdf2lP2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dI= X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 212.227.15.19 X-Spam-Score: -1.4 (-) X-Debbugs-Envelope-To: submit Cc: Pierre Langlois , Ludovic =?utf-8?Q?Court?= =?utf-8?Q?=C3=A8s?= X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -2.4 (--) --=-=-= Content-Type: text/plain Hi Guix, Ludo, Here's a new 'wireservice-package' macro that factors the packages that used to inherit for a base package with '#f fields. The main change is that native-inputs are no longer common, I toyed with a more complicated macro that would allow extending them but in the end I think the simpler the better! WDYT? Thanks for the suggestion! I need to learn me some more macro magic, it's fun :-). Pierre --=-=-= Content-Type: text/x-patch Content-Disposition: attachment; filename=0001-gnu-wireservice-New-wireservice-package-macro.patch Content-Transfer-Encoding: quoted-printable =46rom cf7559db69dd1d829e620c6b31e253a2d8911eff Mon Sep 17 00:00:00 2001 From: Pierre Langlois Date: Sun, 7 Jul 2019 16:02:26 +0100 Subject: [PATCH] gnu: wireservice: New wireservice-package macro. Replace the parent 'base-package' variable with a 'wireservice-package' ma= cro that includes all common package fields. * gnu/packages/wireservice.scm (base-package): Delete. (wireservice-package): New macro. (python-leather, python-agate, python-agate-sql, python-agate-dbf, python-agate-excel): Use wireservice-package. =2D-- gnu/packages/wireservice.scm | 247 ++++++++++++++++++----------------- 1 file changed, 124 insertions(+), 123 deletions(-) diff --git a/gnu/packages/wireservice.scm b/gnu/packages/wireservice.scm index ab86f21f2f..362b69575f 100644 =2D-- a/gnu/packages/wireservice.scm +++ b/gnu/packages/wireservice.scm @@ -30,21 +30,10 @@ #:use-module (gnu packages sphinx) #:use-module (gnu packages time)) -;; Base package definition for packages from https://github.com/wireservi= ce. -;; This is done so we can share how to run tests and build documentation. -(define base-package +;; Common package definition for packages from https://github.com/wireser= vice. +(define-syntax-rule (wireservice-package extra-fields ...) (package - (name #f) - (version #f) - (source #f) - (home-page #f) - (synopsis #f) - (description #f) (build-system python-build-system) - (native-inputs - `(("python-nose" ,python-nose) - ("python-sphinx" ,python-sphinx) - ("python-sphinx-rtd-theme" ,python-sphinx-rtd-theme))) (arguments `(#:phases (modify-phases %standard-phases @@ -66,131 +55,143 @@ (string-append doc "/" target))) '("html" "dirhtml" "singlehtml" "text"))) #t)))))) - (license license:expat))) + (license license:expat) + extra-fields ...)) (define-public python-leather - (package - (inherit base-package) - (name "python-leather") - (version "0.3.3") - (source (origin - (method git-fetch) - (uri (git-reference - (url "https://github.com/wireservice/leather.git") - (commit version))) - (file-name (git-file-name name version)) - (sha256 - (base32 - "1ck3dplni99sv4s117cbm07ydwwjsrxkhdy19rnk0iglia1d4s5i")))= ) - (native-inputs - `(("python-cssselect" ,python-cssselect) - ("python-lxml" ,python-lxml) - ,@(package-native-inputs base-package))) - (propagated-inputs - `(("python-six" ,python-six))) - (home-page "https://leather.rtfd.org") - (synopsis "Python charting for 80% of humans") - (description "Leather is a Python charting library for those who need + (wireservice-package + (name "python-leather") + (version "0.3.3") + (source (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/wireservice/leather.git") + (commit version))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "1ck3dplni99sv4s117cbm07ydwwjsrxkhdy19rnk0iglia1d4s5i")))) + (native-inputs + `(("python-nose" ,python-nose) + ("python-sphinx" ,python-sphinx) + ("python-sphinx-rtd-theme" ,python-sphinx-rtd-theme) + ("python-csselect" ,python-cssselect) + ("python-lxml" ,python-lxml))) + (propagated-inputs + `(("python-six" ,python-six))) + (home-page "https://leather.rtfd.org") + (synopsis "Python charting for 80% of humans") + (description "Leather is a Python charting library for those who need charts now and don't care if they're perfect."))) (define-public python-agate - (package - (inherit base-package) - (name "python-agate") - (version "1.6.1") - (source (origin - (method git-fetch) - (uri (git-reference - (url "https://github.com/wireservice/agate.git") - (commit version))) - (file-name (git-file-name name version)) - (sha256 - (base32 - "077zj8xad8hsa3nqywvf7ircirmx3krxdipl8wr3dynv3l3khcpl")))= ) - (native-inputs - `(("python-cssselect" ,python-cssselect) - ("python-lxml" ,python-lxml) - ,@(package-native-inputs base-package))) - (propagated-inputs - `(("python-babel" ,python-babel) - ("python-isodate" ,python-isodate) - ("python-leather" ,python-leather) - ("python-parsedatetime" ,python-parsedatetime) - ("python-pytimeparse" ,python-pytimeparse) - ("python-six" ,python-six) - ("python-slugify" ,python-slugify))) - (home-page "https://agate.rtfd.org") - (synopsis "Data analysis library") - (description "Agate is a Python data analysis library. It is an + (wireservice-package + (name "python-agate") + (version "1.6.1") + (source (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/wireservice/agate.git") + (commit version))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "077zj8xad8hsa3nqywvf7ircirmx3krxdipl8wr3dynv3l3khcpl")))) + (native-inputs + `(("python-nose" ,python-nose) + ("python-sphinx" ,python-sphinx) + ("python-sphinx-rtd-theme" ,python-sphinx-rtd-theme) + ("python-csselect" ,python-cssselect) + ("python-lxml" ,python-lxml))) + (propagated-inputs + `(("python-babel" ,python-babel) + ("python-isodate" ,python-isodate) + ("python-leather" ,python-leather) + ("python-parsedatetime" ,python-parsedatetime) + ("python-pytimeparse" ,python-pytimeparse) + ("python-six" ,python-six) + ("python-slugify" ,python-slugify))) + (home-page "https://agate.rtfd.org") + (synopsis "Data analysis library") + (description "Agate is a Python data analysis library. It is an alternative to numpy and pandas that solves real-world problems with read= able code. Agate was previously known as journalism."))) (define-public python-agate-sql - (package - (inherit base-package) - (name "python-agate-sql") - (version "0.5.4") - (source (origin - (method git-fetch) - (uri (git-reference - (url "https://github.com/wireservice/agate-sql.git") - (commit version))) - (file-name (git-file-name name version)) - (sha256 - (base32 - "16q0b211n5b1qmhzkfl2jr56lda0rvyh5j1wzw26h2n4pm4wxlx2")))= ) - (propagated-inputs - `(("python-agate" ,python-agate) - ("python-crate" ,python-crate) - ("python-sqlalchemy" ,python-sqlalchemy))) - (home-page "https://agate-sql.rtfd.org") - (synopsis "SQL read/write support to agate") - (description "@code{agatesql} uses a monkey patching pattern to add S= QL + (wireservice-package + (name "python-agate-sql") + (version "0.5.4") + (source (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/wireservice/agate-sql.git") + (commit version))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "16q0b211n5b1qmhzkfl2jr56lda0rvyh5j1wzw26h2n4pm4wxlx2")))) + (native-inputs + `(("python-nose" ,python-nose) + ("python-sphinx" ,python-sphinx) + ("python-sphinx-rtd-theme" ,python-sphinx-rtd-theme))) + (propagated-inputs + `(("python-agate" ,python-agate) + ("python-crate" ,python-crate) + ("python-sqlalchemy" ,python-sqlalchemy))) + (home-page "https://agate-sql.rtfd.org") + (synopsis "SQL read/write support to agate") + (description "@code{agatesql} uses a monkey patching pattern to add SQ= L support to all @code{agate.Table} instances."))) (define-public python-agate-dbf - (package - (inherit base-package) - (name "python-agate-dbf") - (version "0.2.1") - (source (origin - (method git-fetch) - (uri (git-reference - (url "https://github.com/wireservice/agate-dbf.git") - (commit version))) - (file-name (git-file-name name version)) - (sha256 - (base32 - "1y49fi6pmm7gzhajvqmfpcca2sqnwj24fqnsvzwk7r1hg2iaa2gi")))= ) - (propagated-inputs - `(("python-agate" ,python-agate) - ("python-dbfread" ,python-dbfread))) - (home-page "https://agate-dbf.rtfd.org") - (synopsis "Add read support for dbf files to agate") - (description "@code{agatedbf} uses a monkey patching pattern to add r= ead + (wireservice-package + (name "python-agate-dbf") + (version "0.2.1") + (source (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/wireservice/agate-dbf.git") + (commit version))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "1y49fi6pmm7gzhajvqmfpcca2sqnwj24fqnsvzwk7r1hg2iaa2gi")))) + (native-inputs + `(("python-nose" ,python-nose) + ("python-sphinx" ,python-sphinx) + ("python-sphinx-rtd-theme" ,python-sphinx-rtd-theme))) + (propagated-inputs + `(("python-agate" ,python-agate) + ("python-dbfread" ,python-dbfread))) + (home-page "https://agate-dbf.rtfd.org") + (synopsis "Add read support for dbf files to agate") + (description "@code{agatedbf} uses a monkey patching pattern to add re= ad for dbf files support to all @code{agate.Table} instances."))) (define-public python-agate-excel - (package - (inherit base-package) - (name "python-agate-excel") - (version "0.2.3") - (source (origin - (method git-fetch) - (uri (git-reference - (url "https://github.com/wireservice/agate-excel.git"= ) - (commit version))) - (file-name (git-file-name name version)) - (sha256 - (base32 - "1k5lv21k19s7kgbj5srd1xgrkqvxqqs49qwj33zncs9l7851afy7")))= ) - (propagated-inputs - `(("python-agate" ,python-agate) - ("python-openpyxl" ,python-openpyxl) - ("python-xlrd" ,python-xlrd))) - (home-page "https://agate-excel.rtfd.org") - (synopsis "Add read support for Excel files (xls and xlsx) to agate") - (description "@code{agateexcel} uses a monkey patching pattern to add= read + (wireservice-package + (name "python-agate-excel") + (version "0.2.3") + (source (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/wireservice/agate-excel.git") + (commit version))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "1k5lv21k19s7kgbj5srd1xgrkqvxqqs49qwj33zncs9l7851afy7")))) + (native-inputs + `(("python-nose" ,python-nose) + ("python-sphinx" ,python-sphinx) + ("python-sphinx-rtd-theme" ,python-sphinx-rtd-theme))) + (propagated-inputs + `(("python-agate" ,python-agate) + ("python-openpyxl" ,python-openpyxl) + ("python-xlrd" ,python-xlrd))) + (home-page "https://agate-excel.rtfd.org") + (synopsis "Add read support for Excel files (xls and xlsx) to agate") + (description "@code{agateexcel} uses a monkey patching pattern to add = read for xls and xlsx files support to all @code{agate.Table} instances."))) (define-public csvkit =2D- 2.22.0 --=-=-=-- From debbugs-submit-bounces@debbugs.gnu.org Mon Jul 08 06:57:40 2019 Received: (at 36543-done) by debbugs.gnu.org; 8 Jul 2019 10:57:40 +0000 Received: from localhost ([127.0.0.1]:57934 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hkRL1-0008Rn-Um for submit@debbugs.gnu.org; Mon, 08 Jul 2019 06:57:40 -0400 Received: from eggs.gnu.org ([209.51.188.92]:58239) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hkRL0-0008Ra-1W for 36543-done@debbugs.gnu.org; Mon, 08 Jul 2019 06:57:38 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]:54828) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hkRKu-00055v-HG; Mon, 08 Jul 2019 06:57:32 -0400 Received: from [2001:660:6102:320:e120:2c8f:8909:cdfe] (port=39704 helo=ribbon) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1hkRKt-00089c-5X; Mon, 08 Jul 2019 06:57:31 -0400 From: =?utf-8?Q?Ludovic_Court=C3=A8s?= To: Pierre Langlois Subject: Re: [bug#36543] [PATCH] gnu: wireservice: New wireservice-package macro. References: <875zod8snc.fsf@gmx.com> Date: Mon, 08 Jul 2019 12:57:28 +0200 In-Reply-To: <875zod8snc.fsf@gmx.com> (Pierre Langlois's message of "Sun, 07 Jul 2019 22:02:47 +0100") Message-ID: <87imscequf.fsf@gnu.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.2 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 36543-done Cc: 36543-done@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) Hello, Pierre Langlois skribis: > Here's a new 'wireservice-package' macro that factors the packages that > used to inherit for a base package with '#f fields. The main change is > that native-inputs are no longer common, I toyed with a more complicated > macro that would allow extending them but in the end I think the simpler > the better! > > WDYT? I think it looks good this way! There=E2=80=99s a bit of code bloat because the macro expands the =E2=80=98= arguments=E2=80=99 field for every package, but it doesn=E2=80=99t matter much here (it=E2=80= =99d be more of a problem if we had 100s of packages all duplicating that field.) > Thanks for the suggestion! I need to learn me some more macro magic, > it's fun :-). Yup! :-) > From cf7559db69dd1d829e620c6b31e253a2d8911eff Mon Sep 17 00:00:00 2001 > From: Pierre Langlois > Date: Sun, 7 Jul 2019 16:02:26 +0100 > Subject: [PATCH] gnu: wireservice: New wireservice-package macro. > > Replace the parent 'base-package' variable with a 'wireservice-package' m= acro > that includes all common package fields. > > * gnu/packages/wireservice.scm (base-package): Delete. > (wireservice-package): New macro. > (python-leather, python-agate, python-agate-sql, python-agate-dbf, > python-agate-excel): Use wireservice-package. Applied, thanks for the quick followup! Ludo=E2=80=99. From unknown Wed Jun 18 23:18:32 2025 Received: (at fakecontrol) by fakecontrolmessage; To: internal_control@debbugs.gnu.org From: Debbugs Internal Request Subject: Internal Control Message-Id: bug archived. Date: Mon, 05 Aug 2019 11:24:06 +0000 User-Agent: Fakemail v42.6.9 # This is a fake control message. # # The action: # bug archived. thanks # This fakemail brought to you by your local debbugs # administrator