Package: bottleneck / 1.2.1+ds1-2

Enable-build-of-docs-with-Python-3.patch Patch series | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
From: Ghislain Antony Vaillant <ghisvail@users.noreply.github.com>
Date: Sun, 4 Jun 2017 13:41:04 +0100
Subject: Enable build of docs with Python 3

`file()` is no longer a built-in in Python 3. It is better to just use a single call to `open` chained with a `read`.
---
 doc/source/conf.py | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/doc/source/conf.py b/doc/source/conf.py
index 21d4d3c..2dfa7bc 100644
--- a/doc/source/conf.py
+++ b/doc/source/conf.py
@@ -43,9 +43,7 @@ copyright = u'2010-2017 Keith Goodman'
 
 # Grab version from bottleneck/version.py
 ver_file = os.path.join('..', '..', 'bottleneck', 'version.py')
-fid = file(ver_file, 'r')
-VER = fid.read()
-fid.close()
+VER = open(ver_file, 'r').read()
 VER = VER.split("= ")
 VER = VER[1].strip()
 VER = VER.strip('"')