Skip to content

Commit 18631d6

Browse files
committed
Merge remote-tracking branch 'upstream/master'
2 parents ac9f79a + 53a0dfd commit 18631d6

File tree

1,047 files changed

+50340
-56233
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

1,047 files changed

+50340
-56233
lines changed

.github/FUNDING.yml

+1
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,3 @@
11
custom: https://pandas.pydata.org/donate.html
2+
github: [numfocus]
23
tidelift: pypi/pandas

.github/workflows/assign.yml

+15
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
name: Assign
2+
on:
3+
issue_comment:
4+
types: created
5+
6+
jobs:
7+
one:
8+
runs-on: ubuntu-latest
9+
steps:
10+
- name:
11+
run: |
12+
if [[ "${{ github.event.comment.body }}" == "take" ]]; then
13+
echo "Assigning issue ${{ github.event.issue.number }} to ${{ github.event.comment.user.login }}"
14+
curl -H "Authorization: token ${{ secrets.GITHUB_TOKEN }}" -d '{"assignees": ["${{ github.event.comment.user.login }}"]}' https://api.github.com/repos/${{ github.repository }}/issues/${{ github.event.issue.number }}/assignees
15+
fi

.github/workflows/ci.yml

+97
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,97 @@
1+
name: CI
2+
3+
on:
4+
push:
5+
branches: master
6+
pull_request:
7+
branches: master
8+
9+
env:
10+
ENV_FILE: environment.yml
11+
12+
jobs:
13+
checks:
14+
name: Checks
15+
runs-on: ubuntu-latest
16+
steps:
17+
18+
- name: Setting conda path
19+
run: echo "::add-path::${HOME}/miniconda3/bin"
20+
21+
- name: Checkout
22+
uses: actions/checkout@v1
23+
24+
- name: Looking for unwanted patterns
25+
run: ci/code_checks.sh patterns
26+
if: true
27+
28+
- name: Setup environment and build pandas
29+
run: ci/setup_env.sh
30+
if: true
31+
32+
- name: Linting
33+
run: |
34+
source activate pandas-dev
35+
ci/code_checks.sh lint
36+
if: true
37+
38+
- name: Dependencies consistency
39+
run: |
40+
source activate pandas-dev
41+
ci/code_checks.sh dependencies
42+
if: true
43+
44+
- name: Checks on imported code
45+
run: |
46+
source activate pandas-dev
47+
ci/code_checks.sh code
48+
if: true
49+
50+
- name: Running doctests
51+
run: |
52+
source activate pandas-dev
53+
ci/code_checks.sh doctests
54+
if: true
55+
56+
- name: Docstring validation
57+
run: |
58+
source activate pandas-dev
59+
ci/code_checks.sh docstrings
60+
if: true
61+
62+
- name: Typing validation
63+
run: |
64+
source activate pandas-dev
65+
ci/code_checks.sh typing
66+
if: true
67+
68+
- name: Testing docstring validation script
69+
run: |
70+
source activate pandas-dev
71+
pytest --capture=no --strict scripts
72+
if: true
73+
74+
- name: Running benchmarks
75+
run: |
76+
source activate pandas-dev
77+
cd asv_bench
78+
asv check -E existing
79+
git remote add upstream https://github.com/pandas-dev/pandas.git
80+
git fetch upstream
81+
if git diff upstream/master --name-only | grep -q "^asv_bench/"; then
82+
asv machine --yes
83+
asv dev | sed "/failed$/ s/^/##[error]/" | tee benchmarks.log
84+
if grep "failed" benchmarks.log > /dev/null ; then
85+
exit 1
86+
fi
87+
else
88+
echo "Benchmarks did not run, no changes detected"
89+
fi
90+
if: true
91+
92+
- name: Publish benchmarks artifact
93+
uses: actions/upload-artifact@master
94+
with:
95+
name: Benchmarks log
96+
path: asv_bench/benchmarks.log
97+
if: failure()

.gitignore

