Skip to content

Commit 5386db8

Browse files
gsheniEthan Tutuethan1999
authored
Documentation changes (#35)
* fixed tests * major updates * fix req * fix woodwork * fix lint * working notebooks * update example to match mock customer update * remove typo? * remove type * update version * remove extra index rst * download dataset for docs * add liquor dataset and use git lfs * scale down dataset * stop example data gen from running on import * fix typo * fix guides * add api changes * Update build_docs.yml * Update lint_check.yml * Update unit_tests_with_latest_deps.yml * Update unit_tests_with_latest_deps.yml * Update unit_tests_with_latest_deps.yml * lint * add make lint to contributing md * add 3.9 support * add comment explaining reproducability code * 3.9 compatability * replace featuretool references * delete unused examples * delete unused example gen code * remove unused import statements * remove featuretool references * lint * add pr numbers * Delete .gitattributes no longer support git lfs * upload actual csvs Co-authored-by: Ethan Tu <[email protected]> Co-authored-by: Ethan Tu <[email protected]>
1 parent 23ca00b commit 5386db8

Some content is hidden

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

65 files changed

+26770
-2012175
lines changed

.github/workflows/build_docs.yml

Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,38 @@
1+
on:
2+
pull_request:
3+
types: [opened, synchronize]
4+
push:
5+
branches:
6+
- main
7+
8+
name: Build Docs
9+
jobs:
10+
build_docs:
11+
name: 3.7 build docs
12+
runs-on: ubuntu-latest
13+
steps:
14+
- name: Set up python 3.7
15+
uses: actions/setup-python@v2
16+
with:
17+
python-version: 3.7
18+
- name: Checkout repository
19+
uses: actions/checkout@v2
20+
with:
21+
ref: ${{ github.event.pull_request.head.ref }}
22+
repository: ${{ github.event.pull_request.head.repo.full_name }}
23+
lfs: 'True'
24+
- name: Install autonormalize with doc requirements
25+
run: |
26+
sudo apt update
27+
sudo apt install -y pandoc
28+
sudo apt install -y graphviz
29+
pip config --site set global.progress_bar off
30+
python -m pip install --upgrade pip
31+
python -m pip install -e .
32+
python -m pip install -r dev-requirements.txt
33+
- name: Build docs
34+
run: |
35+
make -C docs/ html
36+
ls docs/build/html
37+
env:
38+
ALTERYX_OPEN_SRC_UPDATE_CHECKER: False
Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
on:
2+
pull_request:
3+
types: [opened, synchronize]
4+
5+
name: Entry Point Test
6+
jobs:
7+
entry_point_test:
8+
name: Entry Point Test - Python ${{ matrix.python_version }}
9+
runs-on: ubuntu-latest
10+
strategy:
11+
matrix:
12+
python_version: ["3.7", "3.8", "3.9"]
13+
steps:
14+
- name: Set up python ${{ matrix.python_version }}
15+
uses: actions/setup-python@v2
16+
with:
17+
python-version: ${{ matrix.python_version }}
18+
- name: Checkout repository
19+
uses: actions/checkout@v2
20+
with:
21+
ref: ${{ github.event.pull_request.head.ref }}
22+
repository: ${{ github.event.pull_request.head.repo.full_name }}
23+
- name: Build source distribution
24+
run: make package_autonormalize
25+
- name: Install package
26+
run: |
27+
pip config --site set global.progress_bar off
28+
python -m pip install --upgrade pip
29+
python -m pip install -e unpacked_sdist/
30+
- name: Test entry point
31+
run: make entry-point-test

.github/workflows/lint_check.yml

Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
on:
2+
pull_request:
3+
types: [opened, synchronize]
4+
push:
5+
branches:
6+
- main
7+
8+
name: Lint Check
9+
jobs:
10+
lint_test:
11+
name: ${{ matrix.python_version }} lint test
12+
runs-on: ubuntu-latest
13+
strategy:
14+
matrix:
15+
python_version: ["3.7", "3.8", "3.9"]
16+
steps:
17+
- name: Set up python ${{ matrix.python_version }}
18+
uses: actions/setup-python@v2
19+
with:
20+
python-version: ${{ matrix.python_version }}
21+
- name: Checkout repository
22+
uses: actions/checkout@v2
23+
with:
24+
ref: ${{ github.event.pull_request.head.ref }}
25+
repository: ${{ github.event.pull_request.head.repo.full_name }}
26+
- name: Install autonormalize with dev, and test requirements
27+
run: |
28+
pip config --site set global.progress_bar off
29+
python -m pip install --upgrade pip
30+
python -m pip install -e .
31+
python -m pip install -r dev-requirements.txt
32+
python -m pip install -r test-requirements.txt
33+
- name: Run lint test
34+
run: make lint

.github/workflows/tests.yml

Lines changed: 0 additions & 95 deletions
This file was deleted.
Lines changed: 51 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,51 @@
1+
on:
2+
pull_request:
3+
types: [opened, synchronize]
4+
push:
5+
branches:
6+
- main
7+
8+
name: Unit Tests - Latest Dependencies
9+
jobs:
10+
unit_tests:
11+
name: Unit Tests - Python ${{ matrix.python-version }}
12+
runs-on: ubuntu-latest
13+
strategy:
14+
matrix:
15+
python-version: ["3.7", "3.8", "3.9"]
16+
steps:
17+
- name: Set up python ${{ matrix.python_version }}
18+
uses: actions/setup-python@v2
19+
with:
20+
python-version: ${{ matrix.python_version }}
21+
- name: Checkout repository
22+
uses: actions/checkout@v2
23+
with:
24+
ref: ${{ github.event.pull_request.head.ref }}
25+
repository: ${{ github.event.pull_request.head.repo.full_name }}
26+
- name: Build source distribution
27+
run: make package_autonormalize
28+
- name: Install package with test requirements
29+
run: |
30+
sudo python -m pip config --site set global.progress_bar off
31+
python -m pip install --upgrade pip
32+
sudo apt update && sudo apt install -y graphviz
33+
python -m pip install -e unpacked_sdist/
34+
python -m pip install -r unpacked_sdist/test-requirements.txt
35+
- if: ${{ matrix.python_version == 3.7 }}
36+
name: Run unit tests with code coverage
37+
run: |
38+
python -m pip install "$(cat dev-requirements.txt | grep codecov)"
39+
coverage erase
40+
cd unpacked_sdist/
41+
coverage erase
42+
pytest autonormalize/ -n 2 --cov=autonormalize --cov-config=../.coveragerc
43+
env:
44+
PYARROW_IGNORE_TIMEZONE: 1
45+
ALTERYX_OPEN_SRC_UPDATE_CHECKER: False
46+
- if: ${{ matrix.python_version == 3.7 }}
47+
name: Upload coverage to Codecov
48+
uses: codecov/codecov-action@v1
49+
with:
50+
fail_ci_if_error: true
51+
token: ${{ secrets.CODECOV_TOKEN }}

Makefile

Lines changed: 23 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -1,39 +1,40 @@
1+
.PHONY: clean
2+
clean:
3+
find . -name '*.pyo' -delete
4+
find . -name '*.pyc' -delete
5+
find . -name __pycache__ -delete
6+
find . -name '*~' -delete
7+
18
.PHONY: entry-point-test
29
entry-point-test:
310
cd ~ && python -c "from featuretools import autonormalize"
411

5-
.PHONY: lint-fix
6-
lint-fix:
7-
select="E225,E303,E302,E203,E128,E231,E251,E271,E127,E126,E301,W291,W293,E226,E306,E221"
8-
autopep8 --in-place --recursive --max-line-length=100 --select=${select} autonormalize
9-
isort --recursive autonormalize
10-
1112
.PHONY: lint
1213
lint:
13-
flake8 autonormalize
14-
isort --check-only --recursive autonormalize
14+
flake8 autonormalize && isort --check-only autonormalize
1515

16-
.PHONY: lint_tests
17-
lint_tests:
18-
flake8 autonormalize
19-
isort --check-only --recursive autonormalize
16+
.PHONY: lint-fix
17+
lint-fix:
18+
autopep8 --in-place --recursive --max-line-length=100 --exclude="*/migrations/*" --select="E225,E303,E302,E203,E128,E231,E251,E271,E127,E126,E301,W291,W293,E226,E306,E221,E261,E111,E114" autonormalize
19+
isort autonormalize
2020

2121
.PHONY: test
2222
test: lint
23-
pytest autonormalize/
23+
pytest autonormalize/
2424

2525
.PHONY: testcoverage
2626
testcoverage: lint
2727
pytest autonormalize/ --cov=autonormalize
2828

29-
.PHONY: unit_tests
30-
unit_tests:
31-
pytest --cache-clear --show-capture=stderr -vv ${addopts}
29+
.PHONY: installdeps
30+
installdeps:
31+
pip install --upgrade pip
32+
pip install -e .
33+
pip install -r dev-requirements.txt
3234

33-
.PHONY: package_build
34-
package_build:
35-
rm -rf dist/package
35+
.PHONY: package_autonormalize
36+
package_autonormalize:
3637
python setup.py sdist
37-
$(eval package=$(shell python setup.py --fullname))
38-
tar -zxvf "dist/${package}.tar.gz"
39-
mv ${package} dist/package
38+
$(eval DT_VERSION=$(shell python setup.py --version))
39+
tar -zxvf "dist/autonormalize-${DT_VERSION}.tar.gz"
40+
mv "autonormalize-${DT_VERSION}" unpacked_sdist

0 commit comments

Comments
 (0)