all messages for Guix-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* [PATCH] gnu: Add python-dendropy.
@ 2016-07-08 14:04 Ben Woodcroft
  2016-07-08 16:15 ` Leo Famulari
  0 siblings, 1 reply; 3+ messages in thread
From: Ben Woodcroft @ 2016-07-08 14:04 UTC (permalink / raw)
  To: guix-devel

* gnu/packages/bioinformatics.scm (python-dendropy, python2-dendropy): New
variables.
* gnu/packages/patches/python-dendropy-exclude-failing-tests.patch: New
file.
* gnu/local.mk (dist_patch_DATA): Add it.
---
 gnu/local.mk                                       |  1 +
 gnu/packages/bioinformatics.scm                    | 34 ++++++++++++++++++++++
 .../python-dendropy-exclude-failing-tests.patch    | 21 +++++++++++++
 3 files changed, 56 insertions(+)
 create mode 100644 gnu/packages/patches/python-dendropy-exclude-failing-tests.patch

diff --git a/gnu/local.mk b/gnu/local.mk
index 947d1b0..e95c6ae 100644
--- a/gnu/local.mk
+++ b/gnu/local.mk
@@ -743,6 +743,7 @@ dist_patch_DATA =						\
   %D%/packages/patches/python-2.7-source-date-epoch.patch	\
   %D%/packages/patches/python-3-deterministic-build-info.patch	\
   %D%/packages/patches/python-3-search-paths.patch		\
+  %D%/packages/patches/python-dendropy-exclude-failing-tests.patch \
   %D%/packages/patches/python-disable-ssl-test.patch		\
   %D%/packages/patches/python-fix-tests.patch			\
   %D%/packages/patches/python-ipython-inputhook-ctype.patch	\
diff --git a/gnu/packages/bioinformatics.scm b/gnu/packages/bioinformatics.scm
index 03e7584..8f72816 100644
--- a/gnu/packages/bioinformatics.scm
+++ b/gnu/packages/bioinformatics.scm
@@ -1446,6 +1446,40 @@ accessing bigWig files.")
       (native-inputs
        `(("python-setuptools" ,python2-setuptools))))))
 
+(define-public python-dendropy
+  (package
+    (name "python-dendropy")
+    (version "4.1.0")
+    (source
+     (origin
+       (method url-fetch)
+       (uri (pypi-uri "DendroPy" version))
+       (sha256
+        (base32
+         "1jfz7gp18wph311w1yygbvjanb3n5mdqal439bb6myw41dwb5m63"))
+       ;; There are two known test failures thare will be fixed in the next
+       ;; release after 4.1.0.
+       ;; https://github.com/jeetsukumaran/DendroPy/issues/48
+       (patches (search-patches
+                 "python-dendropy-exclude-failing-tests.patch"))))
+    (build-system python-build-system)
+    (home-page "http://packages.python.org/DendroPy/")
+    (synopsis "Library for phylogenetics and phylogenetic computing")
+    (description
+     "DendroPy is a library for phylogenetics and phylogenetic computing: reading,
+writing, simulation, processing and manipulation of phylogenetic
+trees (phylogenies) and characters.")
+    (license license:bsd-3)
+    (properties `((python2-variant . ,(delay python2-dendropy))))))
+
+(define-public python2-dendropy
+  (let ((base (package-with-python2 (strip-python2-variant python-dendropy))))
+    (package
+      (inherit base)
+      (native-inputs `(("python2-setuptools" ,python2-setuptools)
+                       ,@(package-native-inputs base))))))
+
+
 (define-public deeptools
   (package
     (name "deeptools")
diff --git a/gnu/packages/patches/python-dendropy-exclude-failing-tests.patch b/gnu/packages/patches/python-dendropy-exclude-failing-tests.patch
new file mode 100644
index 0000000..288a58b
--- /dev/null
+++ b/gnu/packages/patches/python-dendropy-exclude-failing-tests.patch
@@ -0,0 +1,21 @@
+diff --git a/dendropy/test/test_phylogenetic_distance_matrix.py b/dendropy/test/test_phylogenetic_distance_matrix.py
+index 10c05f5..a18ba52 100644
+--- a/dendropy/test/test_phylogenetic_distance_matrix.py
++++ b/dendropy/test/test_phylogenetic_distance_matrix.py
+@@ -793,7 +793,7 @@ class PdmUpgmaTree(PdmTreeChecker, unittest.TestCase):
+                     expected_tree=expected_tree)
+ 
+ class NodeToNodeDistancesTest(unittest.TestCase):
+-
++    @unittest.expectedFailure
+     def test_distances(self):
+         ## get distances from ape
+         # library(ape)
+@@ -825,6 +825,7 @@ class NodeToNodeDistancesTest(unittest.TestCase):
+                     e = reference_table[nd1.label, nd2.label]
+                     self.assertAlmostEqual(d, e)
+ 
++    @unittest.expectedFailure
+     def test_mrca(self):
+         test_runs = [
+                 "hiv1.newick",
-- 
2.9.0

^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH] gnu: Add python-dendropy.
  2016-07-08 14:04 [PATCH] gnu: Add python-dendropy Ben Woodcroft
@ 2016-07-08 16:15 ` Leo Famulari
  2016-07-08 22:24   ` Ben Woodcroft
  0 siblings, 1 reply; 3+ messages in thread
From: Leo Famulari @ 2016-07-08 16:15 UTC (permalink / raw)
  To: Ben Woodcroft; +Cc: guix-devel

On Sat, Jul 09, 2016 at 12:04:36AM +1000, Ben Woodcroft wrote:
> +(define-public python-dendropy

> +       ;; There are two known test failures thare will be fixed in the next
                                                 ^
						 typo?

Otherwise, it looks good to me.

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] gnu: Add python-dendropy.
  2016-07-08 16:15 ` Leo Famulari
@ 2016-07-08 22:24   ` Ben Woodcroft
  0 siblings, 0 replies; 3+ messages in thread
From: Ben Woodcroft @ 2016-07-08 22:24 UTC (permalink / raw)
  To: Leo Famulari, Ben Woodcroft; +Cc: guix-devel



On 09/07/16 02:15, Leo Famulari wrote:
> On Sat, Jul 09, 2016 at 12:04:36AM +1000, Ben Woodcroft wrote:
>> +(define-public python-dendropy
>> +       ;; There are two known test failures thare will be fixed in the next
>                                                   ^
> 						 typo?

Right. I pushed fixing this, thanks for the review.
ben

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2016-07-08 22:24 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-07-08 14:04 [PATCH] gnu: Add python-dendropy Ben Woodcroft
2016-07-08 16:15 ` Leo Famulari
2016-07-08 22:24   ` Ben Woodcroft

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/guix.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.