+1
Original file line numberDiff line numberDiff line change
@@ -57,6 +57,7 @@ dist
5757
# wheel files
5858
*.whl
5959
**/wheelhouse/*
60+
pip-wheel-metadata
6061
# coverage
6162
.coverage
6263
coverage.xml

.pre-commit-config.yaml

+17-16
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,18 @@
11
repos:
2-
- repo: https://github.com/python/black
3-
rev: stable
4-
hooks:
5-
- id: black
6-
language_version: python3.7
7-
- repo: https://gitlab.com/pycqa/flake8
8-
rev: 3.7.7
9-
hooks:
10-
- id: flake8
11-
language: python_venv
12-
additional_dependencies: [flake8-comprehensions]
13-
- repo: https://github.com/pre-commit/mirrors-isort
14-
rev: v4.3.20
15-
hooks:
16-
- id: isort
17-
language: python_venv
2+
- repo: https://github.com/python/black
3+
rev: 19.10b0
4+
hooks:
5+
- id: black
6+
language_version: python3.7
7+
- repo: https://gitlab.com/pycqa/flake8
8+
rev: 3.7.7
9+
hooks:
10+
- id: flake8
11+
language: python_venv
12+
additional_dependencies: [flake8-comprehensions>=3.1.0]
13+
- repo: https://github.com/pre-commit/mirrors-isort
14+
rev: v4.3.20
15+
hooks:
16+
- id: isort
17+
language: python_venv
18+
exclude: ^pandas/__init__\.py$|^pandas/core/api\.py$

.travis.yml

+23-22
Original file line numberDiff line numberDiff line change
@@ -30,27 +30,34 @@ matrix:
3030
- python: 3.5
3131

3232
include:
33-
- dist: trusty
34-
env:
33+
- env:
34+
- JOB="3.8" ENV_FILE="ci/deps/travis-38.yaml" PATTERN="(not slow and not network)"
35+
36+
- env:
3537
- JOB="3.7" ENV_FILE="ci/deps/travis-37.yaml" PATTERN="(not slow and not network)"
3638

37-
- dist: trusty
38-
env:
39-
- JOB="3.6, locale" ENV_FILE="ci/deps/travis-36-locale.yaml" PATTERN="((not slow and not network) or (single and db))" LOCALE_OVERRIDE="zh_CN.UTF-8"
39+
- env:
40+
- JOB="3.6, locale" ENV_FILE="ci/deps/travis-36-locale.yaml" PATTERN="((not slow and not network) or (single and db))" LOCALE_OVERRIDE="zh_CN.UTF-8" SQL="1"
41+
services:
42+
- mysql
43+
- postgresql
4044

41-
- dist: trusty
42-
env:
43-
- JOB="3.6, coverage" ENV_FILE="ci/deps/travis-36-cov.yaml" PATTERN="((not slow and not network) or (single and db))" PANDAS_TESTING_MODE="deprecate" COVERAGE=true
45+
- env:
46+
- JOB="3.6, coverage" ENV_FILE="ci/deps/travis-36-cov.yaml" PATTERN="((not slow and not network) or (single and db))" PANDAS_TESTING_MODE="deprecate" COVERAGE=true SQL="1"
47+
services:
48+
- mysql
49+
- postgresql
4450

4551
# In allow_failures
46-
- dist: trusty
47-
env:
48-
- JOB="3.6, slow" ENV_FILE="ci/deps/travis-36-slow.yaml" PATTERN="slow"
52+
- env:
53+
- JOB="3.6, slow" ENV_FILE="ci/deps/travis-36-slow.yaml" PATTERN="slow" SQL="1"
54+
services:
55+
- mysql
56+
- postgresql
4957

5058
allow_failures:
51-
- dist: trusty
52-
env:
53-
- JOB="3.6, slow" ENV_FILE="ci/deps/travis-36-slow.yaml" PATTERN="slow"
59+
- env:
60+
- JOB="3.6, slow" ENV_FILE="ci/deps/travis-36-slow.yaml" PATTERN="slow" SQL="1"
5461

5562
before_install:
5663
- echo "before_install"
@@ -71,23 +78,17 @@ before_install:
7178
# This overrides travis and tells it to look nowhere.
7279
- export BOTO_CONFIG=/dev/null
7380

81+
7482
install:
7583
- echo "install start"
7684
- ci/prep_cython_cache.sh
7785
- ci/setup_env.sh
7886
- ci/submit_cython_cache.sh
7987
- echo "install done"
8088

81-
before_script:
82-
# display server (for clipboard functionality) needs to be started here,
83-
# does not work if done in install:setup_env.sh (GH-26103)
84-
- export DISPLAY=":99.0"
85-
- echo "sh -e /etc/init.d/xvfb start"
86-
- sh -e /etc/init.d/xvfb start
87-
- sleep 3
88-
8989
script:
9090
- echo "script start"
91+
- echo "$JOB"
9192
- source activate pandas-dev
9293
- ci/run_tests.sh
9394

LICENSES/MSGPACK_LICENSE

-13
This file was deleted.

LICENSES/MSGPACK_NUMPY_LICENSE

-33
This file was deleted.

MANIFEST.in

+5-1
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@ include LICENSE
33
include RELEASE.md
44
include README.md
55
include setup.py
6+
include pyproject.toml
67

78
graft doc
89
prune doc/build
@@ -14,16 +15,19 @@ graft pandas
1415
global-exclude *.bz2
1516
global-exclude *.csv
1617
global-exclude *.dta
18+
global-exclude *.feather
1719
global-exclude *.gz
1820
global-exclude *.h5
1921
global-exclude *.html
2022
global-exclude *.json
21-
global-exclude *.msgpack
2223
global-exclude *.pickle
2324
global-exclude *.png
2425
global-exclude *.pyc
2526
global-exclude *.pyd
27+
global-exclude *.ods
28+
global-exclude *.odt
2629
global-exclude *.sas7bdat
30+
global-exclude *.sav
2731
global-exclude *.so
2832
global-exclude *.xls
2933
global-exclude *.xlsm

Makefile

+2-2
Original file line numberDiff line numberDiff line change
@@ -15,10 +15,10 @@ lint-diff:
1515
git diff upstream/master --name-only -- "*.py" | xargs flake8
1616

1717
black:
18-
black . --exclude '(asv_bench/env|\.egg|\.git|\.hg|\.mypy_cache|\.nox|\.tox|\.venv|_build|buck-out|build|dist|setup.py)'
18+
black .
1919

2020
develop: build
21-
python setup.py develop
21+
python -m pip install --no-build-isolation -e .
2222

2323
doc:
2424
-rm -rf doc/build doc/source/generated

README.md

+13-13
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
<div align="center">
2-
<img src="https://github.com/pandas-dev/pandas/blob/master/doc/logo/pandas_logo.png"><br>
2+
<img src="https://dev.pandas.io/static/img/pandas.svg"><br>
33
</div>
44

55
-----------------
@@ -124,7 +124,7 @@ Here are just a few of the things that pandas does well:
124124
and saving/loading data from the ultrafast [**HDF5 format**][hdfstore]
125125
- [**Time series**][timeseries]-specific functionality: date range
126126
generation and frequency conversion, moving window statistics,
127-
moving window linear regressions, date shifting and lagging, etc.
127+
date shifting and lagging.
128128

129129

130130
[missing-data]: https://pandas.pydata.org/pandas-docs/stable/missing_data.html#working-with-missing-data
@@ -164,12 +164,11 @@ pip install pandas
164164
```
165165

166166
## Dependencies
167-
- [NumPy](https://www.numpy.org): 1.13.3 or higher
168-
- [python-dateutil](https://labix.org/python-dateutil): 2.5.0 or higher
169-
- [pytz](https://pythonhosted.org/pytz): 2015.4 or higher
167+
- [NumPy](https://www.numpy.org)
168+
- [python-dateutil](https://labix.org/python-dateutil)
169+
- [pytz](https://pythonhosted.org/pytz)
170170

171-
See the [full installation instructions](https://pandas.pydata.org/pandas-docs/stable/install.html#dependencies)
172-
for recommended and optional dependencies.
171+
See the [full installation instructions](https://pandas.pydata.org/pandas-docs/stable/install.html#dependencies) for minimum supported versions of required, recommended and optional dependencies.
173172

174173
## Installation from sources
175174
To install pandas from source you need Cython in addition to the normal
@@ -188,16 +187,17 @@ python setup.py install
188187

189188
or for installing in [development mode](https://pip.pypa.io/en/latest/reference/pip_install.html#editable-installs):
190189

190+
191191
```sh
192-
python setup.py develop
192+
python -m pip install -e . --no-build-isolation --no-use-pep517
193193
```
194194

195-
Alternatively, you can use `pip` if you want all the dependencies pulled
196-
in automatically (the `-e` option is for installing it in [development
197-
mode](https://pip.pypa.io/en/latest/reference/pip_install.html#editable-installs)):
195+
If you have `make`, you can also use `make develop` to run the same command.
196+
197+
or alternatively
198198

199199
```sh
200-
pip install -e .
200+
python setup.py develop
201201
```
202202

203203
See the full instructions for [installing from source](https://pandas.pydata.org/pandas-docs/stable/install.html#installing-from-source).
@@ -224,7 +224,7 @@ Most development discussion is taking place on github in this repo. Further, the
224224

225225
All contributions, bug reports, bug fixes, documentation improvements, enhancements and ideas are welcome.
226226

227-
A detailed overview on how to contribute can be found in the **[contributing guide](https://dev.pandas.io/contributing.html)**. There is also an [overview](.github/CONTRIBUTING.md) on GitHub.
227+
A detailed overview on how to contribute can be found in the **[contributing guide](https://dev.pandas.io/docs/contributing.html)**. There is also an [overview](.github/CONTRIBUTING.md) on GitHub.
228228

229229
If you are simply looking to start working with the pandas codebase, navigate to the [GitHub "issues" tab](https://github.com/pandas-dev/pandas/issues) and start looking through interesting issues. There are a number of issues listed under [Docs](https://github.com/pandas-dev/pandas/issues?labels=Docs&sort=updated&state=open) and [good first issue](https://github.com/pandas-dev/pandas/issues?labels=good+first+issue&sort=updated&state=open) where you could start out.
230230

0 commit comments

Comments
 (0)