[Lldb-commits] [lldb] [lldb/test] Register the addressable_bits_scripted_process module with the script interpreter (PR #224803)
Med Ismail Bennani via lldb-commits
lldb-commits at lists.llvm.org
Fri Sep 18 21:51:56 PDT 2026
https://github.com/medismailben created https://github.com/llvm/llvm-project/pull/224803
`test_scripted_process_addressable_bits` imported `addressable_bits_scripted_process` into the test process, which makes the module's constants available to the test but tells lldb's own script interpreter nothing about it, so `SBLaunchInfo::SetScriptedProcessClassName()` had nothing to resolve:
```
error: failed to create ScriptedProcess: failed to create script object:
Could not find script class:
addressable_bits_scripted_process.AddressableBitsScriptedProcess
```
Import the file with `command script import` the way the other scripted process tests in this file do.
>From a7d52315809aa9f9721abe5877e0981c68fa2401 Mon Sep 17 00:00:00 2001
From: Med Ismail Bennani <ismail at bennani.ma>
Date: Fri, 18 Sep 2026 21:44:51 -0700
Subject: [PATCH] [lldb/test] Register the scripted process module with the
script interpreter
`test_scripted_process_addressable_bits` imported
`addressable_bits_scripted_process` into the test process, which makes the
module's constants available to the test but tells lldb's own script
interpreter nothing about it, so
`SBLaunchInfo::SetScriptedProcessClassName()` had nothing to resolve:
error: failed to create ScriptedProcess: failed to create script object:
Could not find script class:
addressable_bits_scripted_process.AddressableBitsScriptedProcess
Import the file with `command script import` the way the other scripted
process tests in this file do.
---
.../functionalities/scripted_process/TestScriptedProcess.py | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/lldb/test/API/functionalities/scripted_process/TestScriptedProcess.py b/lldb/test/API/functionalities/scripted_process/TestScriptedProcess.py
index 33ff43ea8bc5f4..7b6f31f8015595 100644
--- a/lldb/test/API/functionalities/scripted_process/TestScriptedProcess.py
+++ b/lldb/test/API/functionalities/scripted_process/TestScriptedProcess.py
@@ -333,6 +333,11 @@ def test_scripted_process_addressable_bits(self):
target = self.dbg.CreateTarget(self.getBuildArtifact("a.out"))
self.assertTrue(target, VALID_TARGET)
+ self.runCmd(
+ "command script import "
+ + os.path.join(self.getSourceDir(), "addressable_bits_scripted_process.py")
+ )
+
launch_info = lldb.SBLaunchInfo(None)
launch_info.SetProcessPluginName("ScriptedProcess")
launch_info.SetScriptedProcessClassName(
More information about the lldb-commits
mailing list