File tree Expand file tree Collapse file tree 1 file changed +11
-1
lines changed Expand file tree Collapse file tree 1 file changed +11
-1
lines changed Original file line number Diff line number Diff line change @@ -160,10 +160,20 @@ jobs:
160160 run : git fetch origin master:refs/remotes/origin/master
161161 - name : Set up Python ${{ matrix.python-version }}
162162 # we use containers to use the native python version from them
163- if : ${{ !matrix.container }}
163+ if : ${{ !matrix.container && matrix.python-version != '2.7' }}
164164 uses : actions/setup-python@v2
165165 with :
166166 python-version : ${{ matrix.python-version }}
167+ - name : Ensure python 2.7
168+ if : matrix.python-version == '2.7'
169+ run : |
170+ sudo apt-get update
171+ sudo apt-get install -y \
172+ python2.7 python2.7-dev python-pip-whl
173+ sudo ln -sf python2.7 /usr/bin/python
174+ export PYTHONPATH=`echo /usr/share/python-wheels/pip-*py2*.whl`
175+ sudo --preserve-env=PYTHONPATH python -m pip install --upgrade pip setuptools wheel
176+ sudo chown -R $USER /usr/local/lib/python2.7
167177 - name : Display Python version
168178 run : python -c "import sys; print(sys.version)"
169179 - name : Display installed python package versions
You can’t perform that action at this time.
0 commit comments