* Fix debugger stepping actions in forked process
Fix the debugger stepping state when debugging a process that has been
forked from the main process. The new sys.monitoring mechanism didn't
fully clear the thread local storage after a fork leading to a state
where the forked child process tracked the wrong thread information and
was never updated on the latest continue action.
* Add stepping test for forked process
* Add line ending back in for cleaner diff
* More formatting reversions
* Add parent-session-pid argument
Add the ability to specify the parent process id when connecting a new
DAP server to the client. This value is used instead of the actual
process' parent id so that it can be associated with a specific debug
session even if it hasn't been spawned directly by that parent process.
* Add tests for new option
* Before this change it was not possible to attach to a process on arm64 mac.
The primary issue was that we weren't building the attach.dylib for all targets; but even once we did that we had to ensure that we were exiting successfully after injecting into the process.
We pulled in the compile changes from 2e7109f6fe
Co-authored-by: @artemmukhin <Artem.Mukhin@jetbrains.com>
Co-authored-by: Cole Miller <cole@zed.dev>
* Use g++ on macOS (with -D_FORTIFY_SOURCE=2)
---------
Co-authored-by: @artemmukhin <Artem.Mukhin@jetbrains.com>
Co-authored-by: Cole Miller <cole@zed.dev>
* 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`
* Support using scope during setVariable request
* Fix other overloads to accept scope too
* Use 3.9 compatible unions
* Review feedback
* Pydevd test wasn't actually validating
* Allow relative paths and add more logging for path issues
* Revert "Allow relative paths and add more logging for path issues"
This reverts commit a3956e4753.
* Allow relative paths and add more logging for path issues
* Add case test
* Missed some spots
* Invalid variable name
* Func doesn't return tuple
* Fix multithreaded stepping to not have 'return' events when a thread is already suspended
* Update after removing blank line
* Remove unnecessary change for start method
* Add more logging for 313 failure
* Auto retry failures
* Add retry for socket.write
* Put watchdog timeout back and drop errors
* Fix linter
* Add message on error so at least it's logged
* Try a different combination
* Fix linter
* Go back to longer watchdog
* Try a different tactic
* Don't log failure and wait a bit in the watchdog
* Go back to the NoMoreMessages
* Just disable watchdog in 3.13 for now
* Change watchdog timeout
* Try different algorithm for ports in use
* Add retries option
* Fix usages of get_test_server_port
* Retries don't seem to work at global level with xdist, use retries on individual tests