Skip to content

Commit 65218d4

Browse files
authored
Reland "binary: Add check for git_version (#1044)" (#1047)
1 parent 67a37ab commit 65218d4

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

check_binary.sh

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -310,6 +310,16 @@ else
310310
popd
311311
fi
312312

313+
###############################################################################
314+
# Check torch.git_version
315+
###############################################################################
316+
if [[ "$PACKAGE_TYPE" != 'libtorch' ]]; then
317+
pushd /tmp
318+
python -c 'import torch; assert torch.version.git_version != "Unknown"'
319+
python -c 'import torch; assert torch.version.git_version != None'
320+
popd
321+
fi
322+
313323

314324
###############################################################################
315325
# Check for MKL

0 commit comments

Comments
 (0)