Skip to content

Commit 9e9f0c3

Browse files
authored
Merge pull request #2 from pandas-dev/master
Updates fork
2 parents 10abc0f + 634a41f commit 9e9f0c3

File tree

1,318 files changed

+88281
-92316
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,318 files changed

+88281
-92316
lines changed

.binstar.yml

-28
This file was deleted.

.devcontainer.json

+28
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
// For format details, see https://aka.ms/vscode-remote/devcontainer.json or the definition README at
2+
// https://github.com/microsoft/vscode-dev-containers/tree/master/containers/python-3-miniconda
3+
{
4+
"name": "pandas",
5+
"context": ".",
6+
"dockerFile": "Dockerfile",
7+
8+
// Use 'settings' to set *default* container specific settings.json values on container create.
9+
// You can edit these settings after create using File > Preferences > Settings > Remote.
10+
"settings": {
11+
"terminal.integrated.shell.linux": "/bin/bash",
12+
"python.condaPath": "/opt/conda/bin/conda",
13+
"python.pythonPath": "/opt/conda/bin/python",
14+
"python.formatting.provider": "black",
15+
"python.linting.enabled": true,
16+
"python.linting.flake8Enabled": true,
17+
"python.linting.pylintEnabled": false,
18+
"python.linting.mypyEnabled": true,
19+
"python.testing.pytestEnabled": true,
20+
"python.testing.cwd": "pandas/tests"
21+
},
22+
23+
// Add the IDs of extensions you want installed when the container is created in the array below.
24+
"extensions": [
25+
"ms-python.python",
26+
"ms-vscode.cpptools"
27+
]
28+
}

.github/CODE_OF_CONDUCT.md

+3-3
Original file line numberDiff line numberDiff line change
@@ -54,10 +54,10 @@ incident.
5454

