CI: Fix Roll PyTorch CI failure at determining commit hash (#2796)

Signed-Off By: Vivek Khandelwal <vivekkhandelwal1424@gmail.com>
pull/2738/head snapshot-20240124.1093
Vivek Khandelwal 2024-01-24 15:55:12 +05:30 committed by GitHub
parent ccaac85788
commit 311b6b0286
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 1 additions and 1 deletions

View File

@ -68,7 +68,7 @@ jobs:
printf -- "-f https://download.pytorch.org/whl/nightly/cpu/torch_nightly.html\n--pre\ntorchvision==%s\n" "${VISION_RELEASE}" > torchvision-requirements.txt printf -- "-f https://download.pytorch.org/whl/nightly/cpu/torch_nightly.html\n--pre\ntorchvision==%s\n" "${VISION_RELEASE}" > torchvision-requirements.txt
# Read the commit hash from the downloaded whl file without extracting it # Read the commit hash from the downloaded whl file without extracting it
PT_HASH=$(unzip -p torch-"${PT_RELEASE}"*.whl torch/version.py | grep git_version | awk '{ print $3 }' | tr -d "'") PT_HASH=$(unzip -p torch-"${PT_RELEASE}"*.whl torch/version.py | grep git_version | tail -1 | awk '{ print $3 }' | tr -d "'")
echo "Found torch commit hash ${PT_HASH}" echo "Found torch commit hash ${PT_HASH}"
PT_HASH_CHANGED=0 PT_HASH_CHANGED=0