[Lldb-commits] [lldb] [lldb][test] Check cryptography.x509 in the strict test requirements (PR #229409)

via lldb-commits lldb-commits at lists.llvm.org
Tue Oct 6 05:50:02 PDT 2026


llvmorg-github-actions[bot] wrote:


<!--LLVM PR SUMMARY COMMENT-->

@llvm/pr-subscribers-lldb

Author: Charles Zablit (charles-zablit)

<details>
<summary>Changes</summary>

`lldb_find_python_module(cryptography)` only runs `import cryptography`, which does not load the native `cryptography.hazmat.bindings._rust`. An install without cffi (`pip install --no-deps cryptography`) passed the check, then every `from cryptography import x509` in `TestSymStore.py` failed with `"ModuleNotFoundError: No module named '_cffi_backend'"`.

This patch imports `cryptography.x509` instead so such an install fails at configure time.

This was uncovered in swiftlang testing.


---
Full diff: https://github.com/llvm/llvm-project/pull/229409.diff


1 Files Affected:

- (modified) lldb/test/CMakeLists.txt (+1-1) 


``````````diff
diff --git a/lldb/test/CMakeLists.txt b/lldb/test/CMakeLists.txt
index 59e3c31793372..288723d0099a4 100644
--- a/lldb/test/CMakeLists.txt
+++ b/lldb/test/CMakeLists.txt
@@ -12,7 +12,7 @@ endif()
 if(LLDB_ENFORCE_STRICT_TEST_REQUIREMENTS)
   message(STATUS "Enforcing strict test requirements for LLDB")
   # Lit uses psutil to do per-test timeouts.
-  set(useful_python_modules psutil packaging cryptography)
+  set(useful_python_modules psutil packaging cryptography.x509)
 
   if(NOT WIN32)
     # We no longer vendor pexpect and it is not used on Windows.

``````````

</details>


https://github.com/llvm/llvm-project/pull/229409


More information about the lldb-commits mailing list