@@ -3,23 +3,26 @@ dist: xenial
3
3
4
4
matrix :
5
5
include :
6
- - os : windows
7
- language : sh
8
- env : PYTHON_ROOT="/c/Python37" PYTHON_CHOCO_PKG="python3"
9
- - os : windows
10
- language : sh
11
- env : PYTHON_ROOT="/c/Python27" PYTHON_CHOCO_PKG="python2"
6
+ # - os: windows
7
+ # language: sh
8
+ # env: PYTHON_ROOT="/c/Python37" PYTHON_CHOCO_PKG="python3"
9
+ # - os: windows
10
+ # language: sh
11
+ # env: PYTHON_ROOT="/c/Python27" PYTHON_CHOCO_PKG="python2"
12
+ # - os: linux
13
+ # dist: trusty
14
+ # python: "pypy3"
15
+ # - os: linux
16
+ # python: 3.7
17
+ # - os: linux
18
+ # python: 3.6
19
+ # - os: linux
20
+ # python: 3.5
21
+ # - os: linux
22
+ # python: 2.7
12
23
- os : linux
13
- dist : trusty
14
- python : " pypy3"
15
- - os : linux
16
- python : 3.7
17
- - os : linux
18
- python : 3.6
19
- - os : linux
20
- python : 3.5
21
- - os : linux
22
- python : 2.7
24
+ # running python 3.8
25
+ env : BUILD_PY_FROM_SOURCE=1
23
26
- os : linux
24
27
# The PROJECT environment variable refers to a downstream project that
25
28
# depends on cloudpickle (for example: distributed, joblib, loky). For
@@ -54,34 +57,50 @@ before_install:
54
57
export PATH="$PYTHON_ROOT:$PYTHON_ROOT/Scripts:$PATH";
55
58
python -m pip install --upgrade pip;
56
59
fi
60
+ - if [[ "$BUILD_PY_FROM_SOURCE" == 1 ]]; then
61
+ export VENV_DIR="$HOME/python38";
62
+ pushd ..;
63
+ git clone https://github.com/pierreglaser/cpython.git;
64
+ pushd cpython;
65
+ git checkout add-global-hook;
66
+ ./configure;
67
+ make;
68
+ ./python -m venv "$VENV_DIR";
69
+ popd;
70
+ popd;
71
+ export PYTHON_EXE="$VENV_DIR/bin/python";
72
+ else
73
+ export PYTHON_EXE="python";
74
+ fi
75
+
57
76
install :
58
- - pip install .
59
- - pip install --upgrade -r dev-requirements.txt
60
- - pip install tornado
61
- - if [[ $TRAVIS_PYTHON_VERSION != 'pypy'* ]]; then
62
- pip install numpy scipy;
77
+ - $PYTHON_EXE -m pip install .
78
+ - $PYTHON_EXE -m pip install --upgrade -r dev-requirements.txt
79
+ - $PYTHON_EXE -m pip install tornado
80
+ - if [[ $TRAVIS_PYTHON_VERSION != 'pypy'* && "$BUILD_PY_FROM_SOURCE" != 1 ]]; then
81
+ $PYTHON_EXE -m pip install numpy scipy;
63
82
fi
64
83
- if [[ $PROJECT != "" ]]; then
65
- pip install $TEST_REQUIREMENTS;
84
+ $PYTHON_EXE -m pip install $TEST_REQUIREMENTS;
66
85
pushd ..;
67
86
git clone $PROJECT_URL;
68
87
if [[ $PROJECT == "joblib" ]]; then
69
88
pushd joblib/joblib/externals;
70
89
source vendor_cloudpickle.sh ../../../cloudpickle;
71
90
popd;
72
91
fi;
73
- pip install ./$PROJECT;
92
+ $PYTHON_EXE -m pip install ./$PROJECT;
74
93
popd;
75
94
fi
76
- - pip list
95
+ - $PYTHON_EXE -m pip list
77
96
before_script :
78
97
# stop the build if there are Python syntax errors or undefined names
79
- - flake8 . --count --select=E901,E999,F821,F822,F823 --show-source --statistics
98
+ - $PYTHON_EXE -m flake8 . --count --verbose --select=E901,E999,F821,F822,F823 --show-source --statistics
80
99
# exit-zero treats all errors as warnings. The GitHub editor is 127 chars wide
81
- - flake8 . --count --exit-zero --max-complexity=10 --max-line-length=127 --statistics
82
- - python ci/install_coverage_subprocess_pth.py
100
+ - $PYTHON_EXE -m flake8 . --count --exit-zero --max-complexity=10 --max-line-length=127 --statistics
101
+ - $PYTHON_EXE ci/install_coverage_subprocess_pth.py
83
102
script :
84
- - COVERAGE_PROCESS_START="$TRAVIS_BUILD_DIR/.coveragerc" PYTHONPATH='.:tests' pytest -r s
103
+ - COVERAGE_PROCESS_START="$TRAVIS_BUILD_DIR/.coveragerc" PYTHONPATH='.:tests' $PYTHON_EXE -m pytest -r s
85
104
- |
86
105
if [[ $PROJECT != "" ]]; then
87
106
pushd ../$PROJECT
0 commit comments