Skip to content
This repository was archived by the owner on Sep 10, 2025. It is now read-only.

Commit 3d8d031

Browse files
authored
Fix validation workflow for test channel (#2071)
* Validate test binaries test * Fix validate binaries for py3.11 * fix lint * remove temp change
1 parent b01660b commit 3d8d031

File tree

2 files changed

+12
-2
lines changed

2 files changed

+12
-2
lines changed

.github/scripts/validate_binaries.sh

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,11 @@
11

22
if [[ ${MATRIX_PACKAGE_TYPE} = "conda" ]]; then
3-
conda install -y torchtext -c ${PYTORCH_CONDA_CHANNEL}
3+
#special case for Python 3.11
4+
if [[ ${MATRIX_PYTHON_VERSION} == '3.11' ]]; then
5+
conda install -y torchtext -c malfet -c ${PYTORCH_CONDA_CHANNEL}
6+
else
7+
conda install -y torchtext -c ${PYTORCH_CONDA_CHANNEL}
8+
fi
49
else
510
pip install ${PYTORCH_PIP_PREFIX} torchtext --extra-index-url ${PYTORCH_PIP_DOWNLOAD_URL}
611
fi

test/smoke_tests/smoke_tests.py

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,14 @@
11
"""Run smoke tests"""
22

3+
import os
34
import re
45

56
import torchdata
67
import torchtext
78
import torchtext.version # noqa: F401
89

910
NIGHTLY_ALLOWED_DELTA = 3
11+
channel = os.getenv("MATRIX_CHANNEL")
1012

1113

1214
def validateTorchdataVersion():
@@ -19,5 +21,8 @@ def validateTorchdataVersion():
1921
raise RuntimeError(f"torchdata binary {torchdata.__version__} is more than {NIGHTLY_ALLOWED_DELTA} days old!")
2022

2123

22-
validateTorchdataVersion()
24+
if channel == "nightly":
25+
validateTorchdataVersion()
26+
2327
print("torchtext version is ", torchtext.__version__)
28+
print("torchdata version is ", torchdata.__version__)

0 commit comments

Comments
 (0)