Gentoo Archives: gentoo-commits

From: "Michał Górny" <mgorny@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: dev-python/pandas/
Date: Tue, 09 Feb 2021 14:16:35
Message-Id: 1612880189.a7c99693c2e94e5d8582471d3094c92f8144f606.mgorny@gentoo
1 commit: a7c99693c2e94e5d8582471d3094c92f8144f606
2 Author: Michał Górny <mgorny <AT> gentoo <DOT> org>
3 AuthorDate: Tue Feb 9 13:33:49 2021 +0000
4 Commit: Michał Górny <mgorny <AT> gentoo <DOT> org>
5 CommitDate: Tue Feb 9 14:16:29 2021 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=a7c99693
7
8 dev-python/pandas: Bump to 1.2.2
9
10 Signed-off-by: Michał Górny <mgorny <AT> gentoo.org>
11
12 dev-python/pandas/Manifest | 1 +
13 dev-python/pandas/pandas-1.2.2.ebuild | 186 ++++++++++++++++++++++++++++++++++
14 2 files changed, 187 insertions(+)
15
16 diff --git a/dev-python/pandas/Manifest b/dev-python/pandas/Manifest
17 index 38c28feaba3..e20c78541e1 100644
18 --- a/dev-python/pandas/Manifest
19 +++ b/dev-python/pandas/Manifest
20 @@ -1,2 +1,3 @@
21 DIST pandas-1.1.5.tar.gz 5229894 BLAKE2B 5b47774e33c7fccd7a9110e8971e8ce63cafd68273ee870b386aa8562be4c8f667137a4a078eafb2a62847bdd6f73c390254e8024d483c21e1834a8c49d44d32 SHA512 a213690ea658554b78e003a30cc88a59e34195457401d84b1cafdf74433ad27c801c12b8138371bb0206f6dc083ae882eabf0e33cb5733fa313e9f3257d48823
22 DIST pandas-1.2.1.tar.gz 5459053 BLAKE2B 49d99e7217d52f1233cdff20628da9028b7a8ce1d89a5ebe502c6e960ca9f7948005e7a63a15b76f9bc44ab5f15e00eef86c3b3179e6cad820e6f5072c7c78f0 SHA512 9bf9212ebdd07785f1877f5f80d6a5beb4637e8a1cf741e32a705a48724280a8e8daae209c66c1a3f00718b566127d77af578d6c72a5d9b68e2b03784c604083
23 +DIST pandas-1.2.2.tar.gz 5463571 BLAKE2B e27e032bb9d6abb6f40d1a15bc7e9796690f0bd099e5fc7704cbd5b40b37c0f277b462116bd7582263abef8f728d3109f6c4c425cac427f0c750b019fd5e8ad8 SHA512 288ec9f3a2042c2a376340ddc25b4e2d9d3c4de146468316378269d4b70fb271241acb9aa5295415d8bebabad859a9ea9dc95aa71a68f06c2eba73809b9b30e2
24
25 diff --git a/dev-python/pandas/pandas-1.2.2.ebuild b/dev-python/pandas/pandas-1.2.2.ebuild
26 new file mode 100644
27 index 00000000000..2bfbf0f7609
28 --- /dev/null
29 +++ b/dev-python/pandas/pandas-1.2.2.ebuild
30 @@ -0,0 +1,186 @@
31 +# Copyright 1999-2021 Gentoo Authors
32 +# Distributed under the terms of the GNU General Public License v2
33 +
34 +EAPI=7
35 +
36 +PYTHON_COMPAT=( python3_{7..9} )
37 +PYTHON_REQ_USE="threads(+)"
38 +
39 +VIRTUALX_REQUIRED="manual"
40 +
41 +inherit distutils-r1 flag-o-matic multiprocessing optfeature virtualx
42 +
43 +DESCRIPTION="Powerful data structures for data analysis and statistics"
44 +HOMEPAGE="https://pandas.pydata.org/"
45 +SRC_URI="mirror://pypi/${PN:0:1}/${PN}/${P/_/}.tar.gz"
46 +S="${WORKDIR}/${P/_/}"
47 +
48 +SLOT="0"
49 +LICENSE="BSD"
50 +KEYWORDS="~amd64 ~arm ~arm64 ~x86"
51 +IUSE="doc full-support minimal test X"
52 +RESTRICT="!test? ( test )"
53 +
54 +RECOMMENDED_DEPEND="
55 + >=dev-python/bottleneck-1.2.1[${PYTHON_USEDEP}]
56 + >=dev-python/numexpr-2.1[${PYTHON_USEDEP}]
57 +"
58 +
59 +# TODO: add pandas-gbq to the tree
60 +OPTIONAL_DEPEND="
61 + dev-python/beautifulsoup:4[${PYTHON_USEDEP}]
62 + dev-python/blosc[${PYTHON_USEDEP}]
63 + || (
64 + dev-python/html5lib[${PYTHON_USEDEP}]
65 + dev-python/lxml[${PYTHON_USEDEP}]
66 + )
67 + dev-python/jinja[${PYTHON_USEDEP}]
68 + dev-python/matplotlib[${PYTHON_USEDEP}]
69 + || (
70 + dev-python/openpyxl[${PYTHON_USEDEP}]
71 + dev-python/xlsxwriter[${PYTHON_USEDEP}]
72 + )
73 + >=dev-python/pytables-3.2.1[${PYTHON_USEDEP}]
74 + dev-python/statsmodels[${PYTHON_USEDEP}]
75 + $(python_gen_cond_dep '
76 + >=dev-python/xarray-0.10.8[${PYTHON_USEDEP}]
77 + ' python3_{6,7})
78 + >=dev-python/sqlalchemy-0.8.1[${PYTHON_USEDEP}]
79 + >=dev-python/xlrd-1.0.0[${PYTHON_USEDEP}]
80 + dev-python/xlwt[${PYTHON_USEDEP}]
81 + >=dev-python/scipy-1.1[${PYTHON_USEDEP}]
82 + X? (
83 + || (
84 + dev-python/PyQt5[${PYTHON_USEDEP}]
85 + x11-misc/xclip
86 + x11-misc/xsel
87 + )
88 + )
89 +"
90 +COMMON_DEPEND="
91 + >dev-python/numpy-1.15.4[${PYTHON_USEDEP}]
92 + dev-python/python-dateutil[${PYTHON_USEDEP}]
93 + dev-python/pytz[${PYTHON_USEDEP}]
94 +"
95 +DEPEND="${COMMON_DEPEND}
96 + >=dev-python/cython-0.29.21[${PYTHON_USEDEP}]
97 + doc? (
98 + ${VIRTUALX_DEPEND}
99 + app-text/pandoc
100 + dev-python/beautifulsoup:4[${PYTHON_USEDEP}]
101 + dev-python/html5lib[${PYTHON_USEDEP}]
102 + dev-python/ipython[${PYTHON_USEDEP}]
103 + dev-python/lxml[${PYTHON_USEDEP}]
104 + dev-python/matplotlib[${PYTHON_USEDEP}]
105 + dev-python/nbsphinx[${PYTHON_USEDEP}]
106 + >=dev-python/numpydoc-0.9.1[${PYTHON_USEDEP}]
107 + >=dev-python/openpyxl-1.6.1[${PYTHON_USEDEP}]
108 + >=dev-python/pytables-3.0.0[${PYTHON_USEDEP}]
109 + dev-python/pytz[${PYTHON_USEDEP}]
110 + dev-python/rpy[${PYTHON_USEDEP}]
111 + dev-python/sphinx[${PYTHON_USEDEP}]
112 + dev-python/xlrd[${PYTHON_USEDEP}]
113 + dev-python/xlwt[${PYTHON_USEDEP}]
114 + dev-python/scipy[${PYTHON_USEDEP}]
115 + x11-misc/xclip
116 + )
117 + test? (
118 + ${VIRTUALX_DEPEND}
119 + ${RECOMMENDED_DEPEND}
120 + ${OPTIONAL_DEPEND}
121 + dev-python/beautifulsoup:4[${PYTHON_USEDEP}]
122 + dev-python/hypothesis[${PYTHON_USEDEP}]
123 + dev-python/nose[${PYTHON_USEDEP}]
124 + dev-python/openpyxl[${PYTHON_USEDEP}]
125 + dev-python/pymysql[${PYTHON_USEDEP}]
126 + >=dev-python/pytest-5.1[${PYTHON_USEDEP}]
127 + dev-python/pytest-mock[${PYTHON_USEDEP}]
128 + dev-python/pytest-xdist[${PYTHON_USEDEP}]
129 + dev-python/psycopg:2[${PYTHON_USEDEP}]
130 + dev-python/xlsxwriter[${PYTHON_USEDEP}]
131 + x11-misc/xclip
132 + x11-misc/xsel
133 + )
134 +"
135 +# dev-python/statsmodels invokes a circular dep
136 +# hence rm from doc? ( ), again
137 +RDEPEND="${COMMON_DEPEND}
138 + !minimal? ( ${RECOMMENDED_DEPEND} )
139 + full-support? ( ${OPTIONAL_DEPEND} )
140 +"
141 +
142 +python_prepare_all() {
143 + # Prevent un-needed download during build
144 + sed -e "/^ 'sphinx.ext.intersphinx',/d" \
145 + -i doc/source/conf.py || die
146 +
147 + # requires package installed
148 + sed -e '/extra_compile_args =/s:"-Werror"::' \
149 + -i setup.py || die
150 +
151 + distutils-r1_python_prepare_all
152 +}
153 +
154 +python_compile_all() {
155 + # To build docs the need be located in $BUILD_DIR,
156 + # else PYTHONPATH points to unusable modules.
157 + if use doc; then
158 + cd "${BUILD_DIR}"/lib || die
159 + cp -ar "${S}"/doc . && cd doc || die
160 + LANG=C PYTHONPATH=. virtx ${EPYTHON} make.py html
161 + fi
162 +}
163 +
164 +src_test() {
165 + virtx distutils-r1_src_test
166 +}
167 +
168 +python_test() {
169 + local deselect=(
170 + # broken on practically any hardware/CFLAGS but the one
171 + # the patch author was using
172 + # https://github.com/pandas-dev/pandas/issues/38921
173 + pandas/tests/window/test_rolling.py::test_rolling_var_numerical_issues
174 +
175 + # weird issue, doesn't seem very important
176 + 'pandas/tests/base/test_misc.py::test_memory_usage[series-with-empty-index]'
177 + )
178 +
179 + local -x LC_ALL=C.UTF-8
180 + pushd "${BUILD_DIR}"/lib > /dev/null || die
181 + "${EPYTHON}" -c "import pandas; pandas.show_versions()" || die
182 + PYTHONPATH=. pytest pandas -vv --skip-slow --skip-network \
183 + ${deselect[@]/#/--deselect } \
184 + -n "$(makeopts_jobs "${MAKEOPTS}" "$(get_nproc)")" \
185 + -m "not single" || die "Tests failed with ${EPYTHON}"
186 + find . '(' -name .pytest_cache -o -name .hypothesis ')' \
187 + -exec rm -r {} + || die
188 + popd > /dev/null || die
189 +}
190 +
191 +python_install_all() {
192 + if use doc; then
193 + dodoc -r "${BUILD_DIR}"/lib/doc/build/html
194 + einfo "An initial build of docs is absent of references to statsmodels"
195 + einfo "due to circular dependency. To have them included, emerge"
196 + einfo "statsmodels next and re-emerge pandas with USE doc"
197 + fi
198 +
199 + distutils-r1_python_install_all
200 +}
201 +
202 +pkg_postinst() {
203 + optfeature "accelerating certain types of NaN evaluations, using specialized cython routines to achieve large speedups." dev-python/bottleneck
204 + optfeature "accelerating certain numerical operations, using multiple cores as well as smart chunking and caching to achieve large speedups" ">=dev-python/numexpr-2.1"
205 + optfeature "needed for pandas.io.html.read_html" dev-python/beautifulsoup:4 dev-python/html5lib dev-python/lxml
206 + optfeature "for msgpack compression using blosc" dev-python/blosc
207 + optfeature "Template engine for conditional HTML formatting" dev-python/jinja
208 + optfeature "Plotting support" dev-python/matplotlib
209 + optfeature "Needed for Excel I/O" ">=dev-python/openpyxl-1.6.1" dev-python/xlsxwriter dev-python/xlrd dev-python/xlwt
210 + optfeature "necessary for HDF5-based storage" ">=dev-python/pytables-3.2.1"
211 + optfeature "R I/O support" dev-python/rpy
212 + optfeature "Needed for parts of pandas.stats" dev-python/statsmodels
213 + optfeature "SQL database support" ">=dev-python/sqlalchemy-0.8.1"
214 + optfeature "miscellaneous statistical functions" dev-python/scipy
215 + optfeature "necessary to use pandas.io.clipboard.read_clipboard support" dev-python/PyQt5 dev-python/pygtk x11-misc/xclip x11-misc/xsel
216 +}