Commit graph

738 commits

Author SHA1 Message Date
Pavel Minaev
7687590f7f Remove unused dependencies and unnecessary version pins. 2019-12-08 14:13:58 -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
b23031b773 Disable "redirectOutput" in tests by default. 2019-12-08 14:13:58 -08:00
Pavel Minaev
c545ccb5f8 Fix and re-enable test_reattach. 2019-12-04 09:32:59 -08:00
Pavel Minaev
7d160fc0f8 Fix and re-enable Django multiproc test. 2019-11-20 16:15:02 -08:00
Pavel Minaev
270afb8095 Fix #1900: Ensure that the ptvsd_attach event sets the right name for child processes 2019-11-19 12:59:54 -08:00
Pavel Minaev
4fb41ca083 Disable attach_to_pid tests on MacOS + Python 2.7 (#1916) 2019-11-19 12:05:57 -08:00
Pavel Minaev
75a7417e87 Disable attach_by_pid(wait=True) tests on Win32 and Mac due to #1926 2019-11-19 12:05:57 -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
36485c02c6 Fix #1884: Use sys.platform over platform.system() 2019-11-19 12:05:57 -08:00
Pavel Minaev
ca8e6a137b Reduce default test matrix to avoid redundant tests. 2019-11-19 12:05:57 -08:00
Pavel Minaev
d5fe978d5e Add ResponseOccurrence.result to alias Response.result 2019-11-18 13:50:14 -08:00
Pavel Minaev
52ebb7ca1f Fix #1886: test_flask_breakpoint_multiproc fails with run=attach_by_socket
Adjust sys.path before running Flask from the stub script.
2019-11-18 13:50:14 -08:00
Pavel Minaev
fb6d35ebea Improve failed test diagnostics. 2019-11-18 13:50:14 -08:00
Pavel Minaev
9b34bc0dac Fix #1918: ptvsd port conflicts in test runs 2019-11-15 11:55:27 -08:00
Pavel Minaev
3fc156ca32 Disable attach-to-PID tests on Travis due to #1915. 2019-11-15 11:55:27 -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
Pavel Minaev
e1d5543819 Fix #1875: Inject ptvsd into subprocesses
Fix #1901: Race between IDE and server connecting to the adapter

Use "evaluate" request without "frameId" to import ptvsd into the debuggee as soon as server attaches.

If the adapter is spawned by the server, wait for server to connect if IDE connects first.

Fix test_subprocess to use the new test API, and add a check for ptvsd being loaded in the child process.
2019-11-12 18:13:25 -08:00
Pavel Minaev
db7b0b64a3 Disable multiproc tests that haven't yet been refactored to use the new debug.Session API. 2019-10-30 17:12:17 -07:00
Pavel Minaev
b862bb3143 Disable attach_by_socket("api") for test_flask due to #1886 2019-10-30 17:12:17 -07:00
Pavel Minaev
c910565b9a Blacken code. 2019-10-30 17:12:17 -07:00
Pavel Minaev
fad3c4f878 Add "from __future__ import division" to all ptvsd modules. 2019-10-30 17:12:17 -07:00
Pavel Minaev
095e5bcd5c Fix #1713: Adapter: multiple concurrent sessions 2019-10-30 17:12:17 -07:00
fabioz
959412a77c Handle binary data when redirecting pydevd output. Fixes #1640 2019-10-23 10:52:25 -03:00
Fabio Zadrozny
cd44e3b514 Support Python 3.8. Fixes #1845 (#1855) 2019-10-17 13:34:42 -07:00
Pavel Minaev
b2111b93ca Switch test output capture to use os.pipe(). Fixes #1819. 2019-10-16 11:44:17 -07:00
Pavel Minaev
b3f0265785 Place pydevd log file in debug.Session log directory, for better handling of multi-session (e.g. multiproc) tests.
Always log to disk for test runs, and dump all ptvsd and pydevd logs on test failures and timeouts.
2019-10-16 11:44:17 -07:00
Fabio Zadrozny
c0108c08b5 Use pid for files created in pydevd logging. Fixes #1831 2019-10-15 08:30:36 -03: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
Karthik Nadig
ffc6306d8b
Updating telemetry and some comments (#1825)
* Change version field name in telemetry
* Add info on where to set justMyCode
* Address comments.
2019-10-03 20:30:05 -07:00
Pavel Minaev
66f37523ed Re-enable test_break_api[code] on Python 2.7. 2019-10-03 18:31:37 -07:00
Pavel Minaev
89be0d1fce Reformat tests. 2019-10-03 18:31:37 -07:00
Pavel Minaev
95dde37734 Refactor test_set_expression. 2019-10-03 18:31:37 -07:00
Pavel Minaev
2935c000f0 Refactor test_evaluate to use simplified APIs where possible, and to test more scenarios. 2019-10-03 18:31:37 -07:00
Pavel Minaev
5f11b7580e Improve reporting of captured multiline debuggee output in tests. 2019-10-03 18:31:37 -07:00
Pavel Minaev
c1486a99b9 Fix log.stderr_levels not respected. 2019-10-03 18:31:37 -07:00
Pavel Minaev
a1ba6f22a5 Fix debug.Session hanging on failed test if debuggee is still alive. 2019-10-03 18:31:37 -07:00
Pavel Minaev
14b0e80f2e Disable test_wait_on_abnormal_exit_enabled due to #1819. 2019-09-30 22:01:27 -07:00
Pavel Minaev
70396bd9fd Disable test_wait_on_normal_exit_enabled due to #1819. 2019-09-30 22:01:27 -07:00
Pavel Minaev
f1f539a7f6 Fix encoding issues in pytest stdio logs. 2019-09-30 22:01:27 -07:00
Pavel Minaev
ca56bf70ba Disable Python stdio buffering when spawning processes in tests. 2019-09-30 22:01:27 -07:00
Pavel Minaev
f60cc99c8f Remove test_client_ide_from_path_mapping_linux_backend, since the corresponding product functionality has been removed. 2019-09-30 22:01:27 -07:00
Pavel Minaev
a2d58ee7c9 Use fully qualified test names for log directories to avoid name clashes. 2019-09-30 04:41:10 -07:00
Pavel Minaev
a6060d4f0c Disable test_client_ide_from_path_mapping_linux_backend due to #1812. 2019-09-30 04:41:10 -07:00
Pavel Minaev
2bf8f582b2 Disable attach_by_pid where applicable (#1810, #1811). 2019-09-30 04:41:10 -07:00
Pavel Minaev
e1557d78c5 Fix test_client_ide_from_path_mapping_linux_backend 2019-09-30 04:41:10 -07:00
Pavel Minaev
1262a265b5 Fix test_client_ide_from_path_mapping_linux_backend. 2019-09-30 04:41:10 -07:00
Pavel Minaev
79ccbb950d Fix encoding issues when writing test logs. 2019-09-30 04:41:10 -07:00
Pavel Minaev
4b9773e89d Also capture full pytest logs with --ptvsd-logs. 2019-09-30 04:41:10 -07:00