diff --git a/backwards-compat-tests/scripts/run_local.sh b/backwards-compat-tests/scripts/run_local.sh index bf2f09c6841a4..81545f70b77a8 100755 --- a/backwards-compat-tests/scripts/run_local.sh +++ b/backwards-compat-tests/scripts/run_local.sh @@ -47,7 +47,7 @@ EOF setup_old_cluster() { echo "--- Setting up old cluster" LATEST_BRANCH=$(git branch --show-current) - git checkout "v${OLD_VERSION}-rc" + git checkout "v${OLD_VERSION}" } setup_new_cluster() { diff --git a/backwards-compat-tests/scripts/utils.sh b/backwards-compat-tests/scripts/utils.sh index e047b9f44f421..9d5fdeb1773bc 100644 --- a/backwards-compat-tests/scripts/utils.sh +++ b/backwards-compat-tests/scripts/utils.sh @@ -132,13 +132,14 @@ get_rw_versions() { echo "--- git branch origin output" git branch -r | grep origin + # Extract X.Y.Z tags echo "--- VERSION BRANCHES" - local branches=$(git branch -r | grep -E "^ origin\/v[0-9]*\.[0-9]*.*-rc" | tr -d ' ' | sed -E 's/origin\/v([0-9]*\.[0-9])\-rc/\1.0/' | tr -d '\-vrcorigin\/' | tr -d ' ') - echo "$branches" + local tags=$(git tag | grep -E "^v[0-9]+\.[0-9]+\.[0-9]+$" | tr -d 'v' | tr -d ' ') + echo "$tags" # Then we sort them in descending order. echo "--- VERSIONS" - local sorted_versions=$(echo -e "$branches" | sort -t '.' -n) + local sorted_versions=$(echo -e "$tags" | sort -t '.' -n) echo "$sorted_versions" # Then we take the Nth latest version. diff --git a/ci/scripts/backwards-compat-test.sh b/ci/scripts/backwards-compat-test.sh index 1c1b4d388faa9..9e86e3807db35 100755 --- a/ci/scripts/backwards-compat-test.sh +++ b/ci/scripts/backwards-compat-test.sh @@ -74,7 +74,7 @@ EOF setup_old_cluster() { echo "--- Build risedev for $OLD_VERSION, it may not be backwards compatible" git config --global --add safe.directory /risingwave - git checkout "v${OLD_VERSION}-rc" + git checkout "v${OLD_VERSION}" cargo build -p risedev OLD_URL=https://github.com/risingwavelabs/risingwave/releases/download/v${OLD_VERSION}/risingwave-v${OLD_VERSION}-x86_64-unknown-linux.tar.gz wget $OLD_URL