QuakeWang commented on code in PR #557:
URL: https://github.com/apache/paimon-rust/pull/557#discussion_r3618924485
##########
.github/workflows/release_python_binding.yml:
##########
@@ -70,6 +83,14 @@ jobs:
steps:
- uses: actions/checkout@v7
+ - name: Set Python release version
+ env:
+ RELEASE_TAG: ${{ inputs.tag || github.ref_name }}
+ run: >
+ python3 scripts/python_release_version.py
+ --tag "${RELEASE_TAG}"
Review Comment:
The `wheels` matrix includes `windows-latest`, where `run` uses PowerShell
by default. `${RELEASE_TAG}` does not read the environment variable in
PowerShell, so the Windows wheel job receives an empty tag and fails.
##########
scripts/python_release_version.py:
##########
@@ -0,0 +1,82 @@
+#!/usr/bin/env python3
+
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements. See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+"""Set a unique Python version for release-candidate artifacts."""
+
+from __future__ import annotations
+
+import argparse
+import re
+import sys
+import tomllib
+from pathlib import Path
+
+
+TAG_PATTERN = re.compile(r"^v(?P<base>\d+\.\d+\.\d+)(?:-rc(?P<rc>[1-9]\d*))?$")
Review Comment:
The workflow tag filter accepts `vX.Y.Z-rc0`, but this pattern rejects it.
Such a tag will trigger the release workflow and then fail during version
validation.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]