Skip to content

Commit

Permalink
.
Browse files Browse the repository at this point in the history
  • Loading branch information
Pavel Minaev committed Oct 3, 2023
1 parent 94c9999 commit ca33030
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -261,7 +261,13 @@ def get_target_filename(is_target_process_64=None, prefix=None, extension=None):

def run_python_code_windows(pid, python_code, connect_debugger_tracing=False, show_debug_info=0):
assert '\'' not in python_code, 'Having a single quote messes with our command.'
from winappdbg.process import Process

# Suppress winappdbg warning about sql package missing.
import warnings
with warnings.catch_warnings():
warnings.simplefilter("ignore", category=ImportWarning)
from winappdbg.process import Process

if not isinstance(python_code, bytes):
python_code = python_code.encode('utf-8')

Expand Down
1 change: 1 addition & 0 deletions tests/debug/runners.py
Original file line number Diff line number Diff line change
Expand Up @@ -199,6 +199,7 @@ def attach_pid(session, target, cwd=None, wait=True):
config["processId"] = session.debuggee.pid

session.spawn_adapter()
session.expect_server_socket()
with session.request_attach():
yield

Expand Down

0 comments on commit ca33030

Please sign in to comment.