Gentoo Archives: gentoo-commits

From: David Seifert <soap@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: dev-python/whoosh/, dev-python/whoosh/files/
Date: Sun, 05 Feb 2017 14:03:14
Message-Id: 1486303340.6c74c78e513232f9efec5ab11a7ed4ffde0c3c8d.soap@gentoo
1 commit: 6c74c78e513232f9efec5ab11a7ed4ffde0c3c8d
2 Author: David Seifert <soap <AT> gentoo <DOT> org>
3 AuthorDate: Sun Feb 5 14:01:39 2017 +0000
4 Commit: David Seifert <soap <AT> gentoo <DOT> org>
5 CommitDate: Sun Feb 5 14:02:20 2017 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=6c74c78e
7
8 dev-python/whoosh: Specify UTF-8 encoding for tests
9
10 Gentoo-bug: 608324
11
12 Package-Manager: Portage-2.3.3, Repoman-2.3.1
13
14 dev-python/whoosh/Manifest | 2 +-
15 .../files/whoosh-2.7.4-tests-specify-utf8.patch | 13 +++++++++
16 dev-python/whoosh/whoosh-2.7.4.ebuild | 34 +++++++++++-----------
17 3 files changed, 31 insertions(+), 18 deletions(-)
18
19 diff --git a/dev-python/whoosh/Manifest b/dev-python/whoosh/Manifest
20 index eb191d2..1e6e7e8 100644
21 --- a/dev-python/whoosh/Manifest
22 +++ b/dev-python/whoosh/Manifest
23 @@ -1,3 +1,3 @@
24 DIST Whoosh-2.6.0.zip 1193541 SHA256 7de7bc4d00a6d051dbb360b48eb7f3cd002373d87252fb0b284a3c9c453a7677 SHA512 e50e47ec0d1c65ad3c7d657586f5380a1be748945c1ce964305fa68b99379f0da676faef6f0ca45ef151df7be71150601162ee966f3aaf84047a20bca36f7e37 WHIRLPOOL c42e9760833db7186f3df5946f6dd071288cfccf2eaefba95520a2415ca377c49cf74307b3fa2c9e655f134b086ae637e5db06330248b4a27e12175920f3c7b8
25 DIST Whoosh-2.7.3.zip 1097515 SHA256 aa6db447522e208ae652c6ce063bb23cedec47f5ed630121b3debaa011fcb9c4 SHA512 3df18ed30f63aaa9f858d596919fa8a927f7203a52bdb4c584117b28bce313cbbb530cdb144e35af99763edbbc7d3f5c79680d04fa7c04efa91376ba62b6f556 WHIRLPOOL 1829fd083485367dd0751844c77e5f7e8c8edee4021b8518415ab6cd6f8db84b5f2f188d6e2128a105cfd8076d8101c1421838ac18f10cd632c64eed5828a44e
26 -DIST Whoosh-2.7.4.zip 1097662 SHA256 e0857375f63e9041e03fedd5b7541f97cf78917ac1b6b06c1fcc9b45375dda69 SHA512 8ea2f10152b0eb9fbf516a3faeed5a466216eb468f0e4b88d156591d5a36c5dc7d3408928bbd693de98bb0351b9c33cc62900c13ea56d3b3d989c1a4bbeba139 WHIRLPOOL 56622fc1049c2bfefdb4ec49e4784e7d751837cdd0cc379e7eb737da34a2dc0c6d3e7e85696ba0be60c3dd55f1981b6473391555d3851c82b7e816bab20db5d8
27 +DIST Whoosh-2.7.4.tar.gz 968741 SHA256 7ca5633dbfa9e0e0fa400d3151a8a0c4bec53bd2ecedc0a67705b17565c31a83 SHA512 7cdefdcf52b704ffe50c00718c42677e2ddfe879f81ad2d14b580b0e026cc0ebb6b9ddc99d8709eaff4eb9b83f654b042c8792821e1ed90aa85cfa6f82845074 WHIRLPOOL 2f077eb84fc89ff03babdd7adb25bf04ca03811a21f9ac987854c158fdd0b31f25d30ad59c9299a2da4b7ed982e2d292eeab781c10c9062e878ac0f8454115ed
28
29 diff --git a/dev-python/whoosh/files/whoosh-2.7.4-tests-specify-utf8.patch b/dev-python/whoosh/files/whoosh-2.7.4-tests-specify-utf8.patch
30 new file mode 100644
31 index 00000000..94636c1
32 --- /dev/null
33 +++ b/dev-python/whoosh/files/whoosh-2.7.4-tests-specify-utf8.patch
34 @@ -0,0 +1,13 @@
35 +Python 2 requires specifying the file encoding
36 +See also:
37 +https://www.python.org/dev/peps/pep-0263/
38 +https://bugs.gentoo.org/show_bug.cgi?id=608324
39 +
40 +--- a/tests/test_reading.py
41 ++++ b/tests/test_reading.py
42 +@@ -1,3 +1,5 @@
43 ++# -*- coding: utf-8 -*-
44 ++
45 + from __future__ import with_statement
46 + import random, threading, time
47 +
48
49 diff --git a/dev-python/whoosh/whoosh-2.7.4.ebuild b/dev-python/whoosh/whoosh-2.7.4.ebuild
50 index b89e1c6..b580f97 100644
51 --- a/dev-python/whoosh/whoosh-2.7.4.ebuild
52 +++ b/dev-python/whoosh/whoosh-2.7.4.ebuild
53 @@ -2,28 +2,31 @@
54 # Distributed under the terms of the GNU General Public License v2
55 # $Id$
56
57 -EAPI="5"
58 +EAPI=6
59
60 -PYTHON_COMPAT=( python{2_7,3_4,3_5} pypy )
61 -
62 -MY_PN="Whoosh"
63 +PYTHON_COMPAT=( python2_7 python{3_4,3_5} pypy )
64
65 inherit distutils-r1
66
67 DESCRIPTION="Fast, pure-Python full text indexing, search and spell checking library"
68 HOMEPAGE="https://bitbucket.org/mchaput/whoosh/wiki/Home/ https://pypi.python.org/pypi/Whoosh/"
69 -SRC_URI="mirror://pypi/W/${MY_PN}/${MY_PN}-${PV}.zip"
70 -
71 -DEPEND="app-arch/unzip
72 - dev-python/setuptools[${PYTHON_USEDEP}]
73 - test? ( dev-python/pytest[${PYTHON_USEDEP}] )"
74 +SRC_URI="mirror://pypi/W/${PN^}/${P^}.tar.gz"
75
76 LICENSE="BSD-2"
77 SLOT="0"
78 KEYWORDS="~alpha ~amd64 ~hppa ~x86"
79 IUSE="doc test"
80
81 -S="${WORKDIR}/${MY_PN}-${PV}"
82 +DEPEND="
83 + dev-python/setuptools[${PYTHON_USEDEP}]
84 + doc? ( dev-python/sphinx )
85 + test? ( dev-python/pytest[${PYTHON_USEDEP}] )"
86 +
87 +S="${WORKDIR}/${P^}"
88 +
89 +PATCHES=(
90 + "${FILESDIR}"/${PN}-2.7.4-tests-specify-utf8.patch
91 +)
92
93 python_prepare_all() {
94 # (backport from upstream)
95 @@ -37,7 +40,10 @@ python_prepare_all() {
96
97 python_compile_all() {
98 # https://bitbucket.org/mchaput/whoosh/issue/403/
99 - use doc && sphinx-build -b html -c docs/source/ docs/source/ docs/source/build/html
100 + if use doc; then
101 + sphinx-build -b html -c docs/source/ docs/source/ docs/source/build/html || die
102 + HTML_DOCS=( docs/source/build/html/. )
103 + fi
104 }
105
106 python_test() {
107 @@ -45,9 +51,3 @@ python_test() {
108 # tarball missing a file english-words.10.gz which when added sees all tests pass.
109 esetup.py test
110 }
111 -
112 -python_install_all() {
113 - local DOCS=( README.txt )
114 - use doc && local HTML_DOCS=( docs/source/build/html/. )
115 - distutils-r1_python_install_all
116 -}