GNU bug report logs - #27548
[PATCH] gnu: Add python-xenon

Previous Next

Package: guix-patches;

Reported by: Muriithi Frederick Muriuki <fredmanglis <at> gmail.com>

Date: Sat, 1 Jul 2017 14:45:01 UTC

Severity: normal

Tags: patch

Done: ludo <at> gnu.org (Ludovic Courtès)

Bug is archived. No further changes may be made.

To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 27548 in the body.
You can then email your comments to 27548 AT debbugs.gnu.org in the normal way.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to guix-patches <at> gnu.org:
bug#27548; Package guix-patches. (Sat, 01 Jul 2017 14:45:02 GMT) Full text and rfc822 format available.

Acknowledgement sent to Muriithi Frederick Muriuki <fredmanglis <at> gmail.com>:
New bug report received and forwarded. Copy sent to guix-patches <at> gnu.org. (Sat, 01 Jul 2017 14:45:02 GMT) Full text and rfc822 format available.

Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: Muriithi Frederick Muriuki <fredmanglis <at> gmail.com>
To: guix-patches <at> gnu.org
Subject: [PATCH] gnu: Add python-xenon
Date: Sat,  1 Jul 2017 17:44:20 +0300
* gnu/packages/python.scm (python-xenon, python2-xenon) New variables.
---
 gnu/packages/python.scm | 46 ++++++++++++++++++++++++++++++++++++++++++++++
 1 file changed, 46 insertions(+)

diff --git a/gnu/packages/python.scm b/gnu/packages/python.scm
index 6e1e289e9..1167b0933 100644
--- a/gnu/packages/python.scm
+++ b/gnu/packages/python.scm
@@ -15512,3 +15512,49 @@ pure Python module.")
 
 (define-public python2-rencode
   (package-with-python2 python-rencode))
