10
10
11
11
12
12
@contextlib .contextmanager
13
- def check_logs (tmpdir , run , pydevd_log ):
13
+ def check_logs (tmpdir , run ):
14
14
# For attach_pid, there's ptvsd.server process that performs the injection,
15
15
# and then there's the debug server that is injected into the debuggee.
16
16
server_count = 2 if type (run ).__name__ == "attach_pid" else 1
17
17
18
18
expected_logs = {
19
19
"debugpy.adapter-*.log" : 1 ,
20
20
"debugpy.launcher-*.log" : 1 if run .request == "launch" else 0 ,
21
- "debugpy.pydevd.*.log" : server_count if pydevd_log else 0 ,
21
+ "debugpy.pydevd.*.log" : server_count ,
22
22
"debugpy.server-*.log" : server_count ,
23
23
}
24
24
@@ -43,7 +43,7 @@ def code_to_debug():
43
43
# Depending on the method, the runner will use either `debugpy --log-dir ...`
44
44
# or `debugpy.log_to() ...`.
45
45
run = run .with_options (log_dir = tmpdir .strpath )
46
- with check_logs (tmpdir , run , pydevd_log = False ):
46
+ with check_logs (tmpdir , run ):
47
47
with debug .Session () as session :
48
48
session .log_dir = None
49
49
@@ -62,7 +62,7 @@ def code_to_debug():
62
62
debuggee .setup ()
63
63
assert backchannel .receive () == "proceed"
64
64
65
- with check_logs (tmpdir , run , pydevd_log = True ):
65
+ with check_logs (tmpdir , run ):
66
66
with debug .Session () as session :
67
67
session .log_dir = None
68
68
session .spawn_adapter .env ["DEBUGPY_LOG_DIR" ] = tmpdir .strpath
0 commit comments