Commit graph

16 commits

Author SHA1 Message Date
Rich Chiodo
e5017d7360
Fix arq quoting to work in runInTerminal (#1981)
Some checks failed
Code scanning - action / CodeQL-Build (push) Has been cancelled
* Fix arq quoting to work in runInTerminal

* Default was backwards

* Fix ruff errors

* Fix failing tests

* Only strip quotes on the exe

* Try fixing gw worker failures

* Skip certain test because of cmd limitations

* Need to skip all 'code' based tests on windows
2025-12-10 10:39:27 -08:00
rabbit
34d5de99a0
IPv6 support (#1896)
* Add initial support for IPv6

* address comments (part 1)

* quick clean up of missed fix suggestion

* Fix misassigned default serving server address in adapter client

* add wrapper method to get host and port from`getsockname`
2025-05-22 13:04:11 -07:00
Rich Chiodo
4d86a42380
Updates from pydevd (#1706)
* Changes from pushing to pydevd

* Update some time outs to get flakey tests to pass

* Fix string failure

* String case backwards. Fixup test in pydevd

* Using callstack for exception check not sufficient

* Too restrictive on pydevd matching

* Try somethign better than just checking 'pydev'

* Retry a flakey test

* Disable flakey tests

* Another flakey test

* Increase timeout for attach

* Try upping timeout

* Up watchdog timeout

* Up some more timeouts

* Try delaying shutdown of test apps

* Don't output extra things that tests don't expect

* Fix output differences in 3.9? Not sure what that's about

* Fixup line differences in 3.9 with extra sleep

* Fix linter errors

* Fix breakpoint bugs
2024-10-21 10:17:39 -07:00
Pavel Minaev
dd5196fbfc Blacken code. 2022-04-13 11:38:41 -07:00
Pavel Minaev
1965b47034 Get rid of fmt() and use idiomatic format() and f"" instead. 2022-04-13 11:38:41 -07:00
Pavel Minaev
e87017e0b3 Remove redundant "from __future__ import ..." 2022-04-13 11:38:41 -07:00
Pavel Minaev
de9ea2cb9c Improve exception logging to make swallowing/reraising explicit in all cases. 2020-02-21 15:55:04 -08:00
Pavel Minaev
55eac82c96 Fix #1811: tests using attach_by_pid fail on Python 2.7
Don't call enable_attach() and wait_for_attach() while under import lock.
2020-01-26 17:14:30 -08:00
Pavel Minaev
8b4c40e922 Rename ptvsd -> debugpy. 2020-01-17 11:57:13 -08:00
Pavel Minaev
a3acba68d5 Tweak test log formatting to match adapter logs, and reset session ID between tests. 2019-12-08 14:13:58 -08:00
Pavel Minaev
bc40fef197 Fix attach_by_pid test runner not properly waiting before running debuggee code. 2019-11-19 12:05:57 -08:00
Pavel Minaev
646981e4af Fix #1810: tests using attach_by_pid fail on Linux and macOS
Add time.sleep() to attach_by_pid spinning loop to give the injected code a better chance to execute.

Read and log injector output to prevent it from blocking on prints.

Improve code injection logging.

Fix race between socket.accept() backchannel listener thread, and debug.Session.close().
2019-11-15 11:55:27 -08:00
Pavel Minaev
173f9b3a48 Fix race condition in backchannel socket cleanup. 2019-11-12 18:13:25 -08:00
Karthik Nadig
c6cee270ca
Reverse the connection direction used by enable attach internals. (#1833)
* Minor cleanup
* Reverse the direction used by enable attach internals.
* Handle occasional Invalid argument
2019-10-08 22:24:27 -07:00
Pavel Minaev
8f358d6e0f Refactor tests.debug to accommodate ptvsd.server spawning the adapter, and remove the need for "custom_client" and "custom_server" start methods.
Fix launcher not propagating debuggee exit code.

Fix attach-by-PID without explicit --log-dir overriding PTVSD_LOG_DIR (and disabling logging).

Improve test logging, with a separate directory for every test.

Various test fixes.
2019-09-26 13:20:26 -07:00
Pavel Minaev
340942aafc Fix #1695: Handle IDE, launcher, debug server, and no-debug disconnect
Fix #1721 "runInTerminal" is broken on non-Windows platforms.

Fix #1722: Output is not captured in "noDebug" with "runInTerminal"

Groundwork for #1713: adapter: multiple concurrent sessions

Move "launch" request parsing and debuggee process spawning, PID reporting and tracking, stdio "output" capture, and exit code reporting into launcher. Launcher now communicates to the adapter via a full-fledged message channel.

Refactor adapter. Add an abstraction for a debug session, and treat IDE, launcher, and debug server as separate components managed by that session.

Improve adapter logging to capture information about current debug session, and current message handler if any.

Fix reporting exceptions from message handlers.

Various test fixes.
2019-09-10 15:12:23 -07:00