@@ -23,90 +23,92 @@ concurrency:
23
23
permissions :
24
24
contents : read # to fetch code (actions/checkout)
25
25
26
- jobs :
26
+ env :
27
+ REDIS_STACK_IMAGE : redis/redis-stack-server:7.4.0-rc1
27
28
28
- dependency-audit :
29
- name : Dependency audit
30
- runs-on : ubuntu-latest
31
- steps :
32
- - uses : actions/checkout@v4
33
-
34
- with :
35
- inputs : requirements.txt dev_requirements.txt
36
- ignore-vulns : |
37
- GHSA-w596-4wvx-j9j6 # subversion related git pull, dependency for pytest. There is no impact here.
38
- PYSEC-2024-48 # black vulnerability in 22.3.0, can't upgrade due to python 3.7 support, no impact
29
+ jobs :
30
+ dependency-audit :
31
+ name : Dependency audit
32
+ runs-on : ubuntu-latest
33
+ steps :
34
+ - uses : actions/checkout@v4
35
+
36
+ with :
37
+ inputs : requirements.txt dev_requirements.txt
38
+ ignore-vulns : |
39
+ GHSA-w596-4wvx-j9j6 # subversion related git pull, dependency for pytest. There is no impact here.
40
+ PYSEC-2024-48 # black vulnerability in 22.3.0, can't upgrade due to python 3.7 support, no impact
39
41
40
- lint :
41
- name : Code linters
42
- runs-on : ubuntu-latest
43
- steps :
44
- - uses : actions/checkout@v4
45
- - uses : actions/setup-python@v5
46
- with :
47
- python-version : 3.9
48
- cache : ' pip'
49
- - name : run code linters
50
- run : |
51
- pip install -r dev_requirements.txt
52
- invoke linters
42
+ lint :
43
+ name : Code linters
44
+ runs-on : ubuntu-latest
45
+ steps :
46
+ - uses : actions/checkout@v4
47
+ - uses : actions/setup-python@v5
48
+ with :
49
+ python-version : 3.9
50
+ cache : ' pip'
51
+ - name : run code linters
52
+ run : |
53
+ pip install -r dev_requirements.txt
54
+ invoke linters
53
55
54
- run-tests :
55
- runs-on : ubuntu-latest
56
- timeout-minutes : 60
57
- strategy :
58
- max-parallel : 15
59
- fail-fast : false
60
- matrix :
61
- python-version : ['3.7', '3.8', '3.9', '3.10', '3.11', 'pypy-3.7', 'pypy-3.8', 'pypy-3.9']
62
- test-type : ['standalone', 'cluster']
63
- connection-type : ['hiredis', 'plain']
64
- env :
65
- ACTIONS_ALLOW_UNSECURE_COMMANDS : true
66
- name : Python ${{ matrix.python-version }} ${{matrix.test-type}}-${{matrix.connection-type}} tests
67
- steps :
68
- - uses : actions/checkout@v4
69
- - uses : actions/setup-python@v5
70
- with :
71
- python-version : ${{ matrix.python-version }}
72
- cache : ' pip'
73
- - name : run tests
74
- run : |
75
- pip install -U setuptools wheel
76
- pip install -r requirements.txt
77
- pip install -r dev_requirements.txt
78
- if [ "${{matrix.connection-type}}" == "hiredis" ]; then
79
- pip install hiredis
80
- fi
81
- invoke devenv
82
- sleep 10 # time to settle
83
- invoke ${{matrix.test-type}}-tests
56
+ run-tests :
57
+ runs-on : ubuntu-latest
58
+ timeout-minutes : 60
59
+ strategy :
60
+ max-parallel : 15
61
+ fail-fast : false
62
+ matrix :
63
+ python-version : ['3.7', '3.8', '3.9', '3.10', '3.11', 'pypy-3.7', 'pypy-3.8', 'pypy-3.9']
64
+ test-type : ['standalone', 'cluster']
65
+ connection-type : ['hiredis', 'plain']
66
+ env :
67
+ ACTIONS_ALLOW_UNSECURE_COMMANDS : true
68
+ name : Python ${{ matrix.python-version }} ${{matrix.test-type}}-${{matrix.connection-type}} tests
69
+ steps :
70
+ - uses : actions/checkout@v4
71
+ - uses : actions/setup-python@v5
72
+ with :
73
+ python-version : ${{ matrix.python-version }}
74
+ cache : ' pip'
75
+ - name : run tests
76
+ run : |
77
+ pip install -U setuptools wheel
78
+ pip install -r requirements.txt
79
+ pip install -r dev_requirements.txt
80
+ if [ "${{matrix.connection-type}}" == "hiredis" ]; then
81
+ pip install hiredis
82
+ fi
83
+ invoke devenv
84
+ sleep 10 # time to settle
85
+ invoke ${{matrix.test-type}}-tests
84
86
85
- - uses : actions/upload-artifact@v4
86
- if : success() || failure()
87
- with :
88
- name : pytest-results-${{matrix.test-type}}-${{matrix.connection-type}}-${{matrix.python-version}}
89
- path : ' ${{matrix.test-type}}*results.xml'
87
+ - uses : actions/upload-artifact@v4
88
+ if : success() || failure()
89
+ with :
90
+ name : pytest-results-${{matrix.test-type}}-${{matrix.connection-type}}-${{matrix.python-version}}
91
+ path : ' ${{matrix.test-type}}*results.xml'
90
92
91
- - name : Upload codecov coverage
92
- uses : codecov/codecov-action@v4
93
- with :
94
- fail_ci_if_error : false
93
+ - name : Upload codecov coverage
94
+ uses : codecov/codecov-action@v4
95
+ with :
96
+ fail_ci_if_error : false
95
97
96
- - name : View Test Results
97
- uses : dorny/test-reporter@v1
98
- if : success() || failure()
99
- continue-on-error : true
100
- with :
101
- name : Test Results ${{matrix.python-version}} ${{matrix.test-type}}-${{matrix.connection-type}}
102
- path : ' *.xml'
103
- reporter : java-junit
104
- list-suites : all
105
- list-tests : all
106
- max-annotations : 10
107
- fail-on-error : ' false'
98
+ - name : View Test Results
99
+ uses : dorny/test-reporter@v1
100
+ if : success() || failure()
101
+ continue-on-error : true
102
+ with :
103
+ name : Test Results ${{matrix.python-version}} ${{matrix.test-type}}-${{matrix.connection-type}}
104
+ path : ' *.xml'
105
+ reporter : java-junit
106
+ list-suites : all
107
+ list-tests : all
108
+ max-annotations : 10
109
+ fail-on-error : ' false'
108
110
109
- resp3_tests :
111
+ resp3_tests :
110
112
runs-on : ubuntu-latest
111
113
strategy :
112
114
fail-fast : false
@@ -116,7 +118,7 @@ jobs:
116
118
connection-type : ['hiredis', 'plain']
117
119
protocol : ['3']
118
120
env :
119
- ACTIONS_ALLOW_UNSECURE_COMMANDS : true
121
+ ACTIONS_ALLOW_UNSECURE_COMMANDS : true
120
122
name : RESP3 [${{ matrix.python-version }} ${{matrix.test-type}}-${{matrix.connection-type}}]
121
123
steps :
122
124
- uses : actions/checkout@v4
@@ -137,7 +139,7 @@ jobs:
137
139
invoke ${{matrix.test-type}}-tests
138
140
invoke ${{matrix.test-type}}-tests --uvloop
139
141
140
- build_and_test_package :
142
+ build_and_test_package :
141
143
name : Validate building and installing the package
142
144
runs-on : ubuntu-latest
143
145
needs : [run-tests]
@@ -154,7 +156,7 @@ jobs:
154
156
run : |
155
157
bash .github/workflows/install_and_test.sh ${{ matrix.extension }}
156
158
157
- install_package_from_commit :
159
+ install_package_from_commit :
158
160
name : Install package from commit hash
159
161
runs-on : ubuntu-latest
160
162
strategy :
0 commit comments