This is an automated email from the ASF dual-hosted git repository.

jiadongb pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/texera.git


The following commit(s) were added to refs/heads/main by this push:
     new ab9a84b198 fix(ci): use consistent 9-char commit hash for image tags 
(#4231)
ab9a84b198 is described below

commit ab9a84b198a4c9430c3591649b802b33158cac3f
Author: Jiadong Bai <[email protected]>
AuthorDate: Mon Feb 23 11:39:19 2026 -0800

    fix(ci): use consistent 9-char commit hash for image tags (#4231)
    
    ### What changes were proposed in this PR?
    
    Standardize the commit hash length used for image tags across both
    workflows to 9 characters.
    
    The `build-and-push-images` workflow used `sha[:7]` (7 chars) while
    `create-release-candidate` used `git rev-parse --short` (variable
    length, 9 chars in this repo). This mismatch caused `manifest unknown`
    errors when running `docker compose up` from the release bundle.
    
    Changes:
    - `build-and-push-images.yml`: `sha[:7]` → `sha[:9]`
    - `create-release-candidate.yml`: `git rev-parse --short` → `git
    rev-parse --short=9`
    
    ### Any related issues, documentation, discussions?
    
    Fixes #4230
    
    ### How was this PR tested?
    
    - Verified `docker pull ghcr.io/apache/texera-dashboard-service:9fd356c`
    (7-char) succeeds but `9fd356c3b` (9-char) fails, confirming the
    mismatch
    - Fixed the `.env` locally and confirmed all 11 containers start
    successfully with `docker compose up -d`
    - Verified `git rev-parse --short=9` produces a consistent 9-char hash
    in this repo
    
    ### Was this PR authored or co-authored using generative AI tooling?
    
    Generated-by: Claude Code (Claude Opus 4.6)
    
    Co-authored-by: Claude Opus 4.6 <[email protected]>
---
 .github/workflows/build-and-push-images.yml    | 2 +-
 .github/workflows/create-release-candidate.yml | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/.github/workflows/build-and-push-images.yml 
b/.github/workflows/build-and-push-images.yml
index 94011e036f..065b10ccc6 100644
--- a/.github/workflows/build-and-push-images.yml
+++ b/.github/workflows/build-and-push-images.yml
@@ -99,7 +99,7 @@ jobs:
 
             # If image_tag is empty, resolve to the short commit hash of the 
branch
             if [[ -z "$IMAGE_TAG" ]]; then
-              COMMIT_SHORT=$(gh api "repos/${{ github.repository 
}}/commits/${BRANCH}" --jq '.sha[:7]')
+              COMMIT_SHORT=$(gh api "repos/${{ github.repository 
}}/commits/${BRANCH}" --jq '.sha[:9]')
               IMAGE_TAG="$COMMIT_SHORT"
               echo "No image tag specified - using short commit hash: 
$IMAGE_TAG"
             fi
diff --git a/.github/workflows/create-release-candidate.yml 
b/.github/workflows/create-release-candidate.yml
index d15f415a90..3f2fca55a3 100644
--- a/.github/workflows/create-release-candidate.yml
+++ b/.github/workflows/create-release-candidate.yml
@@ -85,7 +85,7 @@ jobs:
           fi
 
           COMMIT_HASH=$(git rev-parse "$TAG_NAME")
-          COMMIT_SHORT=$(git rev-parse --short "$TAG_NAME")
+          COMMIT_SHORT=$(git rev-parse "$TAG_NAME" | cut -c1-9)
           RC_DIR="${VERSION}-RC${RC_NUM}"
           SRC_TARBALL="apache-texera-${VERSION}-src.tar.gz"
           COMPOSE_TARBALL="apache-texera-${VERSION}-docker-compose.tar.gz"

Reply via email to