[Lldb-commits] [lldb] [lldb-dap] Added "port" property to vscode "attach" command. (PR #91570)

via lldb-commits lldb-commits at lists.llvm.org
Thu May 9 01:26:41 PDT 2024


github-actions[bot] wrote:

<!--LLVM CODE FORMAT COMMENT: {darker}-->


:warning: Python code formatter, darker found issues in your code. :warning:

<details>
<summary>
You can test this locally with the following command:
</summary>

``````````bash
darker --check --diff -r 443377a9d1a8d4a69a317a1a892184c59dd0aec6...4774f5803327d766d27c26646927e8ba42368b40 lldb/test/API/tools/lldb-dap/attach/TestDAP_attachByPortNum.py lldb/packages/Python/lldbsuite/test/lldbtest.py lldb/packages/Python/lldbsuite/test/tools/lldb-dap/dap_server.py lldb/packages/Python/lldbsuite/test/tools/lldb-dap/lldbdap_testcase.py
``````````

</details>

<details>
<summary>
View the diff from darker here.
</summary>

``````````diff
--- test/API/tools/lldb-dap/attach/TestDAP_attachByPortNum.py	2024-05-08 19:41:43.000000 +0000
+++ test/API/tools/lldb-dap/attach/TestDAP_attachByPortNum.py	2024-05-09 08:26:12.001286 +0000
@@ -14,26 +14,26 @@
 import tempfile
 import threading
 import time
 import sys
 
+
 class TestDAP_attachByPortNum(lldbdap_testcase.DAPTestCaseBase):
-
     def runTargetProgramOnPort(self, port=None, program=None):
         server_tool = "lldb-server"
         server_path = self.getBuiltinServerTool(server_tool)
         if server_path:
-            server_path +=" g localhost:" +  port + " " 
+            server_path += " g localhost:" + port + " "
 
         self.process = subprocess.Popen(
             [server_path + program],
             shell=True,
             stdin=subprocess.PIPE,
             stdout=subprocess.PIPE,
             stderr=subprocess.PIPE,
         )
-        
+
         return self.process
 
     def set_and_hit_breakpoint(self, continueToExit=True):
         source = "main.c"
         main_source_path = os.path.join(os.getcwd(), source)
@@ -41,11 +41,11 @@
         lines = [breakpoint1_line]
         # Set breakpoint in the thread function so we can step the threads
         breakpoint_ids = self.set_source_breakpoints(main_source_path, lines)
         self.assertEqual(
             len(breakpoint_ids), len(lines), "expect correct number of breakpoints"
-        )        
+        )
         self.continue_to_breakpoints(breakpoint_ids)
         if continueToExit:
             self.continue_to_exit()
 
     @skipIfWindows

``````````

</details>


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


More information about the lldb-commits mailing list