[Lldb-commits] [PATCH] D76314: [lldb-vscode] stop read loop after termination

Pavel Labath via Phabricator via lldb-commits lldb-commits at lists.llvm.org
Thu Mar 19 01:03:37 PDT 2020


labath added inline comments.


================
Comment at: lldb/test/API/tools/lldb-vscode/launch/TestVSCode_launch.py:50-53
+        time.sleep(1)
+        # lldb-vscode process must have already finished even though
+        # we didn't close the communication socket explicitly
+        self.assertEqual(self.vscode.process.poll(), 0)
----------------
1 second is pretty short, and I wouldn't be surprised if it causes spurious failures.

Using `popen.wait()` would be _much_ better -- you can use a much larger timeout, while still having the test terminate quickly in the common case.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D76314/new/

https://reviews.llvm.org/D76314





More information about the lldb-commits mailing list