File tree 2 files changed +71
-4
lines changed
2 files changed +71
-4
lines changed Original file line number Diff line number Diff line change
1
+ name : Setup Python and install requirements
2
+ inputs :
3
+ python-version :
4
+ required : true
5
+ architecture :
6
+ default : x64
7
+ runs :
8
+ using : composite
9
+ steps :
10
+ # TODO: GH#44980 https://github.com/pypa/setuptools/issues/2941
11
+ - name : Create temporary requirements.txt
12
+ run : |
13
+ # Drop cache at least once per month
14
+ month_today="$(date '+%Y-%m')"
15
+ cat > requirements.txt <<EOF
16
+ # $month_today
17
+
18
+ # Python deps
19
+ pip
20
+ setuptools<60.0.0
21
+ wheel
22
+
23
+ # Pandas deps
24
+ # GH 39416
25
+ numpy
26
+ cython
27
+ python-dateutil
28
+ pytz
29
+
30
+ # Test deps
31
+ git+https://github.com/nedbat/coveragepy.git
32
+ hypothesis
33
+ pytest>=6.2.5
34
+ pytest-xdist
35
+ pytest-cov
36
+ pytest-asyncio>=0.17
37
+ EOF
38
+ shell : bash -el {0}
39
+
40
+ - name : Set up Python
41
+ uses : actions/setup-python@v3
42
+ with :
43
+ python-version : ${{ inputs.python-version }}
44
+ architecture : ${{ inputs.architecture }}
45
+ cache : pip
46
+
47
+ - name : Fix $PATH on macOS
48
+ run : |
49
+ # On macOS, the Python version we installed above is too late in $PATH
50
+ # to be effective if using "bash -l" (which we need for code that works
51
+ # with Conda envs).
52
+ cat >> ~/.bash_profile <<EOF
53
+ export PATH="\$(echo "\$PATH" | grep -Eio '[^:]+hostedtoolcache/python[^:]+bin'):\$PATH" \
54
+ EOF
55
+ shell : bash -el {0}
56
+ if : ${{ runner.os == 'macOS' }}
57
+
58
+ - name : Install dependencies
59
+ run : |
60
+ cat requirements.txt
61
+ # TODO https://github.com/numpy/numpy/issues/21196
62
+ bits32=$(python -c 'import sys; print(int(sys.maxsize > 2**32))')
63
+ NPY_DISABLE_SVML=$bits32 pip install -r requirements.txt
64
+ pip list
65
+ shell : bash -el {0}
Original file line number Diff line number Diff line change 14
14
- " doc/**"
15
15
16
16
jobs :
17
- build :
18
- if : ${{ github.event.label.name == 'Build' || contains(github.event.pull_request.labels.*.name, 'Build') || github.event_name == 'push'}}
17
+ sdist :
18
+ # if: ${{ github.event.label.name == 'Build' || contains(github.event.pull_request.labels.*.name, 'Build') || github.event_name == 'push'}}
19
19
runs-on : ubuntu-latest
20
20
timeout-minutes : 60
21
21
defaults :
26
26
fail-fast : false
27
27
matrix :
28
28
python-version : ["3.8", "3.9", "3.10"]
29
+ name : sdist Python ${{ matrix.python-version }}
30
+
29
31
concurrency :
30
32
# https://github.community/t/concurrecy-not-work-for-push/183068/7
31
33
group : ${{ github.event_name == 'push' && github.run_number || github.ref }}-${{matrix.python-version}}-sdist
36
38
with :
37
39
fetch-depth : 0
38
40
39
- - name : Set up Python
40
- uses : actions/setup-python@v3
41
+ - name : Set up Python ${{ matrix.python-version }} and install dependencies
42
+ uses : ./.github/ actions/setup-python
41
43
with :
42
44
python-version : ${{ matrix.python-version }}
43
45
You can’t perform that action at this time.
0 commit comments