From 24ee1d13f628c90e445f62d64968798110244aeb Mon Sep 17 00:00:00 2001 From: Nikita Shulga Date: Tue, 14 Dec 2021 14:45:47 -0800 Subject: [PATCH] Another attempt to fix version comparison check (#69939) Summary: Fixes #{issue number} Pull Request resolved: https://github.com/pytorch/pytorch/pull/69939 Reviewed By: atalman Differential Revision: D33108135 Pulled By: malfet fbshipit-source-id: cadadfe5b04c4378f149136f8e1f8e8d6266775c --- test/run_test.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/run_test.py b/test/run_test.py index 965a55bf94e..eb39fa8ae59 100644 --- a/test/run_test.py +++ b/test/run_test.py @@ -913,7 +913,7 @@ def get_selected_tests(options): # This is exception thats caused by this issue https://github.com/pytorch/pytorch/issues/69460 # This below code should be removed once this issue is solved - if LooseVersion(torch.version.cuda) >= LooseVersion("11.5"): + if torch.version.cuda is not None and LooseVersion(torch.version.cuda) >= "11.5": WINDOWS_BLOCKLIST.append("test_cpp_extensions_aot") WINDOWS_BLOCKLIST.append("test_cpp_extensions_aot_ninja") WINDOWS_BLOCKLIST.append("test_cpp_extensions_aot_no_ninja")