1 |
commit: c2e747d2d09a994683ba80ce40b941153acbf650 |
2 |
Author: Michał Górny <mgorny <AT> gentoo <DOT> org> |
3 |
AuthorDate: Thu Jul 30 20:33:38 2020 +0000 |
4 |
Commit: Michał Górny <mgorny <AT> gentoo <DOT> org> |
5 |
CommitDate: Thu Jul 30 20:40:43 2020 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=c2e747d2 |
7 |
|
8 |
dev-python/rdflib: Remove old |
9 |
|
10 |
Signed-off-by: Michał Górny <mgorny <AT> gentoo.org> |
11 |
|
12 |
dev-python/rdflib/Manifest | 1 - |
13 |
.../rdflib-4.2.2-python3.7-StopIteration.patch | 72 ----------------- |
14 |
dev-python/rdflib/metadata.xml | 3 - |
15 |
dev-python/rdflib/rdflib-4.2.2-r1.ebuild | 93 ---------------------- |
16 |
4 files changed, 169 deletions(-) |
17 |
|
18 |
diff --git a/dev-python/rdflib/Manifest b/dev-python/rdflib/Manifest |
19 |
index a905e635164..3f0092e6d69 100644 |
20 |
--- a/dev-python/rdflib/Manifest |
21 |
+++ b/dev-python/rdflib/Manifest |
22 |
@@ -1,2 +1 @@ |
23 |
-DIST rdflib-4.2.2.tar.gz 905094 BLAKE2B fe17b5752f67c745bfdf4a160c2f5d49da19f0d85b6eddc4a65fa0ddb660de8bcc19c3ccecf893fb67f725b973cb94481374d9ee0c82072416a93e44952dba9b SHA512 efc24d8ce1080e59950cecc9c779ae0d63673c8690f74db1772f6c2dbf24d6f4de5214d5870a074bffe549b42d8d5f5d131df29bbfd174b763ae1f843aec7d5c |
24 |
DIST rdflib-5.0.0.tar.gz 818586 BLAKE2B d0046590b00211ccb4f0f586dc829c061a5f426b1cefed44a63d21d46396354b9012dbe0a63c8f9de138b25ca7d73ba624c49da6fb305ececd983c62c917fd8a SHA512 ba98ab6a7bb9d993d11c559a739761f297282eb9307f3e333db8dd1c6b365b408a59b701d823bef9be774a59b3f44f64c9444e3bb0115c0c549cb00945385dab |
25 |
|
26 |
diff --git a/dev-python/rdflib/files/rdflib-4.2.2-python3.7-StopIteration.patch b/dev-python/rdflib/files/rdflib-4.2.2-python3.7-StopIteration.patch |
27 |
deleted file mode 100644 |
28 |
index 389d220dc1b..00000000000 |
29 |
--- a/dev-python/rdflib/files/rdflib-4.2.2-python3.7-StopIteration.patch |
30 |
+++ /dev/null |
31 |
@@ -1,72 +0,0 @@ |
32 |
-Traceback (most recent call last): |
33 |
- File "/var/tmp/portage/dev-python/rdflib-4.2.2/work/rdflib-4.2.2-python3_7/build/src/rdflib/plugins/sparql/evaluate.py", line 330, in evalSlice |
34 |
- next(res) |
35 |
-StopIteration |
36 |
- |
37 |
-The above exception was the direct cause of the following exception: |
38 |
- |
39 |
-Traceback (most recent call last): |
40 |
- File "/usr/lib/python3.7/site-packages/nose/case.py", line 197, in runTest |
41 |
- self.test(*self.arg) |
42 |
- File "/var/tmp/portage/dev-python/rdflib-4.2.2/work/rdflib-4.2.2-python3_7/build/src/test/test_dawg.py", line 434, in query_test |
43 |
- set(res2) |
44 |
- File "/var/tmp/portage/dev-python/rdflib-4.2.2/work/rdflib-4.2.2-python3_7/build/src/rdflib/query.py", line 258, in __iter__ |
45 |
- for b in self._genbindings: |
46 |
-RuntimeError: generator raised StopIteration |
47 |
- |
48 |
-Patch backported from |
49 |
-https://github.com/RDFLib/rdflib/commit/58c45d6f30af88a22f60edcb9a459648a885e226 |
50 |
- |
51 |
---- a/rdflib/plugins/sparql/evaluate.py |
52 |
-+++ b/rdflib/plugins/sparql/evaluate.py |
53 |
-@@ -15,6 +15,7 @@ |
54 |
- """ |
55 |
- |
56 |
- import collections |
57 |
-+import itertools |
58 |
- |
59 |
- from rdflib import Variable, Graph, BNode, URIRef, Literal |
60 |
- |
61 |
-@@ -323,22 +324,9 @@ |
62 |
- |
63 |
- |
64 |
- def evalSlice(ctx, slice): |
65 |
-- # import pdb; pdb.set_trace() |
66 |
- res = evalPart(ctx, slice.p) |
67 |
-- i = 0 |
68 |
-- while i < slice.start: |
69 |
-- res.next() |
70 |
-- i += 1 |
71 |
-- i = 0 |
72 |
-- for x in res: |
73 |
-- i += 1 |
74 |
-- if slice.length is None: |
75 |
-- yield x |
76 |
-- else: |
77 |
-- if i <= slice.length: |
78 |
-- yield x |
79 |
-- else: |
80 |
-- break |
81 |
-+ |
82 |
-+ return itertools.islice(res, slice.start, slice.start+slice.length if slice.length is not None else None) |
83 |
- |
84 |
- |
85 |
- def evalReduced(ctx, part): |
86 |
---- a/rdflib/query.py |
87 |
-+++ b/rdflib/query.py |
88 |
-@@ -1,5 +1,6 @@ |
89 |
- |
90 |
- import os |
91 |
-+import itertools |
92 |
- import shutil |
93 |
- import tempfile |
94 |
- import warnings |
95 |
-@@ -181,7 +182,7 @@ |
96 |
- return self._bindings |
97 |
- |
98 |
- def _set_bindings(self, b): |
99 |
-- if isinstance(b, types.GeneratorType): |
100 |
-+ if isinstance(b, (types.GeneratorType, itertools.islice)): |
101 |
- self._genbindings = b |
102 |
- self._bindings = [] |
103 |
- else: |
104 |
|
105 |
diff --git a/dev-python/rdflib/metadata.xml b/dev-python/rdflib/metadata.xml |
106 |
index c27203b015b..b6848176643 100644 |
107 |
--- a/dev-python/rdflib/metadata.xml |
108 |
+++ b/dev-python/rdflib/metadata.xml |
109 |
@@ -6,9 +6,6 @@ |
110 |
<name>Python</name> |
111 |
</maintainer> |
112 |
<stabilize-allarches/> |
113 |
- <use> |
114 |
- <flag name="redland">enable support for Redland triplestore</flag> |
115 |
- </use> |
116 |
<upstream> |
117 |
<remote-id type="pypi">rdflib</remote-id> |
118 |
<remote-id type="github">RDFLib/rdflib</remote-id> |
119 |
|
120 |
diff --git a/dev-python/rdflib/rdflib-4.2.2-r1.ebuild b/dev-python/rdflib/rdflib-4.2.2-r1.ebuild |
121 |
deleted file mode 100644 |
122 |
index a6eb50c7d38..00000000000 |
123 |
--- a/dev-python/rdflib/rdflib-4.2.2-r1.ebuild |
124 |
+++ /dev/null |
125 |
@@ -1,93 +0,0 @@ |
126 |
-# Copyright 1999-2020 Gentoo Authors |
127 |
-# Distributed under the terms of the GNU General Public License v2 |
128 |
- |
129 |
-EAPI=7 |
130 |
- |
131 |
-DISTUTILS_USE_SETUPTOOLS=rdepend |
132 |
-PYTHON_COMPAT=( python3_{6..9} ) |
133 |
-PYTHON_REQ_USE="sqlite?,threads(+)" |
134 |
- |
135 |
-# The usual required for tests |
136 |
-DISTUTILS_IN_SOURCE_BUILD=1 |
137 |
- |
138 |
-inherit distutils-r1 |
139 |
- |
140 |
-DESCRIPTION="RDF library containing a triple store and parser/serializer" |
141 |
-HOMEPAGE="https://github.com/RDFLib/rdflib https://pypi.org/project/rdflib/" |
142 |
-SRC_URI="mirror://pypi/${PN:0:1}/${PN}/${P}.tar.gz" |
143 |
- |
144 |
-LICENSE="BSD" |
145 |
-SLOT="0" |
146 |
-KEYWORDS="~alpha amd64 arm arm64 ~hppa ~ia64 ~mips ppc ppc64 sparc x86 ~amd64-linux ~x86-linux" |
147 |
-IUSE="doc berkdb examples redland sqlite test" |
148 |
-RESTRICT="!test? ( test )" |
149 |
- |
150 |
-RDEPEND=" |
151 |
- dev-python/isodate[${PYTHON_USEDEP}] |
152 |
- dev-python/html5lib[${PYTHON_USEDEP}] |
153 |
- dev-python/pyparsing[${PYTHON_USEDEP}] |
154 |
- berkdb? ( dev-python/bsddb3[${PYTHON_USEDEP}] ) |
155 |
- redland? ( dev-libs/redland-bindings[python,${PYTHON_USEDEP}] )" |
156 |
-DEPEND="${RDEPEND} |
157 |
- doc? ( dev-python/sphinx[${PYTHON_USEDEP}] ) |
158 |
- test? ( |
159 |
- dev-python/sparql-wrapper[${PYTHON_USEDEP}] |
160 |
- >=dev-python/nose-1.3.1-r1[${PYTHON_USEDEP}] |
161 |
- )" |
162 |
- |
163 |
-PATCHES=( |
164 |
- # Python 3.7 StopIteration bug |
165 |
- "${FILESDIR}"/${PN}-4.2.2-python3.7-StopIteration.patch |
166 |
-) |
167 |
- |
168 |
-python_prepare_all() { |
169 |
- # Upstream manufactured .pyc files which promptly break distutils' src_test |
170 |
- find -name "*.py[oc~]" -delete || die |
171 |
- |
172 |
- # Bug 358189; take out tests that attempt to connect to the network |
173 |
- sed -e "/'--with-doctest',/d" -e "/'--doctest-extension=.doctest',/d" \ |
174 |
- -e "/'--doctest-tests',/d" -i run_tests.py || die |
175 |
- |
176 |
- sed -e "s: 'sphinx.ext.intersphinx',::" -i docs/conf.py || die |
177 |
- |
178 |
- # doc build requires examples folder at the upper level of docs |
179 |
- if use doc; then |
180 |
- cd docs || die |
181 |
- ln -sf ../examples . || die |
182 |
- cd ../ || die |
183 |
- fi |
184 |
- |
185 |
- distutils-r1_python_prepare_all |
186 |
-} |
187 |
- |
188 |
-python_compile_all() { |
189 |
- # https://github.com/RDFLib/rdflib/issues/510 |
190 |
- if use doc; then |
191 |
- einfo "" |
192 |
- einfo "Several warnings and Errors present in the build" |
193 |
- einfo "For a complete build, it is required to install" |
194 |
- einfo "github.com/gjhiggins/n3_pygments_lexer and" |
195 |
- einfo "github.com/gjhiggins/sparql_pygments_lexer" |
196 |
- einfo "outside portage via pip or by cloning. These have not been" |
197 |
- einfo "given a tagged release by the author and are not in portage" |
198 |
- einfo "" |
199 |
- |
200 |
- emake -C docs html |
201 |
- HTML_DOCS=( docs/_build/html/. ) |
202 |
- fi |
203 |
-} |
204 |
- |
205 |
-python_test() { |
206 |
- pushd "${BUILD_DIR}/src/" >/dev/null || die |
207 |
- "${EPYTHON}" ./run_tests.py -v || die "Tests failed under ${EPYTHON}" |
208 |
- popd >/dev/null || die |
209 |
-} |
210 |
- |
211 |
-python_install_all() { |
212 |
- distutils-r1_python_install_all |
213 |
- |
214 |
- if use examples; then |
215 |
- dodoc -r examples |
216 |
- docompress -x /usr/share/doc/${PF}/examples |
217 |
- fi |
218 |
-} |