MCPcopy Create free account
hub / github.com/microsoft/debugpy / disconnect

Method disconnect

tests/debug/session.py:1004–1020  ·  view source on GitHub ↗
(self, force=False)

Source from the content-addressed store, hash-verified

1002 return self.captured_output.stderr(encoding)
1003
1004 def disconnect(self, force=False):
1005 if self.channel is None:
1006 return
1007
1008 try:
1009 if not force:
1010 self.request("disconnect")
1011 self.wait_for_terminated()
1012 except messaging.JsonIOError:
1013 pass
1014 finally:
1015 try:
1016 self.channel.close()
1017 except Exception:
1018 pass
1019 self.channel.wait()
1020 self.channel = None
1021
1022
1023Session.reset_counter()

Callers 4

__exit__Method · 0.95
test_reattachFunction · 0.45

Calls 4

requestMethod · 0.95
wait_for_terminatedMethod · 0.95
closeMethod · 0.45
waitMethod · 0.45

Tested by 3

test_reattachFunction · 0.36