Skip to content

Commit

Permalink
wsl: fix hard code path
Browse files Browse the repository at this point in the history
  • Loading branch information
squirrelsc committed Nov 3, 2023
1 parent b2a3268 commit 6d7de37
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions lisa/tools/wsl.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
# Copyright (c) Microsoft Corporation.
# Licensed under the MIT license.

import os
import re
import time
from pathlib import PurePath
Expand Down Expand Up @@ -312,7 +311,7 @@ def _config(
def _config_kernel(self, kernel: str) -> str:
self._log.debug(f"Detecting kernel from {kernel}")

if not os.path.exists(kernel):
if not self.node.shell.exists(PurePath(kernel)):
raise LisaException(f"Kernel file {kernel} doesn't exist.")

if kernel.endswith(".tar.xz"):
Expand Down

0 comments on commit 6d7de37

Please sign in to comment.