From a799dd04adc08a062ec9961a026573abcc7c9181 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20K=C4=99pie=C5=84?= Date: Tue, 18 Mar 2025 06:19:01 +0100 Subject: [PATCH] Fix PYTHONPATH set for ans.py servers by start.pl Commit 6c010a5644324947c8c13b5600cd8d988ae7684f caused the PYTHONPATH environment variable to be set for ans.py servers started using start.pl. However, no system test has actually used the new isctest.asyncserver module since that change was applied, so it has not been noticed until now that including the source directory in PYTHONPATH is only sufficient for in-tree builds. Include the build directory instead of the source directory in the PYTHONPATH environment variable set for ans.py servers started by start.pl so that they work correctly for both in-tree and out-of-tree builds. --- bin/tests/system/start.pl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/tests/system/start.pl b/bin/tests/system/start.pl index 20e8bdc82b..35a7efe690 100755 --- a/bin/tests/system/start.pl +++ b/bin/tests/system/start.pl @@ -324,7 +324,7 @@ sub construct_ans_command { } if (-e "$testdir/$server/ans.py") { - $ENV{'PYTHONPATH'} = $testdir . ":" . $ENV{'srcdir'}; + $ENV{'PYTHONPATH'} = $testdir . ":" . $builddir; $command = "$PYTHON -u ans.py 10.53.0.$n $queryport"; } elsif (-e "$testdir/$server/ans.pl") { $command = "$PERL ans.pl";