Skip to content

Commit fd6681e

Browse files
h-vetinarijreback
authored andcommitted
Restore CI after PY2 drop (pandas-dev#25752)
1 parent dca809b commit fd6681e

11 files changed

+128
-15
lines changed

ci/azure/posix.yml

+12
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,18 @@ jobs:
1515
PATTERN: "not slow and not network"
1616

1717
${{ if eq(parameters.name, 'Linux') }}:
18+
py35_compat:
19+
ENV_FILE: ci/deps/azure-35-compat.yaml
20+
CONDA_PY: "35"
21+
PATTERN: "not slow and not network"
22+
23+
py36_locale_slow_old_np:
24+
ENV_FILE: ci/deps/azure-36-locale.yaml
25+
CONDA_PY: "36"
26+
PATTERN: "slow"
27+
LOCALE_OVERRIDE: "zh_CN.UTF-8"
28+
EXTRA_APT: "language-pack-zh-hans"
29+
1830
py36_locale_slow:
1931
ENV_FILE: ci/deps/azure-36-locale_slow.yaml
2032
CONDA_PY: "36"

ci/azure/windows.yml

+4
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,10 @@ jobs:
1212
ENV_FILE: ci/deps/azure-windows-36.yaml
1313
CONDA_PY: "36"
1414

15+
py37_np141:
16+
ENV_FILE: ci/deps/azure-windows-37.yaml
17+
CONDA_PY: "37"
18+
1519
steps:
1620
- task: CondaEnvironment@1
1721
inputs:

ci/deps/azure-35-compat.yaml

+29
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
name: pandas-dev
2+
channels:
3+
- defaults
4+
- conda-forge
5+
dependencies:
6+
- beautifulsoup4==4.4.1
7+
- bottleneck=1.2.0
8+
- cython=0.28.2
9+
- hypothesis>=3.58.0
10+
- jinja2=2.8
11+
- numexpr=2.6.1
12+
- numpy=1.12.0
13+
- openpyxl=2.4.0
14+
- pytables=3.4.2
15+
- python-dateutil=2.5.0
16+
- python=3.5*
17+
- pytz=2015.4
18+
- scipy=0.18.1
19+
- xlrd=1.0.0
20+
- xlsxwriter=0.7.7
21+
- xlwt=1.0.0
22+
# universal
23+
- pytest-xdist
24+
- pytest-mock
25+
- isort
26+
- pip:
27+
# for python 3.5, pytest>=4.0.2 is not available in conda
28+
- pytest>=4.0.2
29+
- html5lib==1.0b2

ci/deps/azure-36-locale.yaml

+29
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
name: pandas-dev
2+
channels:
3+
- defaults
4+
- conda-forge
5+
dependencies:
6+
- beautifulsoup4==4.5.1
7+
- bottleneck=1.2.0
8+
- cython=0.28.2
9+
- lxml
10+
- matplotlib=2.0.0
11+
- numpy=1.12.0
12+
- openpyxl=2.4.0
13+
- python-dateutil
14+
- python-blosc
15+
- python=3.6
16+
- pytz=2016.10
17+
- scipy
18+
- sqlalchemy=1.1.4
19+
- xlrd=1.0.0
20+
- xlsxwriter=0.9.4
21+
- xlwt=1.2.0
22+
# universal
23+
- pytest>=4.0.2
24+
- pytest-xdist
25+
- pytest-mock
26+
- hypothesis>=3.58.0
27+
- isort
28+
- pip:
29+
- html5lib==1.0b2

ci/deps/azure-macos-35.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ dependencies:
1212
- nomkl
1313
- numexpr
1414
- numpy=1.12.0
15-
- openpyxl=2.5.5
15+
- openpyxl
1616
- pyarrow
1717
- pytables
1818
- python=3.5*

ci/deps/azure-windows-37.yaml

+33
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
name: pandas-dev
2+
channels:
3+
- defaults
4+
- conda-forge
5+
dependencies:
6+
- beautifulsoup4
7+
- bottleneck
8+
- gcsfs
9+
- html5lib
10+
- jinja2
11+
- lxml
12+
- matplotlib=3.0.1
13+
- numexpr
14+
- numpy=1.14.*
15+
- openpyxl
16+
- pytables
17+
- python=3.7.*
18+
- python-dateutil
19+
- pytz
20+
- s3fs
21+
- scipy
22+
- sqlalchemy
23+
- xlrd
24+
- xlsxwriter
25+
- xlwt
26+
# universal
27+
- cython>=0.28.2
28+
- pytest>=4.0.2
29+
- pytest-xdist
30+
- pytest-mock
31+
- moto
32+
- hypothesis>=3.58.0
33+
- isort

ci/deps/travis-36-locale.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ dependencies:
1515
- numpy
1616
- openpyxl
1717
- psycopg2
18-
- pymysql
18+
- pymysql=0.7.9
1919
- pytables
2020
- python-dateutil
2121
- python=3.6*

doc/source/install.rst

+1-1
Original file line numberDiff line numberDiff line change
@@ -259,7 +259,7 @@ Optional Dependencies
259259
* `PyTables <http://www.pytables.org>`__: necessary for HDF5-based storage, Version 3.4.2 or higher
260260
* `pyarrow <http://arrow.apache.org/docs/python/>`__ (>= 0.9.0): necessary for feather-based storage.
261261
* `Apache Parquet <https://parquet.apache.org/>`__, either `pyarrow <http://arrow.apache.org/docs/python/>`__ (>= 0.7.0) or `fastparquet <https://fastparquet.readthedocs.io/en/latest>`__ (>= 0.2.1) for parquet-based storage. The `snappy <https://pypi.org/project/python-snappy>`__ and `brotli <https://pypi.org/project/brotlipy>`__ are available for compression support.
262-
* `SQLAlchemy <http://www.sqlalchemy.org>`__: for SQL database support. Version 1.0.8 or higher recommended. Besides SQLAlchemy, you also need a database specific driver. You can find an overview of supported drivers for each SQL dialect in the `SQLAlchemy docs <http://docs.sqlalchemy.org/en/latest/dialects/index.html>`__. Some common drivers are:
262+
* `SQLAlchemy <http://www.sqlalchemy.org>`__: for SQL database support. Version 1.1.4 or higher recommended. Besides SQLAlchemy, you also need a database specific driver. You can find an overview of supported drivers for each SQL dialect in the `SQLAlchemy docs <http://docs.sqlalchemy.org/en/latest/dialects/index.html>`__. Some common drivers are:
263263

264264
* `psycopg2 <http://initd.org/psycopg/>`__: for PostgreSQL
265265
* `pymysql <https://github.com/PyMySQL/PyMySQL>`__: for MySQL.

doc/source/whatsnew/v0.25.0.rst

+3-3
Original file line numberDiff line numberDiff line change
@@ -123,13 +123,13 @@ If installed, we now require:
123123
+=================+=================+==========+
124124
| beautifulsoup4 | 4.4.1 | |
125125
+-----------------+-----------------+----------+
126-
| openpyxl | 2.2.6 | |
126+
| openpyxl | 2.4.0 | |
127127
+-----------------+-----------------+----------+
128-
| pymysql | 0.6.6 | |
128+
| pymysql | 0.7.9 | |
129129
+-----------------+-----------------+----------+
130130
| pytz | 2015.4 | |
131131
+-----------------+-----------------+----------+
132-
| sqlalchemy | 1.0.8 | |
132+
| sqlalchemy | 1.1.4 | |
133133
+-----------------+-----------------+----------+
134134
| xlsxwriter | 0.7.7 | |
135135
+-----------------+-----------------+----------+

pandas/tests/test_algos.py

+6-4
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@
2020
import pandas as pd
2121
from pandas import (
2222
Categorical, CategoricalIndex, DatetimeIndex, Index, IntervalIndex, Series,
23-
Timestamp, compat)
23+
Timestamp, _np_version_under1p14, compat)
2424
import pandas.core.algorithms as algos
2525
from pandas.core.arrays import DatetimeArray
2626
import pandas.core.common as com
@@ -228,9 +228,11 @@ def test_complex_sorting(self):
228228
# gh 12666 - check no segfault
229229
x17 = np.array([complex(i) for i in range(17)], dtype=object)
230230

