Skip to content

Commit 79d552a

Browse files
authored
Revert the changes applied in #3821 + #3822 (#3825)
Reverts our `releases.yml` workflow to the state as of 93dd0e4, i.e. no option to publish a tag declared in workflow dispatch.
1 parent b76e006 commit 79d552a

File tree

1 file changed

+1
-28
lines changed

1 file changed

+1
-28
lines changed

.github/workflows/releases.yml

Lines changed: 1 addition & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -6,11 +6,6 @@ on:
66
pull_request:
77
branches: [main]
88
workflow_dispatch:
9-
inputs:
10-
tag:
11-
description: 'Git tag to build and publish (e.g. v3.1.6)'
12-
required: true
13-
type: string
149

1510
permissions:
1611
contents: read
@@ -21,26 +16,7 @@ concurrency:
2116

2217
jobs:
2318

24-
validate_tag:
25-
if: github.event_name == 'workflow_dispatch'
26-
runs-on: ubuntu-latest
27-
steps:
28-
- name: Validate tag format
29-
run: |
30-
if [[ ! "${{ inputs.tag }}" =~ ^v[0-9]+\.[0-9]+\.[0-9]+([a-z]+[0-9]*)?$ ]]; then
31-
echo "::error::Invalid tag format '${{ inputs.tag }}'. Expected format: v1.2.3, v1.2.3a1, v1.2.3rc1"
32-
exit 1
33-
fi
34-
- name: Verify tag exists
35-
run: |
36-
git ls-remote --tags "${{ github.server_url }}/${{ github.repository }}" "${{ inputs.tag }}" | grep -q "${{ inputs.tag }}" || {
37-
echo "::error::Tag '${{ inputs.tag }}' does not exist in the repository"
38-
exit 1
39-
}
40-
4119
build_artifacts:
42-
needs: [validate_tag]
43-
if: always() && (needs.validate_tag.result == 'success' || needs.validate_tag.result == 'skipped')
4420
name: Build wheel on ubuntu-latest
4521
runs-on: ubuntu-latest
4622
strategy:
@@ -49,7 +25,6 @@ jobs:
4925
steps:
5026
- uses: actions/checkout@v6
5127
with:
52-
ref: ${{ inputs.tag || github.ref }}
5328
submodules: true
5429
fetch-depth: 0
5530

@@ -86,9 +61,7 @@ jobs:
8661
upload_pypi:
8762
needs: [build_artifacts, test_dist_pypi]
8863
runs-on: ubuntu-latest
89-
if: >-
90-
(github.event_name == 'push' && startsWith(github.event.ref, 'refs/tags/v'))
91-
|| (github.event_name == 'workflow_dispatch' && startsWith(inputs.tag, 'v'))
64+
if: github.event_name == 'push' && startsWith(github.event.ref, 'refs/tags/v')
9265
environment:
9366
name: releases
9467
url: https://pypi.org/p/zarr

0 commit comments

Comments
 (0)