[med-svn] r17065 - trunk/packages/python-biopython/trunk/debian/patches
Andreas Tille
tille at moszumanska.debian.org
Sun Jun 8 11:53:35 UTC 2014
Author: tille
Date: 2014-06-08 11:53:35 +0000 (Sun, 08 Jun 2014)
New Revision: 17065
Removed:
trunk/packages/python-biopython/trunk/debian/patches/add_missing_test_Fasttree_tool.patch
trunk/packages/python-biopython/trunk/debian/patches/biopython-from-pil-import-image.patch
trunk/packages/python-biopython/trunk/debian/patches/fix_cpairwise2_import_issue.patch
trunk/packages/python-biopython/trunk/debian/patches/fix_test_emboss.patch
trunk/packages/python-biopython/trunk/debian/patches/use_upstream_patch_for_bwa_test.patch
Modified:
trunk/packages/python-biopython/trunk/debian/patches/remove_mathml-qname.patch
trunk/packages/python-biopython/trunk/debian/patches/series
Log:
Updated patches to new upstream version
Deleted: trunk/packages/python-biopython/trunk/debian/patches/add_missing_test_Fasttree_tool.patch
===================================================================
--- trunk/packages/python-biopython/trunk/debian/patches/add_missing_test_Fasttree_tool.patch 2014-06-08 08:29:42 UTC (rev 17064)
+++ trunk/packages/python-biopython/trunk/debian/patches/add_missing_test_Fasttree_tool.patch 2014-06-08 11:53:35 UTC (rev 17065)
@@ -1,42 +0,0 @@
-Author: Peter Cock <p.j.a.cock at googlemail.com>
-Last-Update: Sun, 27 Apr 2014 13:21:14 +0100
-Description: Add file which is missing for no good reason
- from upstream source tarball. It was obtained from
- https://raw.githubusercontent.com/biopython/biopython/2b414d8a9ca0aa15ef4b4b3680b8bfc755776b56/Tests/output/test_Fasttree_tool
-
---- /dev/null
-+++ b/Tests/output/test_Fasttree_tool
-@@ -0,0 +1,33 @@
-+test_Fasttree_tool
-+Checking error conditions
-+=========================
-+Empty file
-+Failed (good)
-+
-+Single sequence
-+Failed (good)
-+
-+Invalid sequence
-+Failed (good)
-+
-+Checking normal situations
-+==========================
-+
-+Calling fasttree on 'Quality/example.fasta' (with 3 records)
-+
-+Checking generation of tree terminals
-+Success
-+
-+Checking distances between tree terminals
-+Success
-+
-+Calling fasttree on 'Clustalw/temp horses.fasta' (with 10 records)
-+
-+Checking generation of tree terminals
-+Success
-+
-+Checking distances between tree terminals
-+Success
-+
-+Done
-+
Deleted: trunk/packages/python-biopython/trunk/debian/patches/biopython-from-pil-import-image.patch
===================================================================
--- trunk/packages/python-biopython/trunk/debian/patches/biopython-from-pil-import-image.patch 2014-06-08 08:29:42 UTC (rev 17064)
+++ trunk/packages/python-biopython/trunk/debian/patches/biopython-from-pil-import-image.patch 2014-06-08 11:53:35 UTC (rev 17065)
@@ -1,31 +0,0 @@
-Author: Jakub Wilk <jwilk at debian.org>
-Last-Update: Mon, 28 Apr 2014 15:39:59 +0200
-Description: Avoid python-imaging compatibility package
- python-imaging's description more or less says what you have to change:
- “PIL used to provide a PIL.pth file which allowed you to `import
- Image` but this is deprecated. Use `from PIL import Image` now, or
- install this compatibility package to temporarily get the old behavior
- back
-
---- a/Tests/test_GenomeDiagram.py
-+++ b/Tests/test_GenomeDiagram.py
-@@ -27,7 +27,7 @@ except ImportError:
- "Install reportlab if you want to use Bio.Graphics.")
-
- try:
-- import Image
-+ from PIL import Image
- from reportlab.graphics import renderPM
- except ImportError:
- #This is an optional part of ReportLab, so may not be installed.
---- a/Tests/test_GraphicsBitmaps.py
-+++ b/Tests/test_GraphicsBitmaps.py
-@@ -35,7 +35,7 @@ except:
- "bitmaps with Bio.Graphics.")
- try:
- # Skip the test if PIL is not installed
-- import Image as i
-+ from PIL import Image as i
- del i
- except:
- raise MissingPythonDependencyError(
Deleted: trunk/packages/python-biopython/trunk/debian/patches/fix_cpairwise2_import_issue.patch
===================================================================
--- trunk/packages/python-biopython/trunk/debian/patches/fix_cpairwise2_import_issue.patch 2014-06-08 08:29:42 UTC (rev 17064)
+++ trunk/packages/python-biopython/trunk/debian/patches/fix_cpairwise2_import_issue.patch 2014-06-08 11:53:35 UTC (rev 17065)
@@ -1,18 +0,0 @@
-Author: Peter Cock <p.j.a.cock at googlemail.com>
-Last-Update: Fri, 9 May 2014 13:36:32 +0100
-Bugs-Debian: http://bugs.debian.org/747494
-Bugs-Upstream: https://github.com/biopython/biopython/pull/299
-Description: fix cpairwise2 import issue under python3
- see https://github.com/biopython/biopython/commit/daf3e3b5ba317fbbea1f7eebae3c5f8b06a40d6b
-
---- a/Bio/pairwise2.py
-+++ b/Bio/pairwise2.py
-@@ -878,7 +878,7 @@ def format_alignment(align1, align2, sco
- # Try and load C implementations of functions. If I can't,
- # then just ignore and use the pure python implementations.
- try:
-- from cpairwise2 import rint, _make_score_matrix_fast
-+ from .cpairwise2 import rint, _make_score_matrix_fast
- except ImportError:
- pass
-
Deleted: trunk/packages/python-biopython/trunk/debian/patches/fix_test_emboss.patch
===================================================================
--- trunk/packages/python-biopython/trunk/debian/patches/fix_test_emboss.patch 2014-06-08 08:29:42 UTC (rev 17064)
+++ trunk/packages/python-biopython/trunk/debian/patches/fix_test_emboss.patch 2014-06-08 11:53:35 UTC (rev 17065)
@@ -1,15 +0,0 @@
-Author: Andreas Tille <tille at debian.org>
-Last-Update: Thu, 06 Mar 2014 11:51:27 +0100
-Description: Fix EMBOSS test to work with latest EMBOSS release
-
---- a/Tests/test_Emboss.py
-+++ b/Tests/test_Emboss.py
-@@ -73,6 +73,8 @@ def get_emboss_version():
- assert stderr is None # Send to stdout instead
- for line in stdout.split("\n"):
- if line.strip()=="Reports the current EMBOSS version number":
-+ pass
-+ elif line.strip()=="Report the current EMBOSS version number":
- pass
- elif line.startswith("Writes the current EMBOSS version number"):
- pass
Modified: trunk/packages/python-biopython/trunk/debian/patches/remove_mathml-qname.patch
===================================================================
--- trunk/packages/python-biopython/trunk/debian/patches/remove_mathml-qname.patch 2014-06-08 08:29:42 UTC (rev 17064)
+++ trunk/packages/python-biopython/trunk/debian/patches/remove_mathml-qname.patch 2014-06-08 11:53:35 UTC (rev 17065)
@@ -4,9 +4,9 @@
Forwarded-Upstream: yes
Description: Remove non DFSG free DTD
---- a/Bio/Entrez/DTDs/modules.ent
-+++ b/Bio/Entrez/DTDs/modules.ent
-@@ -350,13 +350,6 @@ Version Reason/Occasion
+--- biopython-1.64.orig/Bio/Entrez/DTDs/modules.ent
++++ biopython-1.64/Bio/Entrez/DTDs/modules.ent
+@@ -350,13 +350,6 @@
"mathmlsetup.ent" >
Modified: trunk/packages/python-biopython/trunk/debian/patches/series
===================================================================
--- trunk/packages/python-biopython/trunk/debian/patches/series 2014-06-08 08:29:42 UTC (rev 17064)
+++ trunk/packages/python-biopython/trunk/debian/patches/series 2014-06-08 11:53:35 UTC (rev 17065)
@@ -1,6 +1 @@
-fix_test_emboss.patch
-add_missing_test_Fasttree_tool.patch
-use_upstream_patch_for_bwa_test.patch
-biopython-from-pil-import-image.patch
remove_mathml-qname.patch
-fix_cpairwise2_import_issue.patch
Deleted: trunk/packages/python-biopython/trunk/debian/patches/use_upstream_patch_for_bwa_test.patch
===================================================================
--- trunk/packages/python-biopython/trunk/debian/patches/use_upstream_patch_for_bwa_test.patch 2014-06-08 08:29:42 UTC (rev 17064)
+++ trunk/packages/python-biopython/trunk/debian/patches/use_upstream_patch_for_bwa_test.patch 2014-06-08 11:53:35 UTC (rev 17065)
@@ -1,191 +0,0 @@
-Author: Saket Choudhary <saketkc at gmail.com>
-Last-Update: Tue, 29 Apr 2014 01:37:43 +0530
-Description: Skip bwa aln tests if it is an unrecognized command
-Comment: Taken over from upstream commit d884ee6e12a798b974b3a3996e22b5292ab79be6
-Forwarded-Upstream: yes
-
---- a/Tests/test_BWA_tool.py
-+++ b/Tests/test_BWA_tool.py
-@@ -9,12 +9,12 @@ from Bio import MissingExternalDependenc
- import sys
- import os
- import unittest
--from Bio import SeqIO
--from Bio import AlignIO
--from Bio.Sequencing.Applications import BwaIndexCommandline, BwaAlignCommandline
--from Bio.Sequencing.Applications import BwaSamseCommandline, BwaSampeCommandline
--from Bio.Sequencing.Applications import BwaBwaswCommandline
--from Bio.Application import ApplicationError
-+#TODO from Bio.Sequencing.Applications import BwaBwaswCommandline
-+from Bio.Sequencing.Applications import BwaIndexCommandline
-+from Bio.Sequencing.Applications import BwaAlignCommandline
-+from Bio.Sequencing.Applications import BwaSamseCommandline
-+from Bio.Sequencing.Applications import BwaSampeCommandline
-+
-
- #################################################################
-
-@@ -29,11 +29,8 @@ if sys.platform == "win32":
- prog_files = os.environ["PROGRAMFILES"]
- except KeyError:
- prog_files = r"C:\Program Files"
-- #A default path of C:\Program Files\bwa.exe was chosen
-- #but this path can be edited depending on where bwa is located
--
-- likely_dirs = ["bwa", "BWA", "Bwa", "bwa-0.6.2"]
-- likely_exes = ["bwa.exe", "BWA.exe", "Bwa.exe"]
-+ likely_dirs = ["bwa", "bwa-0.6.2", ""]
-+ likely_exes = ["bwa"]
- for folder in likely_dirs:
- if os.path.isdir(os.path.join(prog_files, folder)):
- for filename in likely_exes:
-@@ -50,52 +47,96 @@ else:
- #really the bwa tool's output
- bwa_found = False
- if "not found" not in output and "bwa" in output \
-- and "alignment via Burrows-Wheeler transformation" in output:
-+ and "alignment via Burrows-Wheeler transformation" in output:
- bwa_exe = "bwa"
-
- if not bwa_exe:
-- raise MissingExternalDependencyError(\
-- "Install bwa and correctly set the file path to the program if you want to use it from Biopython")
-+ raise MissingExternalDependencyError("Install bwa and correctly set"
-+ " the file path to the program if"
-+ " you want to use it from Biopython")
-
-
- class BwaTestCase(unittest.TestCase):
- """Class for implementing BWA test cases"""
- def setUp(self):
-- self.reference_file = os.path.join(os.path.dirname(os.path.abspath(__file__)), "BWA", "human_g1k_v37_truncated.fasta")
-- self.infile1 = os.path.join(os.path.dirname(os.path.abspath(__file__)), "BWA", "HNSCC1_1_truncated.fastq")
-- self.infile2 = os.path.join(os.path.dirname(os.path.abspath(__file__)), "BWA", "HNSCC1_2_truncated.fastq")
-- self.saifile1 = os.path.join(os.path.dirname(os.path.abspath(__file__)), "BWA", "1.sai")
-- self.saifile2 = os.path.join(os.path.dirname(os.path.abspath(__file__)), "BWA", "2.sai")
-- self.samfile1 = os.path.join(os.path.dirname(os.path.abspath(__file__)), "BWA", "1.sam")
-- self.samfile2 = os.path.join(os.path.dirname(os.path.abspath(__file__)), "BWA", "2.sam")
-- self.samfile = os.path.join(os.path.dirname(os.path.abspath(__file__)), "BWA", "out.sam")
-+ self.reference_file = "BWA/human_g1k_v37_truncated.fasta"
-+ self.reference_extensions = ['amb', 'ann', 'bwt', 'pac', 'sa']
-+ self.infile1 = "BWA/HNSCC1_1_truncated.fastq"
-+ self.infile2 = "BWA/HNSCC1_2_truncated.fastq"
-+ self.saifile1 = "BWA/1.sai"
-+ self.saifile2 = "BWA/2.sai"
-+ self.samfile1 = "BWA/1.sam"
-+ self.samfile2 = "BWA/2.sam"
-+ self.samfile = "BWA/out.sam"
-+ self.files_to_clean = [self.saifile1, self.saifile2,
-+ self.samfile1, self.samfile2,
-+ self.samfile]
-+
-+ def tearDown(self):
-+ for filename in self.files_to_clean:
-+ if os.path.isfile(filename):
-+ os.remove(filename)
-+ for extension in self.reference_extensions:
-+ index_file = self.reference_file + "." + extension
-+ if os.path.exists(index_file):
-+ os.remove(index_file)
-
- def test_index(self):
- """Test for creating index files for the reference genome fasta file"""
-- cmdline = BwaIndexCommandline()
-+ cmdline = BwaIndexCommandline(bwa_exe)
- cmdline.set_parameter("infile", self.reference_file)
- cmdline.set_parameter("algorithm", "bwtsw")
- stdout, stderr = cmdline()
-- output = stdout.startswith("[bwt_gen]")
-+ for extension in self.reference_extensions:
-+ index_file = self.reference_file + "." + extension
-+ self.assertTrue(os.path.exists(index_file),
-+ "Index File %s not found"
-+ % (index_file))
- self.assertTrue(stdout.startswith("[bwt_gen]"),
-- "FASTA indexing failed:\n%s\nStdout:%s" \
-+ "FASTA indexing failed:\n%s\nStdout:%s"
- % (cmdline, stdout))
-
- def do_aln(self, in_file, out_file):
- """Test for generating sai files given the reference and read file"""
-- cmdline = BwaAlignCommandline()
-+ cmdline = BwaAlignCommandline(bwa_exe)
- cmdline.set_parameter("reference", self.reference_file)
- cmdline.read_file = in_file
- self.assertTrue(os.path.isfile(in_file))
- stdout, stderr = cmdline(stdout=out_file)
-
- self.assertTrue("fail to locate the index" not in stderr,
-- "Error aligning sequence to reference:\n%s\nStderr:%s" \
-+ "Error aligning sequence to reference:\n%s\nStderr:%s"
- % (cmdline, stderr))
-
-+ def skip_aln_tests(self):
-+ """As reported on http://lists.open-bio.org/pipermail/biopython-dev/2014-April/011342.html
-+ 'bwa aln' is failing for bwa[0.7.6a-r433]
-+ Tests using 'aln' should be skipped in that case"""
-+
-+ aln_output = getoutput("bwa aln")
-+ if "unrecognized" in aln_output:
-+ return True
-+ return False
-+
-+ def create_fasta_index(self):
-+ """Creates index for fasta file
-+ BWA requires an indexed fasta for each alignment operation.
-+ This should be called to create an index before any alignment
-+ operation.
-+
-+ """
-+ cmdline = BwaIndexCommandline(bwa_exe)
-+ cmdline.set_parameter("infile", self.reference_file)
-+ cmdline.set_parameter("algorithm", "bwtsw")
-+ stdout, stderr = cmdline()
-+
- def test_samse(self):
- """Test for single end sequencing """
-- cmdline = BwaSamseCommandline()
-+ if self.skip_aln_tests():
-+ return
-+ self.create_fasta_index()
-+ self.do_aln(self.infile1, self.saifile1)
-+ cmdline = BwaSamseCommandline(bwa_exe)
- cmdline.set_parameter("reference", self.reference_file)
- cmdline.set_parameter("read_file", self.infile1)
- cmdline.set_parameter("sai_file", self.saifile1)
-@@ -104,16 +145,20 @@ class BwaTestCase(unittest.TestCase):
- with open(self.samfile1, "r") as handle:
- headline = handle.readline()
- self.assertTrue(headline.startswith("@SQ"),
-- "Error generating sam files:\n%s\nOutput starts:%s" \
-+ "Error generating sam files:\n%s\nOutput starts:%s"
- % (cmdline, headline))
-
- def test_sampe(self):
- """Test for generating samfile by paired end sequencing"""
-+ if self.skip_aln_tests():
-+ return
-+ self.create_fasta_index()
-+
- ##Generate sai files from paired end data
- self.do_aln(self.infile1, self.saifile1)
- self.do_aln(self.infile2, self.saifile2)
-
-- cmdline = BwaSampeCommandline()
-+ cmdline = BwaSampeCommandline(bwa_exe)
- cmdline.set_parameter("reference", self.reference_file)
- cmdline.set_parameter("sai_file1", self.saifile1)
- cmdline.set_parameter("sai_file2", self.saifile2)
-@@ -124,10 +169,11 @@ class BwaTestCase(unittest.TestCase):
- with open(self.samfile, "r") as handle:
- headline = handle.readline()
- self.assertTrue(headline.startswith("@SQ"),
-- "Error generating sam files:\n%s\nOutput starts:%s" \
-+ "Error generating sam files:\n%s\nOutput starts:%s"
- % (cmdline, headline))
-
-
- if __name__ == "__main__":
- runner = unittest.TextTestRunner(verbosity=2)
- unittest.main(testRunner=runner)
-+
More information about the debian-med-commit
mailing list