diff --git a/wexpect/host.py b/wexpect/host.py index d8eea83..e6a79e3 100644 --- a/wexpect/host.py +++ b/wexpect/host.py @@ -357,7 +357,7 @@ class SpawnBase: wexpect_executable = os.environ['WEXPECT_EXECUTABLE'] except KeyError: dirname = os.path.dirname(sys.executable) - wexpect_executable = os.path.join(dirname, '..', 'wexpect', 'wexpect.exe') + wexpect_executable = os.path.abspath(os.path.join(dirname, '..', 'wexpect', 'wexpect.exe')) if not os.path.exists(wexpect_executable): logger.error(f'ExceptionPexpect: Wexpect executable: >>{wexpect_executable}<< not found.')