5555
This Code of Conduct is adapted from the [Contributor Covenant][homepage],
5656
version 1.3.0, available at
57-
[http://contributor-covenant.org/version/1/3/0/][version],
57+
[https://www.contributor-covenant.org/version/1/3/0/][version],
5858
and the [Swift Code of Conduct][swift].
5959

60-
[homepage]: http://contributor-covenant.org
61-
[version]: http://contributor-covenant.org/version/1/3/0/
60+
[homepage]: https://www.contributor-covenant.org
61+
[version]: https://www.contributor-covenant.org/version/1/3/0/
6262
[swift]: https://swift.org/community/#code-of-conduct
6363

.github/CONTRIBUTING.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ If you notice a bug in the code or documentation, or have suggestions for how we
1616

1717
## Contributing to the Codebase
1818

19-
The code is hosted on [GitHub](https://www.github.com/pandas-dev/pandas), so you will need to use [Git](http://git-scm.com/) to clone the project and make changes to the codebase. Once you have obtained a copy of the code, you should create a development environment that is separate from your existing Python environment so that you can make and test changes without compromising your own work environment. For more information, please refer to the "[Working with the code](https://github.com/pandas-dev/pandas/blob/master/doc/source/development/contributing.rst#working-with-the-code)" section.
19+
The code is hosted on [GitHub](https://www.github.com/pandas-dev/pandas), so you will need to use [Git](https://git-scm.com/) to clone the project and make changes to the codebase. Once you have obtained a copy of the code, you should create a development environment that is separate from your existing Python environment so that you can make and test changes without compromising your own work environment. For more information, please refer to the "[Working with the code](https://github.com/pandas-dev/pandas/blob/master/doc/source/development/contributing.rst#working-with-the-code)" section.
2020

2121
Before submitting your changes for review, make sure to check that your changes do not break any tests. You can find more information about our test suites in the "[Test-driven development/code writing](https://github.com/pandas-dev/pandas/blob/master/doc/source/development/contributing.rst#test-driven-development-code-writing)" section. We also have guidelines regarding coding style that will be enforced during testing, which can be found in the "[Code standards](https://github.com/pandas-dev/pandas/blob/master/doc/source/development/contributing.rst#code-standards)" section.
2222

.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

+14
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
name: Assign
2+
on:
3+
issue_comment:
4+
types: created
5+
6+
jobs:
7+
one:
8+
runs-on: ubuntu-latest
9+
steps:
10+
- if: github.event.comment.body == 'take'
11+
name:
12+
run: |
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

.github/workflows/ci.yml

+159
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,159 @@
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: always()
27+
28+
- name: Setup environment and build pandas
29+
run: ci/setup_env.sh
30+
if: always()
31+
32+
- name: Linting
33+
run: |
34+
source activate pandas-dev
35+
ci/code_checks.sh lint
36+
if: always()
37+
38+
- name: Dependencies consistency
39+
run: |
40+
source activate pandas-dev
41+
ci/code_checks.sh dependencies
42+
if: always()
43+
44+
- name: Checks on imported code
45+
run: |
46+
source activate pandas-dev
47+
ci/code_checks.sh code
48+
if: always()
49+
50+
- name: Running doctests
51+
run: |
52+
source activate pandas-dev
53+
ci/code_checks.sh doctests
54+
if: always()
55+
56+
- name: Docstring validation
57+
run: |
58+
source activate pandas-dev
59+
ci/code_checks.sh docstrings
60+
if: always()
61+
62+
- name: Typing validation
63+
run: |
64+
source activate pandas-dev
65+
ci/code_checks.sh typing
66+
if: always()
67+
68+
- name: Testing docstring validation script
69+
run: |
70+
source activate pandas-dev
71+
pytest --capture=no --strict scripts
72+
if: always()
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: always()
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()
98+
99+
web_and_docs:
100+
name: Web and docs
101+
runs-on: ubuntu-latest
102+
steps:
103+
104+
- name: Setting conda path
105+
run: echo "::set-env name=PATH::${HOME}/miniconda3/bin:${PATH}"
106+
107+
- name: Checkout
108+
uses: actions/checkout@v1
109+
110+
- name: Setup environment and build pandas
111+
run: ci/setup_env.sh
112+
113+
- name: Build website
114+
run: |
115+
source activate pandas-dev
116+
python web/pandas_web.py web/pandas --target-path=web/build
117+
118+
- name: Build documentation
119+
run: |
120+
source activate pandas-dev
121+
doc/make.py --warnings-are-errors | tee sphinx.log ; exit ${PIPESTATUS[0]}
122+
123+
# This can be removed when the ipython directive fails when there are errors,
124+
# including the `tee sphinx.log` in te previous step (https://github.com/ipython/ipython/issues/11547)
125+
- name: Check ipython directive errors
126+
run: "! grep -B1 \"^<<<-------------------------------------------------------------------------$\" sphinx.log"
127+
128+
- name: Merge website and docs
129+
run: |
130+
mkdir -p pandas_web/docs
131+
cp -r web/build/* pandas_web/
132+
cp -r doc/build/html/* pandas_web/docs/
133+
if: github.event_name == 'push'
134+
135+
- name: Install Rclone
136+
run: sudo apt install rclone -y
137+
if: github.event_name == 'push'
138+
139+
- name: Set up Rclone
140+
run: |
141+
RCLONE_CONFIG_PATH=$HOME/.config/rclone/rclone.conf
142+
mkdir -p `dirname $RCLONE_CONFIG_PATH`
143+
echo "[ovh_cloud_pandas_web]" > $RCLONE_CONFIG_PATH
144+
echo "type = swift" >> $RCLONE_CONFIG_PATH
145+
echo "env_auth = false" >> $RCLONE_CONFIG_PATH
146+
echo "auth_version = 3" >> $RCLONE_CONFIG_PATH
147+
echo "auth = https://auth.cloud.ovh.net/v3/" >> $RCLONE_CONFIG_PATH
148+
echo "endpoint_type = public" >> $RCLONE_CONFIG_PATH
149+
echo "tenant_domain = default" >> $RCLONE_CONFIG_PATH
150+
echo "tenant = 2977553886518025" >> $RCLONE_CONFIG_PATH
151+
echo "domain = default" >> $RCLONE_CONFIG_PATH
152+
echo "user = w4KGs3pmDxpd" >> $RCLONE_CONFIG_PATH
153+
echo "key = ${{ secrets.ovh_object_store_key }}" >> $RCLONE_CONFIG_PATH
154+
echo "region = BHS" >> $RCLONE_CONFIG_PATH
155+
if: github.event_name == 'push'
156+
157+
- name: Sync web
158+
run: rclone sync pandas_web ovh_cloud_pandas_web:dev
159+
if: github.event_name == 'push'

.pre-commit-config.yaml

+16-3
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
repos:
22
- repo: https://github.com/python/black
3-
rev: stable
3+
rev: 19.10b0
44
hooks:
55
- id: black
66
language_version: python3.7
@@ -9,9 +9,22 @@ repos:
99
hooks:
1010
- id: flake8
1111
language: python_venv
12-
additional_dependencies: [flake8-comprehensions]
12+
additional_dependencies: [flake8-comprehensions>=3.1.0]
1313
- repo: https://github.com/pre-commit/mirrors-isort
14-
rev: v4.3.20
14+
rev: v4.3.21
1515
hooks:
1616
- id: isort
1717
language: python_venv
18+
exclude: ^pandas/__init__\.py$|^pandas/core/api\.py$
19+
- repo: https://github.com/pre-commit/mirrors-mypy
20+
rev: v0.730
21+
hooks:
22+
- id: mypy
23+
args:
24+
# As long as a some files are excluded from check-untyped-defs
25+
# we have to exclude it from the pre-commit hook as the configuration
26+
# is based on modules but the hook runs on files.
27+
- --no-check-untyped-defs
28+
- --follow-imports
29+
- skip
30+
files: pandas/

0 commit comments

Comments
 (0)