231-
msg = (r"'(<|>)' not supported between instances of 'complex' and"
232-
r" 'complex'|"
233-
r"unorderable types: complex\(\) > complex\(\)")
231+
msg = (r"unorderable types: {0} [<>] {0}".format(r"complex\(\)")
232+
if _np_version_under1p14 else
233+
r"'[<>]' not supported between instances of {0} and {0}".format(
234+
"'complex'")
235+
)
234236
with pytest.raises(TypeError, match=msg):
235237
algos.factorize(x17[::-1], sort=True)
236238

pandas/tests/test_sorting.py

+9-5
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,8 @@
77
import pytest
88

99
from pandas import (
10-
DataFrame, MultiIndex, Series, compat, concat, merge, to_datetime)
10+
DataFrame, MultiIndex, Series, _np_version_under1p14, compat, concat,
11+
merge, to_datetime)
1112
from pandas.core import common as com
1213
from pandas.core.sorting import (
1314
decons_group_index, get_group_index, is_int64_overflow_possible,
@@ -413,10 +414,13 @@ def test_mixed_integer_from_list(self):
413414
def test_unsortable(self):
414415
# GH 13714
415416
arr = np.array([1, 2, datetime.now(), 0, 3], dtype=object)
416-
msg = (r"'(<|>)' not supported between instances of ('"
417-
r"datetime\.datetime' and 'int'|'int' and 'datetime\.datetime"
418-
r"')|"
419-
r"unorderable types: int\(\) > datetime\.datetime\(\)")
417+
msg = (r"unorderable types: ({0} [<>] {1}|{1} [<>] {0})".format(
418+
r"int\(\)", r"datetime\.datetime\(\)") # noqa: E126
419+
if _np_version_under1p14 else
420+
(r"'[<>]' not supported between instances of "
421+
r"({0} and {1}|{1} and {0})").format(
422+
"'int'", r"'datetime\.datetime'")
423+
)
420424
with pytest.raises(TypeError, match=msg):
421425
safe_sort(arr)
422426

0 commit comments

Comments
 (0)