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

lunar pushed a commit to branch pu/reproducible_builds
in repository dh-python.

commit 55948d9c95fb2a626e4763f1abf268a3d4ffe6e2
Author: B. Clausius <ba...@gmx.de>
Date:   Mon Sep 9 22:19:08 2013 +0200

    pybuild: fix --test when LC_ALL=C and setup.py contains non-ascii character
    
    To reproduce:
    1) setup.py contains non ascii character (e.g. copyright symbol)
    2) LC_ALL=C (e.g. in pbuilder)
---
 debian/changelog                   | 4 ++++
 dhpython/build/plugin_distutils.py | 4 ++--
 2 files changed, 6 insertions(+), 2 deletions(-)

diff --git a/debian/changelog b/debian/changelog
index 992c292..6767d28 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -6,6 +6,10 @@ dh-python (1.20130913-1) UNRELEASED; urgency=low
   [ Steve Langasek ]
   * Adjust dh_python to be multiarch-friendly (closes: 722045)
 
+  [ B. Clausius ]
+  * pybuild: fix --test when LC_ALL=C and setup.py contains non-ascii
+    characters (closes: 722214)
+
  -- Piotr Ożarowski <pi...@debian.org>  Fri, 06 Sep 2013 20:27:05 +0200
 
 dh-python (1.20130903-1) unstable; urgency=low
diff --git a/dhpython/build/plugin_distutils.py 
b/dhpython/build/plugin_distutils.py
index 5c76c13..b50dbd6 100644
--- a/dhpython/build/plugin_distutils.py
+++ b/dhpython/build/plugin_distutils.py
@@ -105,8 +105,8 @@ class BuildSystem(Base):
     def test(self, context, args):
         if not self.cfg.custom_tests:
             fpath = join(args['dir'], args['setup_py'])
-            with open(fpath) as fp:
-                if fp.read().find('test_suite') > 0:
+            with open(fpath, 'rb') as fp:
+                if fp.read().find(b'test_suite') > 0:
                     # TODO: is that enough to detect if test target is 
available?
                     return '{interpreter} {setup_py} test {args}'
         return super(BuildSystem, self).test(context, args)

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

_______________________________________________
Reproducible-builds mailing list
Reproducible-builds@lists.alioth.debian.org
http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/reproducible-builds

Reply via email to