diff --git a/src/etc/lldb_batchmode.py b/src/etc/lldb_batchmode.py index 6b4c44806740f..537b419b3279f 100644 --- a/src/etc/lldb_batchmode.py +++ b/src/etc/lldb_batchmode.py @@ -18,10 +18,15 @@ import os import sys import threading -import thread import re import time +try: + import thread +except ModuleNotFoundError: + # The `thread` module was renamed to `_thread` in Python 3. + import _thread as thread + # Set this to True for additional output DEBUG_OUTPUT = False