+
+(define-public python-xenon
+  (package
+    (name "python-xenon")
+    (version "0.5.1")
+    (source
+     (origin
+       (method url-fetch)
+       (uri (pypi-uri "xenon" version))
+       (sha256
+        (base32
+         "14kby2y48vp3sgwxqlm5d5789yibqwb1qli5fwcmdqg3iayrbklc"))))
+    (build-system python-build-system)
+    (native-inputs
+     `(("python-pyyaml" ,python-pyyaml)
+       ("python-radon" ,python-radon)
+       ("python-requests" ,python-requests)
+      ("python-flake8" ,python-flake8)
+       ("python-tox" ,python-tox)))
+    (arguments
+     `(#:phases
+       (modify-phases %standard-phases
+         (add-before 'build 'patch-test-requirements
+          (lambda* (#:key inputs #:allow-other-keys)
+             ;; Update requirements from dependecy==version
+             ;; to dependency>=version
+             (substitute* "requirements.txt"
+               (("==") ">=")
+               ((",<1.5.0") ""))
+            ;; Remove httpretty dependency for tests
+             (substitute* "setup.py"
+               (("httpretty") ""))
+             #t)))))
+    (home-page "https://xenon.readthedocs.org/")
+    (synopsis
+     "Monitor code metrics for Python on your CI server")
+   (description
+     "@code{Xenon} is a monitoring tool based on Radon.  It monitors code’s
+complexity.  Ideally, @code{xenon} is run every time code is committed.  Through
+command line options, various thresholds can be set for the complexity of code.
+It will fail (i.e.  it will exit with a non-zero exit code) when any of these
+equirements is not met.")
+    (license license:expat)))
+
+(define-public python2-xenon
+  (package-with-python2 python-xenon))
-- 
2.13.2





Information forwarded to guix-patches <at> gnu.org:
bug#27548; Package guix-patches. (Tue, 11 Jul 2017 19:04:01 GMT) Full text and rfc822 format available.

Message #8 received at 27548 <at> debbugs.gnu.org (full text, mbox):

From: Marius Bakke <mbakke <at> fastmail.com>
To: Muriithi Frederick Muriuki <fredmanglis <at> gmail.com>, 27548 <at> debbugs.gnu.org
Subject: Re: [bug#27548] [PATCH] gnu: Add python-xenon
Date: Tue, 11 Jul 2017 21:03:24 +0200
[Message part 1 (text/plain, inline)]
Hello!

Sorry for the slooow response :-)

The patch mostly LGTM. A few minor comments:

Muriithi Frederick Muriuki <fredmanglis <at> gmail.com> writes:

> * gnu/packages/python.scm (python-xenon, python2-xenon) New variables.

[...]

> +(define-public python-xenon
> +  (package
> +    (name "python-xenon")
> +    (version "0.5.1")

It looks like 0.5.2 was recently released. Can you try updating to it?

> +    (source
> +     (origin
> +       (method url-fetch)
> +       (uri (pypi-uri "xenon" version))
> +       (sha256
> +        (base32
> +         "14kby2y48vp3sgwxqlm5d5789yibqwb1qli5fwcmdqg3iayrbklc"))))
> +    (build-system python-build-system)
> +    (native-inputs
> +     `(("python-pyyaml" ,python-pyyaml)
> +       ("python-radon" ,python-radon)
> +       ("python-requests" ,python-requests)
> +      ("python-flake8" ,python-flake8)

Indentation is off :)

> +       ("python-tox" ,python-tox)))
> +    (arguments
> +     `(#:phases
> +       (modify-phases %standard-phases
> +         (add-before 'build 'patch-test-requirements
> +          (lambda* (#:key inputs #:allow-other-keys)
> +             ;; Update requirements from dependecy==version
Missing letter here:                             ^^^
> +             ;; to dependency>=version
> +             (substitute* "requirements.txt"
> +               (("==") ">=")
> +               ((",<1.5.0") ""))
> +            ;; Remove httpretty dependency for tests
> +             (substitute* "setup.py"
> +               (("httpretty") ""))

Why is this necessary? Can you expand on this comment?

> +             #t)))))
> +    (home-page "https://xenon.readthedocs.org/")
> +    (synopsis
> +     "Monitor code metrics for Python on your CI server")
> +   (description
> +     "@code{Xenon} is a monitoring tool based on Radon.  It monitors code’s

I think we can drop @code here since it's used as a name. Side note: It
would be cool if we could cross-reference packages in descriptions.

Sorry for the nit-picks! I'll go through the other patches shortly.

> +complexity.  Ideally, @code{xenon} is run every time code is committed.  Through
> +command line options, various thresholds can be set for the complexity of code.
> +It will fail (i.e.  it will exit with a non-zero exit code) when any of these
> +equirements is not met.")
> +    (license license:expat)))
[signature.asc (application/pgp-signature, inline)]

Reply sent to ludo <at> gnu.org (Ludovic Courtès):
You have taken responsibility. (Mon, 16 Oct 2017 13:25:01 GMT) Full text and rfc822 format available.

Notification sent to Muriithi Frederick Muriuki <fredmanglis <at> gmail.com>:
bug acknowledged by developer. (Mon, 16 Oct 2017 13:25:02 GMT) Full text and rfc822 format available.

Message #13 received at 27548-done <at> debbugs.gnu.org (full text, mbox):

From: ludo <at> gnu.org (Ludovic Courtès)
To: Muriithi Frederick Muriuki <fredmanglis <at> gmail.com>
Cc: 27548-done <at> debbugs.gnu.org
Subject: Re: [bug#27548] [PATCH] gnu: Add python-xenon
Date: Mon, 16 Oct 2017 15:24:06 +0200
Muriithi Frederick Muriuki <fredmanglis <at> gmail.com> skribis:

> * gnu/packages/python.scm (python-xenon, python2-xenon) New variables.

This was pushed as 2038a48f4d a while back.

Thanks again,
Ludo'.




Information forwarded to guix-patches <at> gnu.org:
bug#27548; Package guix-patches. (Mon, 16 Oct 2017 13:26:02 GMT) Full text and rfc822 format available.

Message #16 received at 27548-done <at> debbugs.gnu.org (full text, mbox):

From: Frederick Muriithi <fredmanglis <at> gmail.com>
To: Ludovic Courtès <ludo <at> gnu.org>
Cc: 27548-done <at> debbugs.gnu.org
Subject: Re: [bug#27548] [PATCH] gnu: Add python-xenon
Date: Mon, 16 Oct 2017 16:25:26 +0300
[Message part 1 (text/plain, inline)]
No problem, thanks!
[Message part 2 (text/html, inline)]

bug archived. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Tue, 14 Nov 2017 12:24:04 GMT) Full text and rfc822 format available.

This bug report was last modified 6 years and 159 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.