gnu: Add python-optparse-pretty and python-mgatk.

  • Done
  • quality assurance status badge
Details
3 participants
  • MadalinIonel.Patrascu@mdc-berlin.de
  • Mădălin Ionel Patrașcu
  • Ricardo Wurmus
Owner
unassigned
Submitted by
MadalinIonel.Patrascu@mdc-berlin.de
Severity
normal

Debbugs page

MadalinIonel.Patrascu@mdc-berlin.de wrote 2 years ago
(name . guix-patches@gnu.org)(address . guix-patches@gnu.org)
271d6a24b07a43ce8258824917b6630a@mdc-berlin.de
* gnu/packages/python-xyz.scm (python-optparse-pretty): New variable.

* gnu/packages/bioinformatics.scm (python-mgatk): New variable.
Attachment: file
Mădălin Ionel Patrașcu wrote 2 years ago
[PATCH 2/2] gnu: Add python-mgatk.
(address . 63448@debbugs.gnu.org)
20230511183412.27180-2-madalinionel.patrascu@mdc-berlin.de
* gnu/packages/bioinformatics.scm (python-mgatk): New variable.
---
gnu/packages/bioinformatics.scm | 35 +++++++++++++++++++++++++++++++++
1 file changed, 35 insertions(+)

Toggle diff (48 lines)
diff --git a/gnu/packages/bioinformatics.scm b/gnu/packages/bioinformatics.scm
index afca5ab93b..92017b3a07 100644
--- a/gnu/packages/bioinformatics.scm
+++ b/gnu/packages/bioinformatics.scm
@@ -12628,6 +12628,41 @@ (define-public python-biothings-client
API services.")
(license license:bsd-3)))
+(define-public python-mgatk
+ (package
+ (name "python-mgatk")
+ (version "0.6.7")
+ (source
+ (origin
+ (method url-fetch)
+ (uri (pypi-uri "mgatk" version))
+ (sha256
+ (base32 "0bxxk3v8lmqcdnm97468p7p3kzb59i5bpgayx7kqzl2p8lfwzi9h"))))
+ (build-system pyproject-build-system)
+ (arguments
+ (list #:tests? #f)) ; There are no tests in the pypi archive.
+ (propagated-inputs
+ (list python-biopython
+ python-click
+ python-numpy
+ python-optparse-pretty
+ python-pandas
+ python-pysam
+ python-regex
+ python-ruamel.yaml
+ snakemake))
+ (native-inputs
+ (list python-pytest))
+ (home-page "https://github.com/caleblareau/mgatk")
+ (synopsis "Mitochondrial genome analysis toolkit.")
+ (description "This package is a python-based command line interface for
+processing .bam files with mitochondrial reads and generating high-quality
+heteroplasmy estimation from sequencing data. The mgatk package places a
+special emphasis on mitochondrial genotypes generated from single-cell genomics
+data, primarily @acronym{mtscATAC-seq, mitochondrial single-cell ATAC-sequence},
+but is generally applicable across other assays.")
+ (license license:expat)))
+
(define-public python-multivelo
(package
(name "python-multivelo")
--
2.39.2
Mădălin Ionel Patrașcu wrote 2 years ago
[PATCH 1/2] gnu: Add python-optparse-pretty.
(address . 63448@debbugs.gnu.org)
20230511183412.27180-1-madalinionel.patrascu@mdc-berlin.de
* gnu/packages/python-xyz.scm (python-optparse-pretty): New variable
---
gnu/packages/python-xyz.scm | 23 ++++++++++++++++++++++-
1 file changed, 22 insertions(+), 1 deletion(-)

Toggle diff (45 lines)
diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm
index 4f48d80eb6..9fabfce79f 100644
--- a/gnu/packages/python-xyz.scm
+++ b/gnu/packages/python-xyz.scm
@@ -66,7 +66,7 @@
;;; Copyright © 2019, 2020, 2021 Giacomo Leidi <goodoldpaul@autistici.org>
;;; Copyright © 2019 Wiktor Żelazny <wzelazny@vurv.cz>
;;; Copyright © 2019, 2020, 2021, 2022 Tanguy Le Carrour <tanguy@bioneland.org>
-;;; Copyright © 2019, 2021, 2022 Mădălin Ionel Patrașcu <madalinionel.patrascu@mdc-berlin.de>
+;;; Copyright © 2019, 2021-2023 Mădălin Ionel Patrașcu <madalinionel.patrascu@mdc-berlin.de>
;;; Copyright © 2020 Riku Viitanen <riku.viitanen@protonmail.com>
;;; Copyright © 2020 Jakub Kądziołka <kuba@kadziolka.net>
;;; Copyright © 2020 sirgazil <sirgazil@zoho.com>
@@ -2690,6 +2690,27 @@ (define-public python-diskcache
(description "DiskCache is a disk and file backed persistent cache.")
(license license:asl2.0)))
+(define-public python-optparse-pretty
+ (package
+ (name "python-optparse-pretty")
+ (version "0.1.1")
+ (source
+ (origin
+ (method url-fetch)
+ (uri (pypi-uri "optparse-pretty" version))
+ (sha256
+ (base32 "1920wbh2b7a8qn7zx2iiqbcdaax335l81a73x9pp8h11yzs2jdmh"))))
+ (build-system pyproject-build-system)
+ (arguments
+ (list #:tests? #f)) ; There are no tests in the pypi archive.
+ (home-page "https://github.com/gvalkov/optparse-pretty")
+ (synopsis "Compact help formatter for optparse")
+ (description
+ "This module provides two help formatters for optparse. They provide
+terser and more customizable option formatting in comparison to the default
+help formatter.")
+ (license license:bsd-3)))
+
(define-public python-orjson
(package
(name "python-orjson")

base-commit: e2eb43f945fd467e9b55a4b3c91cd186cf32e268
--
2.39.2
Ricardo Wurmus wrote 2 years ago
Re: [bug#63448] [PATCH 2/2] gnu: Add python-mgatk.
(name . Mădălin Ionel Patrașcu)(address . madalinionel.patrascu@mdc-berlin.de)(address . 63448@debbugs.gnu.org)
87jzxet2wq.fsf@elephly.net
Mădălin Ionel Patrașcu <madalinionel.patrascu@mdc-berlin.de> writes:

Toggle quote (2 lines)
> * gnu/packages/bioinformatics.scm (python-mgatk): New variable.
> ---
Toggle quote (3 lines)
> + (arguments
> + (list #:tests? #f)) ; There are no tests in the pypi archive.

Can you fetch the sources from https://github.com/caleblareau/mgatkinstead?
It is better to make sure this actually works by running at least some
of the tests.

--
Ricardo
Ricardo Wurmus wrote 2 years ago
Re: [bug#63448] [PATCH 1/2] gnu: Add python-optparse-pretty.
(name . Mădălin Ionel Patrașcu)(address . madalinionel.patrascu@mdc-berlin.de)(address . 63448@debbugs.gnu.org)
87fs82t2t7.fsf@elephly.net
Mădălin Ionel Patrașcu <madalinionel.patrascu@mdc-berlin.de> writes:

Toggle quote (1 lines)
> * gnu/packages/python-xyz.scm (python-optparse-pretty): New variable
Toggle quote (10 lines)
> + (source
> + (origin
> + (method url-fetch)
> + (uri (pypi-uri "optparse-pretty" version))
> + (sha256
> + (base32 "1920wbh2b7a8qn7zx2iiqbcdaax335l81a73x9pp8h11yzs2jdmh"))))
> + (build-system pyproject-build-system)
> + (arguments
> + (list #:tests? #f)) ; There are no tests in the pypi archive.

There are no tests at all, not just in pypi.

--
Ricardo
Mădălin Ionel Patrașcu wrote 2 years ago
[PATCH v2 2/2] gnu: Add python-mgatk.
(address . 63448@debbugs.gnu.org)
20230512103359.4111-1-madalinionel.patrascu@mdc-berlin.de
* gnu/packages/bioinformatics.scm (python-mgatk): New variable.
---
gnu/packages/bioinformatics.scm | 54 +++++++++++++++++++++++++++++++++
1 file changed, 54 insertions(+)

Toggle diff (69 lines)
diff --git a/gnu/packages/bioinformatics.scm b/gnu/packages/bioinformatics.scm
index afca5ab93b..86e54ad5f5 100644
--- a/gnu/packages/bioinformatics.scm
+++ b/gnu/packages/bioinformatics.scm
@@ -12628,6 +12628,60 @@ (define-public python-biothings-client
API services.")
(license license:bsd-3)))
+(define-public python-mgatk
+ (let ((commit "2633903acb1fb406bb58c787f320c3641f446ee7")
+ (revision "0"))
+ (package
+ (name "python-mgatk")
+ (version "0.6.7")
+ (source
+ (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/caleblareau/mgatk")
+ (commit commit)))
+ (file-name (git-file-name name version))
+ ;(method url-fetch)
+ ;(uri (pypi-uri "mgatk" version))
+ (sha256
+ (base32 "19iklfv1brwsfg1l5lrs3z8m343nskkn1998c1fs7fdn0lgrki2p"))))
+ (build-system pyproject-build-system)
+ (arguments
+ (list
+ #:phases
+ #~(modify-phases %standard-phases
+ ;; The md5 module has beed deprecated since Python 2.5
+ (add-after 'unpack 'make-python3-compatible
+ (lambda* _
+ (substitute* "tests/test_cli.py"
+ (("import md5") ""))))
+ (replace 'check
+ (lambda* (#:key tests? #:allow-other-keys)
+ (when tests?
+ (invoke "pytest" "-vv" "-k" "not file_checksums_equal")))))))
+ (propagated-inputs
+ (list python-biopython
+ python-click
+ python-numpy
+ python-optparse-pretty
+ python-pandas
+ python-pysam
+ python-regex
+ python-ruamel.yaml
+ snakemake))
+ (native-inputs
+ (list python-minimal
+ python-pytest))
+ (home-page "https://github.com/caleblareau/mgatk")
+ (synopsis "Mitochondrial genome analysis toolkit.")
+ (description "This package is a python-based command line interface for
+processing .bam files with mitochondrial reads and generating high-quality
+heteroplasmy estimation from sequencing data. The mgatk package places a
+special emphasis on mitochondrial genotypes generated from single-cell genomics
+data, primarily @acronym{mtscATAC-seq, mitochondrial single-cell ATAC-sequence},
+but is generally applicable across other assays.")
+ (license license:expat))))
+
(define-public python-multivelo
(package
(name "python-multivelo")

base-commit: d07342b16612cfdffad6a7b3504b74e0d95d551f
--
2.39.2
Mădălin Ionel Patrașcu wrote 2 years ago
[PATCH v3 2/2] gnu: Add python-mgatk.
(address . 63448@debbugs.gnu.org)
20230512104303.4337-1-madalinionel.patrascu@mdc-berlin.de
* gnu/packages/bioinformatics.scm (python-mgatk): New variable.
---
gnu/packages/bioinformatics.scm | 52 +++++++++++++++++++++++++++++++++
1 file changed, 52 insertions(+)

Toggle diff (67 lines)
diff --git a/gnu/packages/bioinformatics.scm b/gnu/packages/bioinformatics.scm
index afca5ab93b..abb7cf374a 100644
--- a/gnu/packages/bioinformatics.scm
+++ b/gnu/packages/bioinformatics.scm
@@ -12628,6 +12628,58 @@ (define-public python-biothings-client
API services.")
(license license:bsd-3)))
+(define-public python-mgatk
+ (let ((commit "2633903acb1fb406bb58c787f320c3641f446ee7")
+ (revision "0"))
+ (package
+ (name "python-mgatk")
+ (version "0.6.7")
+ (source
+ (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/caleblareau/mgatk")
+ (commit commit)))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32 "19iklfv1brwsfg1l5lrs3z8m343nskkn1998c1fs7fdn0lgrki2p"))))
+ (build-system python-build-system)
+ (arguments
+ (list
+ #:phases
+ #~(modify-phases %standard-phases
+ ;; The md5 module has beed deprecated since Python 2.5
+ (add-after 'unpack 'make-python3-compatible
+ (lambda* _
+ (substitute* "tests/test_cli.py"
+ (("import md5") ""))))
+ (replace 'check
+ (lambda* (#:key tests? #:allow-other-keys)
+ (when tests?
+ ;; This test is based on the md5 module
+ (invoke "pytest" "-vv" "-k" "not file_checksums_equal")))))))
+ (propagated-inputs
+ (list python-biopython
+ python-click
+ python-numpy
+ python-optparse-pretty
+ python-pandas
+ python-pysam
+ python-regex
+ python-ruamel.yaml
+ snakemake))
+ (native-inputs
+ (list python-pytest))
+ (home-page "https://github.com/caleblareau/mgatk")
+ (synopsis "Mitochondrial genome analysis toolkit.")
+ (description "This package is a python-based command line interface for
+processing .bam files with mitochondrial reads and generating high-quality
+heteroplasmy estimation from sequencing data. The mgatk package places a
+special emphasis on mitochondrial genotypes generated from single-cell genomics
+data, primarily @acronym{mtscATAC-seq, mitochondrial single-cell ATAC-sequence},
+but is generally applicable across other assays.")
+ (license license:expat))))
+
(define-public python-multivelo
(package
(name "python-multivelo")

base-commit: d07342b16612cfdffad6a7b3504b74e0d95d551f
--
2.39.2
Ricardo Wurmus wrote 2 years ago
gnu: Add python-optparse-pretty and python-mgatk.
(address . 63448-done@debbugs.gnu.org)
87y1ltskuw.fsf@elephly.net
I changed it back to pyproject-build-system; all Python packages should
be using pyproject-build-system, as it will replace the
python-build-system eventually.

Instead of disabling the tests I patched it to use hashlib.md5.

--
Ricardo
Closed
?
Your comment

This issue is archived.

To comment on this conversation send an email to 63448@debbugs.gnu.org

To respond to this issue using the mumi CLI, first switch to it
mumi current 63448
Then, you may apply the latest patchset in this issue (with sign off)
mumi am -- -s
Or, compose a reply to this issue
mumi compose
Or, send patches to this issue
mumi send-email *.patch
You may also tag this issue. See list of standard tags. For example, to set the confirmed and easy tags
mumi command -t +confirmed -t +easy
Or, remove the moreinfo tag and set the help tag
mumi command -t -moreinfo -t +help