From cabfb2bc315085ba790f3d2a6c454a93d5437b81 Mon Sep 17 00:00:00 2001 From: zhangxinyuehfad <59153331+zhangxinyuehfad@users.noreply.github.com> Date: Mon, 14 Jul 2025 15:43:37 +0800 Subject: [PATCH] [Test] Resolve vllm-ascend version accuracy test (#1769) ### What this PR does / why we need it? Resolve vllm-ascend version for accuracy test ### Does this PR introduce _any_ user-facing change? ### How was this patch tested? - vLLM version: v0.9.2 - vLLM main: https://github.com/vllm-project/vllm/commit/66f6fbd393721c98440436ab067304ac4331219c Signed-off-by: hfadzxy --- .github/workflows/accuracy_test.yaml | 18 +++++++++++++++++- 1 file changed, 17 insertions(+), 1 deletion(-) diff --git a/.github/workflows/accuracy_test.yaml b/.github/workflows/accuracy_test.yaml index 2eb2661..d367b31 100644 --- a/.github/workflows/accuracy_test.yaml +++ b/.github/workflows/accuracy_test.yaml @@ -169,6 +169,23 @@ jobs: working-directory: ./vllm-empty run: VLLM_TARGET_DEVICE=empty pip install -e . + - name: Resolve vllm-ascend version + run: | + VERSION_INPUT="${{ github.event.inputs.vllm-ascend-version }}" + + if [[ "$VERSION_INPUT" == "main" ]]; then + TAGS=$(git ls-remote --tags --sort=-v:refname https://github.com/vllm-project/vllm-ascend "v*" | cut -f2 | sed 's|refs/tags/||') + LATEST_TAG=$(echo "$TAGS" | head -n1) + if [[ -z "$LATEST_TAG" ]]; then + RESOLVED_VERSION="main" + else + RESOLVED_VERSION="$LATEST_TAG" + fi + else + RESOLVED_VERSION="$VERSION_INPUT" + fi + echo "GHA_VLLM_ASCEND_VERSION=$RESOLVED_VERSION" >> $GITHUB_ENV + - name: Checkout vllm-project/vllm-ascend repo uses: actions/checkout@v4 with: @@ -224,7 +241,6 @@ jobs: pip show torch | grep "Version:" | awk '{print "GHA_TORCH_VERSION="$2}' pip show torch_npu | grep "Version:" | awk '{print "GHA_TORCH_NPU_VERSION="$2}' pip show vllm | grep "Version:" | awk '{print "GHA_VLLM_VERSION="$2}' | sed 's/+.*//' - echo "GHA_VLLM_ASCEND_VERSION=${{ github.event.inputs.vllm-ascend-version || github.ref }}" } >> "$GITHUB_ENV" - name: Print versions