@@ -55,10 +55,16 @@ jobs:
5555 build-wheels :
5656 name : Build wheels
5757 runs-on : ${{ matrix.os }}
58- needs : is-duplicate
58+ needs : test-code
5959 if : |
60- needs.is-duplicate.outputs.should_skip != 'true' &&
61- startsWith(github.ref, 'refs/heads/develop')
60+ !failure() &&
61+ (
62+ startsWith(github.ref, 'refs/heads/develop') ||
63+ (
64+ github.event_name == 'push' &&
65+ startsWith(github.ref, 'refs/tags/v')
66+ )
67+ )
6268 strategy :
6369 matrix :
6470 os : [ubuntu-latest, macos-latest, windows-latest]
@@ -81,10 +87,16 @@ jobs:
8187 build-sdist :
8288 name : Build source distribution
8389 runs-on : ubuntu-latest
84- needs : is-duplicate
90+ needs : test-code
8591 if : |
86- needs.is-duplicate.outputs.should_skip != 'true' &&
87- startsWith(github.ref, 'refs/heads/develop')
92+ !failure() &&
93+ (
94+ startsWith(github.ref, 'refs/heads/develop') ||
95+ (
96+ github.event_name == 'push' &&
97+ startsWith(github.ref, 'refs/tags/v')
98+ )
99+ )
88100
89101 steps :
90102 - name : Check out code
@@ -107,7 +119,7 @@ jobs:
107119 name : Publish to TestPyPI
108120 environment : staging
109121 runs-on : ubuntu-latest
110- needs : [test-code, build-sdist, build-wheels]
122+ needs : [build-sdist, build-wheels]
111123 if : |
112124 !failure() &&
113125 github.event_name == 'push' &&
0 commit comments