1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25
|
Description: Open files using UTF-8
When trying to install the module for use with Python 3 the setup.py stumbles
upon an umlaut in jsonpointer.py which causes a FTBFS.
Author: Michael Bienia <geser@ubuntu.com>
Bug-Ubuntu: https://bugs.launchpad.net/bug/1185170
Forwarded: no
Last-Update: 2013-05-28
Index: python-json-pointer-1.0/setup.py
===================================================================
--- python-json-pointer-1.0.orig/setup.py 2013-04-03 15:42:02.000000000 +0200
+++ python-json-pointer-1.0/setup.py 2013-05-29 00:09:40.000000000 +0200
@@ -3,10 +3,11 @@
from distutils.core import setup
import re
import os.path
+import io
dirname = os.path.dirname(os.path.abspath(__file__))
filename = os.path.join(dirname, 'jsonpointer.py')
-src = open(filename).read()
+src = io.open(filename, encoding='utf-8').read()
metadata = dict(re.findall("__([a-z]+)__ = '([^']+)'", src))
docstrings = re.findall('"""(.*)"""', src)
|