-
Notifications
You must be signed in to change notification settings - Fork 3.3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* add simple CircleCI * ignore some * note
- Loading branch information
Showing
1 changed file
with
71 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,71 @@ | ||
# Python CircleCI 2.0 configuration file | ||
# | ||
# Check https://circleci.com/docs/2.0/language-python/ for more details | ||
# | ||
version: 2.0 | ||
|
||
references: | ||
|
||
install_deps: &install_deps | ||
run: | ||
name: Install Dependences | ||
command: | | ||
sudo apt-get update && sudo apt-get install -y cmake | ||
pip install -r requirements/base.txt -q | ||
pip install -r requirements/test.txt -q | ||
tests: &tests | ||
run: | ||
name: Testing | ||
command: | | ||
python --version ; pip --version ; pip list | ||
python -m pytest pytorch_lightning -v --junitxml=test-reports/pytest_junit.xml --ignore=pytorch_lightning/loggers/comet.py --ignore=pytorch_lightning/loggers/mlflow.py --ignore=pytorch_lightning/loggers/neptune.py --ignore=pytorch_lightning/loggers/test_tube.py --ignore=pytorch_lightning/loggers/wandb.py --ignore=pytorch_lightning/metrics/sklearns.py | ||
no_output_timeout: 15m | ||
|
||
make_docs: &make_docs | ||
run: | ||
name: Make Documentation | ||
command: | | ||
# First run the same pipeline as Read-The-Docs | ||
# apt-get update && apt-get install -y cmake | ||
# using: https://hub.docker.com/r/readthedocs/build | ||
# we need to use py3.7 ot higher becase of an issue with metaclass inheritence | ||
pyenv global 3.7.3 | ||
python --version | ||
pip install -r requirements/docs.txt | ||
cd docs; make clean; make html --debug --jobs 2 SPHINXOPTS="-W" | ||
jobs: | ||
|
||
Build-Docs: | ||
docker: | ||
- image: readthedocs/build:latest | ||
steps: | ||
- checkout | ||
- *make_docs | ||
- store_artifacts: | ||
# allows us to preview the generated html pages | ||
path: docs/build/html/ | ||
destination: html | ||
|
||
CPU-Tests: | ||
# todo: to be replaced by TPU tests | ||
docker: | ||
- image: circleci/python:3.6 | ||
environment: | ||
- TORCH_VERSION: "torch" | ||
steps: &steps | ||
- checkout | ||
- *install_deps | ||
- *tests | ||
- store_test_results: | ||
path: test-reports | ||
- store_artifacts: | ||
path: test-reports | ||
|
||
workflows: | ||
version: 2 | ||
build: | ||
jobs: | ||
- Build-Docs | ||
- CPU-Tests |