[med-svn] [python-biotools] 01/02: Add 2to3 patch

Andreas Tille tille at debian.org
Thu Mar 2 12:36:51 UTC 2017


This is an automated email from the git hooks/post-receive script.

tille pushed a commit to branch master
in repository python-biotools.

commit 09882227edb5c0f68ea5574ff9b2fca96aa6ad48
Author: Andreas Tille <tille at debian.org>
Date:   Thu Mar 2 13:31:07 2017 +0100

    Add 2to3 patch
---
 debian/patches/2to3.patch | 32 ++++++++++++++++++++++++++++++++
 debian/patches/series     |  1 +
 2 files changed, 33 insertions(+)

diff --git a/debian/patches/2to3.patch b/debian/patches/2to3.patch
new file mode 100644
index 0000000..ce87b3d
--- /dev/null
+++ b/debian/patches/2to3.patch
@@ -0,0 +1,32 @@
+--- a/src/analysis/report.py
++++ b/src/analysis/report.py
+@@ -43,7 +43,7 @@ def plot(plotdata, directory, bottom=Tru
+     ax.minorticks_on()
+     ax.tick_params(axis='x', which='minor', length=3)
+ 
+-    for loc, spine in ax.spines.iteritems():
++    for loc, spine in ax.spines.items():
+         if loc in ['right', 'top']:
+             spine.set_color('none')
+             continue
+@@ -74,7 +74,7 @@ def plot(plotdata, directory, bottom=Tru
+     ys = (np.arange(len(starts)) + 1) * lowerbound / 3
+ 
+     ax.hlines(ys, starts, ends, colors='k', lw=4, linestyle='solid')
+-    for i, c in zip(xrange(len(counts)), counts):
++    for i, c in zip(range(len(counts)), counts):
+         ax.text(laa + 10, lowerbound / 3 * (i + 1.25), c)
+     if legend:
+         fig.legend((nt_lines, aa_lines), ('Nucleotide', 'Amino acid'),
+@@ -83,7 +83,7 @@ def plot(plotdata, directory, bottom=Tru
+     if save:
+         fig.savefig(directory + filename)
+ 
+-    print '=============', filename, '============='
+-    print 'Average variance: '
+-    print '\t', sum(snpdata['nt']['var']) / lnt, 'per base pair'
+-    print '\t', sum(snpdata['aa']['var']) / laa, 'per amino acid'
++    print('=============', filename, '=============')
++    print('Average variance: ')
++    print('\t', sum(snpdata['nt']['var']) / lnt, 'per base pair')
++    print('\t', sum(snpdata['aa']['var']) / laa, 'per amino acid')
diff --git a/debian/patches/series b/debian/patches/series
new file mode 100644
index 0000000..998d10f
--- /dev/null
+++ b/debian/patches/series
@@ -0,0 +1 @@
+2to3.patch

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/debian-med/python-biotools.git



More information about the debian-med-commit mailing list