[lldb-dev] Trouble running Python tests on Windows
Alexandre Ganea via lldb-dev
lldb-dev at lists.llvm.org
Sat Jun 1 13:49:13 PDT 2019
Indeed, SWIG 4.0.0 does not work with LLDB, SWIG 3.0.12 is required.
I got into another issue, because of running on a French locale (fr-CA), the tests were throwing this:
UnicodeDecodeError: 'utf-8' codec can't decode byte 0xe9 in position 23: invalid continuation byte
0xe9 is an accentuated ‘e’ on a Windows-1252 encoding. The error above was due to:
output = output + this_output.decode("utf-8") # in lldb/trunk/packages/Python/lldbsuite/test/lldbtest.py
I had to change the default locale to ‘en_US’ using: https://java.com/en/download/help/locale.xml
However just FYI, there are still 3 tests failing. I am running a clean checkout on r362268. Assertions are enabled.
F:\svn>ninja check-lldb -C buildninja
ninja: Entering directory `buildninja'
[0/2422] Building native llvm-tblgen...
ninja: no work to do.
[1/807] Building native clang-tblgen...
ninja: no work to do.
[3/38] Generating VCSVersion.inc
-- Found Subversion: C:/Program Files/TortoiseSVN/bin/svn.exe (found version "1.11.1")
[4/8] Python script sym-linking LLDB Python API
Making symlink from ..\..\..\bin\liblldb.dll to f:\svn\buildninja\.\lib\site-packages\lldb\_lldb.pyd
Making symlink from ..\..\..\bin\lldb-argdumper.exe to f:\svn\buildninja\.\lib\site-packages\lldb\lldb-argdumper.exe
[7/8] Running lldb lit test suite
llvm-lit.py: F:/svn/llvm\utils\lit\lit\llvm\config.py:340: note: using clang: f:\svn\buildninja\bin\clang.exe
llvm-lit.py: F:/svn/llvm\utils\lit\lit\llvm\config.py:340: note: using ld.lld: f:\svn\buildninja\bin\ld.lld.exe
llvm-lit.py: F:/svn/llvm\utils\lit\lit\llvm\config.py:340: note: using lld-link: f:\svn\buildninja\bin\lld-link.exe
llvm-lit.py: F:/svn/llvm\utils\lit\lit\llvm\config.py:340: note: using ld64.lld: f:\svn\buildninja\bin\ld64.lld.exe
llvm-lit.py: F:/svn/llvm\utils\lit\lit\llvm\config.py:340: note: using wasm-ld: f:\svn\buildninja\bin\wasm-ld.exe
-- Testing: 1669 tests, 12 threads --
Testing: 0 .. 10.. 20..
UNRESOLVED: lldb-Suite :: functionalities/platform/TestPlatformCommand.py (520 of 1669)
******************** TEST 'lldb-Suite :: functionalities/platform/TestPlatformCommand.py' FAILED ********************
Unable to find 'RESULT: PASSED' in dotest output:
lldb version 9.0.0 (https://aganea@llvm.org/svn/llvm-project/lldb/trunk revision 362282)
clang revision 362282
llvm revision 362282
A s s e r t i o n f a i l e d : ! K e y I n f o T : : i s E q u a l ( V a l , E m p t y K e y ) & & ! K e y I n f o T : : i s E q u a l ( V a l , T o m b t o n e K e y ) & & " E m p t y / T o m b s t o n e v a l u e s h o u l d n ' t b e i n s e r t e d i n t o m a p ! " , f i l e F : \ s v n \ l l m \ i n c l u d e \ l l v m / A D T / D e n s e M a p . h , l i n e 6 2 0
********************
Testing: 0 .. 10.. 20.. 30.. 40.. 50.. 60.. 70.. 80..
FAIL: lldb-Unit :: Utility/./UtilityTests.exe/StatusTest.ErrorWin32 (1477 of 1669)
******************** TEST 'lldb-Unit :: Utility/./UtilityTests.exe/StatusTest.ErrorWin32' FAILED ********************
Note: Google Test filter = StatusTest.ErrorWin32
[==========] Running 1 test from 1 test case.
[----------] Global test environment set-up.
[----------] 1 test from StatusTest
[ RUN ] StatusTest.ErrorWin32
F:\svn\lldb\unittests\Utility\StatusTest.cpp(69): error: Expected: "Access is denied. "
To be equal to: s.AsCString()
Which is: "Acc\xE8s refus\xE9. "
F:\svn\lldb\unittests\Utility\StatusTest.cpp(72): error: Expected: "Negotiation timed out "
To be equal to: s.AsCString()
Which is: "Le d\xE9lai d\x92" "attente a expir\xE9 pour la n\xE9gociation "
[ FAILED ] StatusTest.ErrorWin32 (1 ms)
[----------] 1 test from StatusTest (1 ms total)
[----------] Global test environment tear-down
[==========] 1 test from 1 test case ran. (1 ms total)
[ PASSED ] 0 tests.
[ FAILED ] 1 test, listed below:
[ FAILED ] StatusTest.ErrorWin32
1 FAILED TEST
********************
Testing: 0 .. 10.. 20.. 30.. 40.. 50.. 60.. 70.. 80.. 90..
TIMEOUT: lldb-Suite :: functionalities/thread/thread_specific_break/TestThreadSpecificBreakpoint.py (1669 of 1669)
******************** TEST 'lldb-Suite :: functionalities/thread/thread_specific_break/TestThreadSpecificBreakpoint.py' FAILED ********************
Reached timeout of 600 seconds
********************
Testing Time: 768.43s
********************
Failing Tests (1):
lldb-Unit :: Utility/./UtilityTests.exe/StatusTest.ErrorWin32
********************
Unresolved Tests (1):
lldb-Suite :: functionalities/platform/TestPlatformCommand.py
********************
Timed Out Tests (1):
lldb-Suite :: functionalities/thread/thread_specific_break/TestThreadSpecificBreakpoint.py
Expected Passes : 1610
Expected Failures : 14
Unsupported Tests : 42
Unresolved Tests : 1
Unexpected Failures: 1
Individual Timeouts: 1
FAILED: tools/lldb/lit/CMakeFiles/check-lldb-lit
cmd.exe /C "cd /D F:\svn\buildninja\tools\lldb\lit && C:\Users\aganea\AppData\Local\Programs\Python\Python37\python.exe F:/svn/buildninja/./bin/llvm-lit.py -sv F:/svn/buildninja/tools/lldb/lit"
ninja: build stopped: subcommand failed.
De : Alex Langford <alex.langford at Oculus.com<mailto:alex.langford at Oculus.com>>
Envoyé : May 31, 2019 2:17 PM
À : Alexandre Ganea <alexandre.ganea at ubisoft.com<mailto:alexandre.ganea at ubisoft.com>>
Cc : lldb-commits <lldb-commits-bounces at lists.llvm.org<mailto:lldb-commits-bounces at lists.llvm.org>>
Objet : Re: [lldb-dev] Trouble running Python tests on Windows
Hey Alex,
I would recommend not using SWIG 4.0.0. The last time I tried to use it, I got the exact same error you did. I would recommend SWIG 3.0.12, since that is the latest version of SWIG that I’ve been able to get working. Good luck!
Alex
From: lldb-dev <lldb-dev-bounces at lists.llvm.org<mailto:lldb-dev-bounces at lists.llvm.org>> on behalf of Alexandre Ganea via lldb-dev <lldb-dev at lists.llvm.org<mailto:lldb-dev at lists.llvm.org>>
Reply-To: Alexandre Ganea <alexandre.ganea at ubisoft.com<mailto:alexandre.ganea at ubisoft.com>>
Date: Friday, May 31, 2019 at 8:42 AM
To: "lldb-dev at lists.llvm.org<mailto:lldb-dev at lists.llvm.org>" <lldb-dev at lists.llvm.org<mailto:lldb-dev at lists.llvm.org>>
Subject: [lldb-dev] Trouble running Python tests on Windows
Hi,
I can’t seem to run the lldb python tests on my Windows 10 setup. I use the following cmd-line to generate:
cmake -G Ninja f:/svn/llvm -DCMAKE_BUILD_TYPE=Release -DLLVM_OPTIMIZED_TABLEGEN=true -DLLVM_EXTERNAL_LLD_SOURCE_DIR=f:/svn/lld -DLLVM_EXTERNAL_CLANG_SOURCE_DIR=f:/svn/clang -DLLVM_TOOL_LLD_BUILD=true -DLLVM_TOOL_CLANG_BUILD=true -DLLVM_ENABLE_PDB=true -DLLVM_ENABLE_ASSERTIONS=ON -DLLVM_EXTERNAL_LLDB_SOURCE_DIR=f:/svn/lldb -DLLVM_TOOL_LLDB_BUILD=true -DPYTHON_HOME="C:\Users\aganea\AppData\Local\Programs\Python\Python37"
Followed by: ninja check-all, which ends up in a bunch of:
******************** TEST 'lldb-Suite :: tools/lldb-server/TestAppleSimulatorOSType.py' FAILED ********************
Unable to find 'RESULT: PASSED' in dotest output:
lldb version 9.0.0 (https://aganea@llvm.org/svn/llvm-project/lldb/trunk revision 361826)
clang revision 361826
llvm revision 361826
LLDB library dir: F:\svn\buildninja\bin
LLDB import library dir: F:\svn\buildninja\bin\..\lib
Traceback (most recent call last):
File "F:/svn/lldb/test/dotest.py", line 7, in <module>
lldbsuite.test.run_suite()
File "F:\svn\lldb\packages\Python\lldbsuite\test\dotest.py", line 1243, in run_suite
import lldb
File "F:\svn\buildninja\lib\site-packages\lldb\__init__.py", line 1500, in <module>
class SBAddress(object):
File "F:\svn\buildninja\lib\site-packages\lldb\__init__.py", line 1675, in SBAddress
__swig_getmethods__["module"] = GetModule
NameError: name '__swig_getmethods__' is not defined
Swig 4.0.0 is there in %PATH%. I’m using MSVC 19.16.27031.1 for compiling. I’ve tried with Clang 8.0, same issues.
Any idea on what could be missing?
Thanks in advance!
Alex.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/lldb-dev/attachments/20190601/d21e7d61/attachment-0001.html>
More information about the lldb-dev
mailing list