forked from facebook/Ax
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.travis.yml
82 lines (78 loc) · 2.8 KB
/
.travis.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
language: python
python:
- 3.6
jobs:
allow_failures:
# create custom environment variable for flagging jobs that are allowed to fail
- env: ALLOW_FAILURE=true
include:
- name: "Tests + Coverage: Python 3.6"
stage: Test
python: "3.6"
install:
- pip install cython numpy
- pip install git+https://github.com/cornellius-gp/gpytorch.git
- pip install git+https://github.com/pytorch/botorch.git
- pip install -q -e .[dev,mysql,notebook]
script:
- pytest -ra --cov=ax
- name: "Tests: Python 3.7"
# Enable Python 3.7 w/o without globally enabling sudo and xenial dist
# See https://github.com/travis-ci/travis-ci/issues/9815
python: "3.7"
dist: xenial
install:
- pip install cython numpy
- pip install git+https://github.com/cornellius-gp/gpytorch.git
- pip install git+https://github.com/pytorch/botorch.git
- pip install -q -e .[dev,mysql,notebook]
script:
- pytest -ra
- name: "Lint: black (Python 3.6)"
python: "3.6"
install:
- pip install black
script:
- black --check --diff .
- name: "Lint: flake8 (Python 3.6)"
python: "3.6"
install:
- pip install flake8
script:
# don't use .flake8 config for now, since don't need custom plugin
- flake8 --isolated --ignore=T484,T499,W503,E704,E231,E203 --max-line-length=88
- name: "Docs: Sphinx (Python 3.6)"
python: "3.6"
install:
- pip install cython numpy
- pip install git+https://github.com/cornellius-gp/gpytorch.git
- pip install git+https://github.com/pytorch/botorch.git
- pip install -q -e .[dev,mysql,notebook,gpy]
script:
# warnings treated as errors
- sphinx-build -WT sphinx/source sphinx/build
# since -W flag breaks on first error, re-run without it to print all
- sphinx-build sphinx/source sphinx/build
- name: "Docs: Sphinx Coverage (Python 3.6)"
python: "3.6"
# Allow failure for now, until missing modules are added to documentation.
env: ALLOW_FAILURE=true
script:
- python3 scripts/validate_sphinx.py -p "${pwd}"
- stage: Deploy Website
python: "3.6"
install:
- pip install cython numpy
- pip install git+https://github.com/cornellius-gp/gpytorch.git
- pip install git+https://github.com/pytorch/botorch.git
- pip install -q -e .[dev,mysql,notebook]
- pip install torchvision # required for tutorials
script:
- travis_wait 90 bash scripts/publish_site.sh -d
stages:
- name: Test
- name: Deploy Website
# require the branch name to be master & only build daily
if: branch = master AND type = cron
after_success:
- bash <(curl -s https://codecov.io/bash)