debugpy 1.8.5__zip → 1.8.7__zip
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {debugpy-1.8.5/src/debugpy.egg-info → debugpy-1.8.7}/PKG-INFO +1 -1
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydev_bundle/_pydev_calltip_util.py +19 -21
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydev_bundle/_pydev_completer.py +30 -30
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydev_bundle/_pydev_execfile.py +3 -1
- debugpy-1.8.7/src/debugpy/_vendored/pydevd/_pydev_bundle/_pydev_filesystem_encoding.py +43 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydev_bundle/_pydev_getopt.py +35 -32
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydev_bundle/_pydev_imports_tipper.py +83 -84
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydev_bundle/_pydev_jy_imports_tipper.py +92 -99
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydev_bundle/_pydev_log.py +2 -3
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydev_bundle/_pydev_saved_modules.py +51 -27
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydev_bundle/_pydev_sys_patch.py +11 -7
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydev_bundle/_pydev_tipper_common.py +6 -5
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydev_bundle/fsnotify/__init__.py +34 -38
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydev_bundle/pydev_console_utils.py +71 -69
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydev_bundle/pydev_import_hook.py +1 -3
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydev_bundle/pydev_imports.py +0 -1
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydev_bundle/pydev_ipython_console.py +14 -16
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydev_bundle/pydev_ipython_console_011.py +81 -93
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydev_bundle/pydev_is_thread_alive.py +3 -3
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydev_bundle/pydev_localhost.py +9 -8
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydev_bundle/pydev_log.py +33 -25
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydev_bundle/pydev_monkey.py +183 -170
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydev_bundle/pydev_monkey_qt.py +33 -29
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydev_bundle/pydev_override.py +6 -4
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydev_bundle/pydev_umd.py +19 -18
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydev_bundle/pydev_versioncheck.py +3 -3
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydev_runfiles/pydev_runfiles.py +165 -138
- debugpy-1.8.7/src/debugpy/_vendored/pydevd/_pydev_runfiles/pydev_runfiles_coverage.py +77 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydev_runfiles/pydev_runfiles_nose.py +35 -36
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydev_runfiles/pydev_runfiles_parallel.py +22 -23
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydev_runfiles/pydev_runfiles_parallel_client.py +37 -57
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydev_runfiles/pydev_runfiles_pytest2.py +54 -52
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydev_runfiles/pydev_runfiles_unittest.py +28 -37
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydev_runfiles/pydev_runfiles_xml_rpc.py +56 -53
- debugpy-1.8.7/src/debugpy/_vendored/pydevd/_pydevd_bundle/_debug_adapter/__main__pydevd_gen_debug_adapter_protocol.py +604 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_bundle/_debug_adapter/debugProtocol.json +551 -445
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_bundle/_debug_adapter/pydevd_base_schema.py +25 -29
- debugpy-1.8.7/src/debugpy/_vendored/pydevd/_pydevd_bundle/_debug_adapter/pydevd_schema.py +17458 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_bundle/_debug_adapter/pydevd_schema_log.py +11 -12
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_bundle/pydevconsole_code.py +18 -19
- debugpy-1.8.7/src/debugpy/_vendored/pydevd/_pydevd_bundle/pydevd_additional_thread_info.py +41 -0
- debugpy-1.8.7/src/debugpy/_vendored/pydevd/_pydevd_bundle/pydevd_additional_thread_info_regular.py +328 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_bundle/pydevd_api.py +263 -214
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_bundle/pydevd_breakpoints.py +7 -10
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_bundle/pydevd_bytecode_utils.py +187 -92
- debugpy-1.8.7/src/debugpy/_vendored/pydevd/_pydevd_bundle/pydevd_bytecode_utils_py311.py +105 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_bundle/pydevd_code_to_source.py +46 -51
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_bundle/pydevd_collect_bytecode_info.py +239 -176
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_bundle/pydevd_comm.py +370 -297
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_bundle/pydevd_comm_constants.py +78 -86
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_bundle/pydevd_command_line_handling.py +55 -59
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_bundle/pydevd_concurrency_analyser/pydevd_concurrency_logger.py +194 -58
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_bundle/pydevd_concurrency_analyser/pydevd_thread_wrappers.py +2 -3
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_bundle/pydevd_console.py +18 -23
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_bundle/pydevd_constants.py +159 -127
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_bundle/pydevd_custom_frames.py +10 -12
- debugpy-1.8.7/src/debugpy/_vendored/pydevd/_pydevd_bundle/pydevd_cython.c +55527 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_bundle/pydevd_cython.pxd +15 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_bundle/pydevd_cython.pyx +803 -511
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_bundle/pydevd_cython_wrapper.py +18 -7
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_bundle/pydevd_daemon_thread.py +32 -24
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_bundle/pydevd_defaults.py +11 -13
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_bundle/pydevd_dont_trace.py +16 -16
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_bundle/pydevd_dont_trace_files.py +27 -2
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_bundle/pydevd_exec2.py +1 -1
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_bundle/pydevd_extension_api.py +4 -5
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_bundle/pydevd_extension_utils.py +8 -10
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_bundle/pydevd_filtering.py +50 -45
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_bundle/pydevd_frame.py +462 -407
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_bundle/pydevd_frame_utils.py +69 -61
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_bundle/pydevd_gevent_integration.py +14 -16
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_bundle/pydevd_import_class.py +27 -25
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_bundle/pydevd_io.py +40 -42
- debugpy-1.8.7/src/debugpy/_vendored/pydevd/_pydevd_bundle/pydevd_json_debug_options.py +200 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_bundle/pydevd_net_command.py +20 -19
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_bundle/pydevd_net_command_factory_json.py +199 -108
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_bundle/pydevd_net_command_factory_xml.py +121 -73
- debugpy-1.8.7/src/debugpy/_vendored/pydevd/_pydevd_bundle/pydevd_plugin_utils.py +208 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_bundle/pydevd_process_net_command.py +206 -159
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_bundle/pydevd_process_net_command_json.py +346 -334
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_bundle/pydevd_referrers.py +75 -80
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_bundle/pydevd_reload.py +35 -35
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_bundle/pydevd_resolver.py +116 -124
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_bundle/pydevd_runpy.py +44 -58
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_bundle/pydevd_safe_repr.py +51 -55
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_bundle/pydevd_save_locals.py +4 -2
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_bundle/pydevd_signature.py +24 -24
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_bundle/pydevd_source_mapping.py +19 -20
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_bundle/pydevd_stackless.py +45 -49
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_bundle/pydevd_suspended_frames.py +61 -58
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_bundle/pydevd_thread_lifecycle.py +23 -13
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_bundle/pydevd_timeout.py +29 -31
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_bundle/pydevd_trace_dispatch.py +41 -11
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_bundle/pydevd_trace_dispatch_regular.py +117 -55
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_bundle/pydevd_traceproperty.py +11 -14
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_bundle/pydevd_utils.py +90 -89
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_bundle/pydevd_vars.py +106 -97
- debugpy-1.8.7/src/debugpy/_vendored/pydevd/_pydevd_bundle/pydevd_vm_type.py +40 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_bundle/pydevd_xml.py +56 -46
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_frame_eval/pydevd_frame_eval_cython_wrapper.py +5 -5
- debugpy-1.8.7/src/debugpy/_vendored/pydevd/_pydevd_frame_eval/pydevd_frame_eval_main.py +71 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_frame_eval/pydevd_frame_evaluator.c +11165 -5326
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_frame_eval/pydevd_frame_tracing.py +5 -6
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_frame_eval/pydevd_modify_bytecode.py +53 -56
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_frame_eval/vendored/bytecode/__init__.py +1 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_frame_eval/vendored/bytecode/bytecode.py +4 -6
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_frame_eval/vendored/bytecode/cfg.py +6 -26
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_frame_eval/vendored/bytecode/concrete.py +7 -21
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_frame_eval/vendored/bytecode/flags.py +5 -24
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_frame_eval/vendored/bytecode/instr.py +10 -34
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_frame_eval/vendored/bytecode/peephole_opt.py +1 -4
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_frame_eval/vendored/bytecode/tests/__init__.py +2 -6
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_frame_eval/vendored/bytecode/tests/test_bytecode.py +3 -5
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_frame_eval/vendored/bytecode/tests/test_cfg.py +11 -31
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_frame_eval/vendored/bytecode/tests/test_code.py +2 -2
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_frame_eval/vendored/bytecode/tests/test_concrete.py +14 -41
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_frame_eval/vendored/bytecode/tests/test_flags.py +2 -4
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_frame_eval/vendored/bytecode/tests/test_instr.py +7 -18
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_frame_eval/vendored/bytecode/tests/test_misc.py +6 -18
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_frame_eval/vendored/bytecode/tests/test_peephole_opt.py +7 -18
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_frame_eval/vendored/bytecode/tests/util_annotation.py +1 -3
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_frame_eval/vendored/pydevd_fix_code.py +14 -19
- debugpy-1.8.7/src/debugpy/_vendored/pydevd/_pydevd_sys_monitoring/_pydevd_sys_monitoring.py +1929 -0
- debugpy-1.8.7/src/debugpy/_vendored/pydevd/_pydevd_sys_monitoring/_pydevd_sys_monitoring_cython.c +43253 -0
- debugpy-1.8.7/src/debugpy/_vendored/pydevd/_pydevd_sys_monitoring/_pydevd_sys_monitoring_cython.pxd +46 -0
- debugpy-1.8.7/src/debugpy/_vendored/pydevd/_pydevd_sys_monitoring/_pydevd_sys_monitoring_cython.pyx +1935 -0
- debugpy-1.8.7/src/debugpy/_vendored/pydevd/_pydevd_sys_monitoring/pydevd_sys_monitoring.py +16 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydev_app_engine_debug_startup.py +12 -11
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydev_coverage.py +30 -32
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydev_ipython/inputhook.py +58 -54
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydev_ipython/inputhookglut.py +20 -24
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydev_ipython/inputhookgtk.py +8 -7
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydev_ipython/inputhookgtk3.py +8 -6
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydev_ipython/inputhookpyglet.py +11 -8
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydev_ipython/inputhookqt4.py +21 -18
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydev_ipython/inputhookqt5.py +17 -15
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydev_ipython/inputhookqt6.py +17 -15
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydev_ipython/inputhooktk.py +6 -4
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydev_ipython/inputhookwx.py +14 -10
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydev_ipython/matplotlibtools.py +30 -26
- debugpy-1.8.7/src/debugpy/_vendored/pydevd/pydev_ipython/qt.py +24 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydev_ipython/qt_for_kernel.py +37 -34
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydev_ipython/qt_loaders.py +86 -73
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydev_ipython/version.py +7 -7
- debugpy-1.8.7/src/debugpy/_vendored/pydevd/pydev_pysrc.py +1 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydev_run_in_console.py +23 -24
- debugpy-1.8.7/src/debugpy/_vendored/pydevd/pydev_sitecustomize/sitecustomize.py +267 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydevconsole.py +55 -47
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydevd.py +732 -508
- debugpy-1.8.7/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/_always_live_program.py +40 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/_check.py +1 -0
- debugpy-1.8.7/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/_test_attach_to_process.py +11 -0
- debugpy-1.8.7/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/_test_attach_to_process_linux.py +75 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/add_code_to_python_process.py +130 -125
- debugpy-1.8.7/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/attach_amd64.dll +0 -0
- debugpy-1.8.7/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/attach_amd64.pdb +0 -0
- debugpy-1.8.7/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/attach_pydevd.py +89 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/attach_script.py +41 -32
- debugpy-1.8.7/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/attach_x86.dll +0 -0
- debugpy-1.8.7/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/attach_x86.pdb +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/common/py_utils.hpp +1 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/common/py_version.hpp +9 -1
- debugpy-1.8.7/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/inject_dll_amd64.exe +0 -0
- debugpy-1.8.7/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/inject_dll_amd64.pdb +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/inject_dll_x86.exe +0 -0
- debugpy-1.8.7/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/inject_dll_x86.pdb +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/linux_and_mac/lldb_prepare.py +10 -9
- debugpy-1.8.7/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/run_code_on_dllmain_amd64.dll +0 -0
- debugpy-1.8.7/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/run_code_on_dllmain_amd64.pdb +0 -0
- debugpy-1.8.7/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/run_code_on_dllmain_x86.dll +0 -0
- debugpy-1.8.7/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/run_code_on_dllmain_x86.pdb +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/winappdbg/__init__.py +103 -119
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/winappdbg/breakpoint.py +457 -516
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/winappdbg/compat.py +33 -15
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/winappdbg/crash.py +336 -281
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/winappdbg/debug.py +101 -131
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/winappdbg/disasm.py +148 -153
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/winappdbg/event.py +310 -302
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/winappdbg/interactive.py +235 -208
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/winappdbg/module.py +185 -218
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/winappdbg/process.py +428 -564
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/winappdbg/registry.py +54 -53
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/winappdbg/search.py +69 -73
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/winappdbg/sql.py +158 -170
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/winappdbg/system.py +143 -213
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/winappdbg/textio.py +302 -333
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/winappdbg/thread.py +220 -239
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/winappdbg/util.py +198 -177
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/winappdbg/win32/__init__.py +11 -11
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/winappdbg/win32/advapi32.py +1191 -713
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/winappdbg/win32/context_amd64.py +248 -194
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/winappdbg/win32/context_i386.py +132 -120
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/winappdbg/win32/dbghelp.py +450 -346
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/winappdbg/win32/defines.py +305 -286
- debugpy-1.8.7/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/winappdbg/win32/gdi32.py +526 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/winappdbg/win32/kernel32.py +1479 -1097
- debugpy-1.8.7/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/winappdbg/win32/ntdll.py +579 -0
- debugpy-1.8.7/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/winappdbg/win32/peb_teb.py +3517 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/winappdbg/win32/psapi.py +54 -31
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/winappdbg/win32/shell32.py +170 -149
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/winappdbg/win32/shlwapi.py +190 -108
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/winappdbg/win32/user32.py +542 -437
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/winappdbg/win32/version.py +489 -442
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/winappdbg/win32/wtsapi32.py +83 -65
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/winappdbg/window.py +70 -76
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/windows/attach.cpp +17 -9
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/windows/compile_windows.bat +1 -1
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydevd_file_utils.py +141 -120
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydevd_plugins/__init__.py +1 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydevd_plugins/django_debug.py +175 -149
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydevd_plugins/extensions/__init__.py +1 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydevd_plugins/extensions/types/__init__.py +1 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydevd_plugins/extensions/types/pydevd_helpers.py +5 -5
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydevd_plugins/extensions/types/pydevd_plugin_numpy_types.py +28 -28
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydevd_plugins/extensions/types/pydevd_plugin_pandas_types.py +22 -30
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydevd_plugins/extensions/types/pydevd_plugins_django_form_str.py +3 -2
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydevd_plugins/jinja2_debug.py +130 -108
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydevd_plugins/pydevd_line_validation.py +27 -14
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydevd_tracing.py +85 -66
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/setup_pydevd_cython.py +96 -59
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_version.py +3 -3
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/common/messaging.py +2 -1
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/server/cli.py +32 -17
- {debugpy-1.8.5 → debugpy-1.8.7/src/debugpy.egg-info}/PKG-INFO +1 -1
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy.egg-info/SOURCES.txt +6 -1
- debugpy-1.8.5/src/debugpy/_vendored/pydevd/_pydev_bundle/_pydev_filesystem_encoding.py +0 -41
- debugpy-1.8.5/src/debugpy/_vendored/pydevd/_pydev_runfiles/pydev_runfiles_coverage.py +0 -76
- debugpy-1.8.5/src/debugpy/_vendored/pydevd/_pydevd_bundle/_debug_adapter/__main__pydevd_gen_debug_adapter_protocol.py +0 -592
- debugpy-1.8.5/src/debugpy/_vendored/pydevd/_pydevd_bundle/_debug_adapter/pydevd_schema.py +0 -19514
- debugpy-1.8.5/src/debugpy/_vendored/pydevd/_pydevd_bundle/pydevd_additional_thread_info.py +0 -19
- debugpy-1.8.5/src/debugpy/_vendored/pydevd/_pydevd_bundle/pydevd_additional_thread_info_regular.py +0 -153
- debugpy-1.8.5/src/debugpy/_vendored/pydevd/_pydevd_bundle/pydevd_cython.c +0 -43377
- debugpy-1.8.5/src/debugpy/_vendored/pydevd/_pydevd_bundle/pydevd_json_debug_options.py +0 -204
- debugpy-1.8.5/src/debugpy/_vendored/pydevd/_pydevd_bundle/pydevd_plugin_utils.py +0 -91
- debugpy-1.8.5/src/debugpy/_vendored/pydevd/_pydevd_bundle/pydevd_trace_api.py +0 -62
- debugpy-1.8.5/src/debugpy/_vendored/pydevd/_pydevd_bundle/pydevd_vm_type.py +0 -41
- debugpy-1.8.5/src/debugpy/_vendored/pydevd/_pydevd_frame_eval/pydevd_frame_eval_main.py +0 -48
- debugpy-1.8.5/src/debugpy/_vendored/pydevd/pydev_ipython/qt.py +0 -23
- debugpy-1.8.5/src/debugpy/_vendored/pydevd/pydev_pysrc.py +0 -1
- debugpy-1.8.5/src/debugpy/_vendored/pydevd/pydev_sitecustomize/sitecustomize.py +0 -237
- debugpy-1.8.5/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/_always_live_program.py +0 -32
- debugpy-1.8.5/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/_test_attach_to_process.py +0 -9
- debugpy-1.8.5/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/_test_attach_to_process_linux.py +0 -74
- debugpy-1.8.5/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/attach_amd64.dll +0 -0
- debugpy-1.8.5/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/attach_amd64.pdb +0 -0
- debugpy-1.8.5/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/attach_pydevd.py +0 -79
- debugpy-1.8.5/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/attach_x86.dll +0 -0
- debugpy-1.8.5/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/attach_x86.pdb +0 -0
- debugpy-1.8.5/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/inject_dll_amd64.exe +0 -0
- debugpy-1.8.5/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/inject_dll_amd64.pdb +0 -0
- debugpy-1.8.5/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/inject_dll_x86.pdb +0 -0
- debugpy-1.8.5/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/run_code_on_dllmain_amd64.dll +0 -0
- debugpy-1.8.5/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/run_code_on_dllmain_amd64.pdb +0 -0
- debugpy-1.8.5/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/run_code_on_dllmain_x86.dll +0 -0
- debugpy-1.8.5/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/run_code_on_dllmain_x86.pdb +0 -0
- debugpy-1.8.5/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/winappdbg/win32/gdi32.py +0 -507
- debugpy-1.8.5/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/winappdbg/win32/ntdll.py +0 -539
- debugpy-1.8.5/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/winappdbg/win32/peb_teb.py +0 -3435
- {debugpy-1.8.5 → debugpy-1.8.7}/DESCRIPTION.md +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/LICENSE +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/MANIFEST.in +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/README.md +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/pyproject.toml +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/setup.cfg +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/setup.py +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/ThirdPartyNotices.txt +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/__init__.py +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/__main__.py +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/__init__.py +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/_pydevd_packaging.py +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/_util.py +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/force_pydevd.py +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydev_bundle/__init__.py +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydev_runfiles/__init__.py +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_bundle/__init__.py +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_bundle/_debug_adapter/__init__.py +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_bundle/_debug_adapter/debugProtocolCustom.json +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_bundle/pydevd_concurrency_analyser/__init__.py +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_frame_eval/.gitignore +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_frame_eval/__init__.py +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_frame_eval/pydevd_frame_evaluator.pxd +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_frame_eval/pydevd_frame_evaluator.pyx +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_frame_eval/pydevd_frame_evaluator.template.pyx +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_frame_eval/release_mem.h +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_frame_eval/vendored/README.txt +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/_pydevd_frame_eval/vendored/__init__.py +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydev_ipython/README +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydev_ipython/__init__.py +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydev_sitecustomize/__not_in_default_pythonpath.txt +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/README.txt +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/common/py_custom_pyeval_settrace.hpp +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/common/py_custom_pyeval_settrace_310.hpp +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/common/py_custom_pyeval_settrace_311.hpp +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/common/py_custom_pyeval_settrace_common.hpp +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/common/py_settrace.hpp +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/common/python.h +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/common/ref_utils.hpp +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/linux_and_mac/.gitignore +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/linux_and_mac/attach.cpp +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/linux_and_mac/compile_linux.sh +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/linux_and_mac/compile_mac.sh +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/linux_and_mac/compile_manylinux.cmd +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/windows/attach.h +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/windows/inject_dll.cpp +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/windows/py_win_helpers.hpp +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/windows/run_code_in_memory.hpp +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/windows/run_code_on_dllmain.cpp +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/windows/stdafx.cpp +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/windows/stdafx.h +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydevd_attach_to_process/windows/targetver.h +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/_vendored/pydevd/pydevd_plugins/extensions/README.md +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/adapter/__init__.py +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/adapter/__main__.py +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/adapter/clients.py +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/adapter/components.py +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/adapter/launchers.py +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/adapter/servers.py +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/adapter/sessions.py +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/common/__init__.py +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/common/json.py +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/common/log.py +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/common/singleton.py +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/common/sockets.py +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/common/stacks.py +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/common/timestamp.py +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/common/util.py +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/launcher/__init__.py +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/launcher/__main__.py +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/launcher/debuggee.py +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/launcher/handlers.py +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/launcher/output.py +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/launcher/winapi.py +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/public_api.py +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/server/__init__.py +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/server/api.py +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy/server/attach_pid_injected.py +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy.egg-info/dependency_links.txt +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy.egg-info/entry_points.txt +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/src/debugpy.egg-info/top_level.txt +0 -0
- {debugpy-1.8.5 → debugpy-1.8.7}/versioneer.py +0 -0
|
@@ -3,8 +3,16 @@ import os
|
|
|
3
3
|
import re
|
|
4
4
|
import sys
|
|
5
5
|
from _pydev_bundle._pydev_saved_modules import threading
|
|
6
|
-
from _pydevd_bundle.pydevd_constants import
|
|
7
|
-
|
|
6
|
+
from _pydevd_bundle.pydevd_constants import (
|
|
7
|
+
get_global_debugger,
|
|
8
|
+
IS_WINDOWS,
|
|
9
|
+
IS_JYTHON,
|
|
10
|
+
get_current_thread_id,
|
|
11
|
+
sorted_dict_repr,
|
|
12
|
+
set_global_debugger,
|
|
13
|
+
DebugInfoHolder,
|
|
14
|
+
PYDEVD_USE_SYS_MONITORING,
|
|
15
|
+
)
|
|
8
16
|
from _pydev_bundle import pydev_log
|
|
9
17
|
from contextlib import contextmanager
|
|
10
18
|
from _pydevd_bundle import pydevd_constants, pydevd_defaults
|
|
@@ -16,9 +24,9 @@ try:
|
|
|
16
24
|
except ImportError:
|
|
17
25
|
Path = None
|
|
18
26
|
|
|
19
|
-
|
|
27
|
+
# ===============================================================================
|
|
20
28
|
# Things that are dependent on having the pydevd debugger
|
|
21
|
-
|
|
29
|
+
# ===============================================================================
|
|
22
30
|
|
|
23
31
|
pydev_src_dir = os.path.dirname(os.path.dirname(__file__))
|
|
24
32
|
|
|
@@ -35,7 +43,7 @@ def skip_subprocess_arg_patch():
|
|
|
35
43
|
|
|
36
44
|
|
|
37
45
|
def _get_apply_arg_patching():
|
|
38
|
-
return getattr(_arg_patch,
|
|
46
|
+
return getattr(_arg_patch, "apply_arg_patching", True)
|
|
39
47
|
|
|
40
48
|
|
|
41
49
|
def _get_setup_updated_with_protocol_and_ppid(setup, is_exec=False):
|
|
@@ -67,32 +75,31 @@ def _get_setup_updated_with_protocol_and_ppid(setup, is_exec=False):
|
|
|
67
75
|
setup[pydevd_constants.ARGUMENT_HTTP_PROTOCOL] = True
|
|
68
76
|
|
|
69
77
|
else:
|
|
70
|
-
pydev_log.debug(
|
|
78
|
+
pydev_log.debug("Unexpected protocol: %s", protocol)
|
|
71
79
|
|
|
72
80
|
mode = pydevd_defaults.PydevdCustomization.DEBUG_MODE
|
|
73
81
|
if mode:
|
|
74
|
-
setup[
|
|
82
|
+
setup["debug-mode"] = mode
|
|
75
83
|
|
|
76
84
|
preimport = pydevd_defaults.PydevdCustomization.PREIMPORT
|
|
77
85
|
if preimport:
|
|
78
|
-
setup[
|
|
86
|
+
setup["preimport"] = preimport
|
|
79
87
|
|
|
80
88
|
if DebugInfoHolder.PYDEVD_DEBUG_FILE:
|
|
81
|
-
setup[
|
|
89
|
+
setup["log-file"] = DebugInfoHolder.PYDEVD_DEBUG_FILE
|
|
82
90
|
|
|
83
91
|
if DebugInfoHolder.DEBUG_TRACE_LEVEL:
|
|
84
|
-
setup[
|
|
92
|
+
setup["log-level"] = DebugInfoHolder.DEBUG_TRACE_LEVEL
|
|
85
93
|
|
|
86
94
|
return setup
|
|
87
95
|
|
|
88
96
|
|
|
89
97
|
class _LastFutureImportFinder(ast.NodeVisitor):
|
|
90
|
-
|
|
91
98
|
def __init__(self):
|
|
92
99
|
self.last_future_import_found = None
|
|
93
100
|
|
|
94
101
|
def visit_ImportFrom(self, node):
|
|
95
|
-
if node.module ==
|
|
102
|
+
if node.module == "__future__":
|
|
96
103
|
self.last_future_import_found = node
|
|
97
104
|
|
|
98
105
|
|
|
@@ -109,7 +116,7 @@ def _get_offset_from_line_col(code, line, col):
|
|
|
109
116
|
|
|
110
117
|
|
|
111
118
|
def _separate_future_imports(code):
|
|
112
|
-
|
|
119
|
+
"""
|
|
113
120
|
:param code:
|
|
114
121
|
The code from where we want to get the __future__ imports (note that it's possible that
|
|
115
122
|
there's no such entry).
|
|
@@ -120,18 +127,18 @@ def _separate_future_imports(code):
|
|
|
120
127
|
If the future import is not available a return such as ('', code) is given, otherwise, the
|
|
121
128
|
future import will end with a ';' (so that it can be put right before the pydevd attach
|
|
122
129
|
code).
|
|
123
|
-
|
|
130
|
+
"""
|
|
124
131
|
try:
|
|
125
|
-
node = ast.parse(code,
|
|
132
|
+
node = ast.parse(code, "<string>", "exec")
|
|
126
133
|
visitor = _LastFutureImportFinder()
|
|
127
134
|
visitor.visit(node)
|
|
128
135
|
|
|
129
136
|
if visitor.last_future_import_found is None:
|
|
130
|
-
return
|
|
137
|
+
return "", code
|
|
131
138
|
|
|
132
139
|
node = visitor.last_future_import_found
|
|
133
140
|
offset = -1
|
|
134
|
-
if hasattr(node,
|
|
141
|
+
if hasattr(node, "end_lineno") and hasattr(node, "end_col_offset"):
|
|
135
142
|
# Python 3.8 onwards has these (so, use when possible).
|
|
136
143
|
line, col = node.end_lineno, node.end_col_offset
|
|
137
144
|
offset = _get_offset_from_line_col(code, line - 1, col) # ast lines are 1-based, make it 0-based.
|
|
@@ -151,7 +158,7 @@ def _separate_future_imports(code):
|
|
|
151
158
|
|
|
152
159
|
if offset >= 0:
|
|
153
160
|
for i in range(offset, len(code)):
|
|
154
|
-
if code[i] in (
|
|
161
|
+
if code[i] in (" ", "\t", ";", ")", "\n"):
|
|
155
162
|
offset += 1
|
|
156
163
|
else:
|
|
157
164
|
break
|
|
@@ -162,21 +169,21 @@ def _separate_future_imports(code):
|
|
|
162
169
|
# Now, put '\n' lines back into the code remainder (we had to search for
|
|
163
170
|
# `\n)`, but in case we just got the `\n`, it should be at the remainder,
|
|
164
171
|
# not at the future import.
|
|
165
|
-
while future_import.endswith(
|
|
172
|
+
while future_import.endswith("\n"):
|
|
166
173
|
future_import = future_import[:-1]
|
|
167
|
-
code_remainder =
|
|
174
|
+
code_remainder = "\n" + code_remainder
|
|
168
175
|
|
|
169
|
-
if not future_import.endswith(
|
|
170
|
-
future_import +=
|
|
176
|
+
if not future_import.endswith(";"):
|
|
177
|
+
future_import += ";"
|
|
171
178
|
return future_import, code_remainder
|
|
172
179
|
|
|
173
180
|
# This shouldn't happen...
|
|
174
|
-
pydev_log.info(
|
|
175
|
-
return
|
|
181
|
+
pydev_log.info("Unable to find line %s in code:\n%r", line, code)
|
|
182
|
+
return "", code
|
|
176
183
|
|
|
177
184
|
except:
|
|
178
|
-
pydev_log.exception(
|
|
179
|
-
return
|
|
185
|
+
pydev_log.exception("Error getting from __future__ imports from: %r", code)
|
|
186
|
+
return "", code
|
|
180
187
|
|
|
181
188
|
|
|
182
189
|
def _get_python_c_args(host, port, code, args, setup):
|
|
@@ -185,36 +192,39 @@ def _get_python_c_args(host, port, code, args, setup):
|
|
|
185
192
|
# i.e.: We want to make the repr sorted so that it works in tests.
|
|
186
193
|
setup_repr = setup if setup is None else (sorted_dict_repr(setup))
|
|
187
194
|
|
|
188
|
-
future_imports =
|
|
189
|
-
if
|
|
195
|
+
future_imports = ""
|
|
196
|
+
if "__future__" in code:
|
|
190
197
|
# If the code has a __future__ import, we need to be able to strip the __future__
|
|
191
198
|
# imports from the code and add them to the start of our code snippet.
|
|
192
199
|
future_imports, code = _separate_future_imports(code)
|
|
193
200
|
|
|
194
|
-
return (
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
201
|
+
return (
|
|
202
|
+
"%simport sys; sys.path.insert(0, r'%s'); import pydevd; pydevd.config(%r, %r); "
|
|
203
|
+
"pydevd.settrace(host=%r, port=%s, suspend=False, trace_only_current_thread=False, patch_multiprocessing=True, access_token=%r, client_access_token=%r, __setup_holder__=%s); "
|
|
204
|
+
"%s"
|
|
205
|
+
) % (
|
|
206
|
+
future_imports,
|
|
207
|
+
pydev_src_dir,
|
|
208
|
+
pydevd_constants.get_protocol(),
|
|
209
|
+
PydevdCustomization.DEBUG_MODE,
|
|
210
|
+
host,
|
|
211
|
+
port,
|
|
212
|
+
setup.get("access-token"),
|
|
213
|
+
setup.get("client-access-token"),
|
|
214
|
+
setup_repr,
|
|
215
|
+
code,
|
|
216
|
+
)
|
|
208
217
|
|
|
209
218
|
|
|
210
219
|
def _get_host_port():
|
|
211
220
|
import pydevd
|
|
221
|
+
|
|
212
222
|
host, port = pydevd.dispatch()
|
|
213
223
|
return host, port
|
|
214
224
|
|
|
215
225
|
|
|
216
226
|
def _is_managed_arg(arg):
|
|
217
|
-
pydevd_py = _get_str_type_compatible(arg,
|
|
227
|
+
pydevd_py = _get_str_type_compatible(arg, "pydevd.py")
|
|
218
228
|
if arg.endswith(pydevd_py):
|
|
219
229
|
return True
|
|
220
230
|
return False
|
|
@@ -225,22 +235,24 @@ def _on_forked_process(setup_tracing=True):
|
|
|
225
235
|
pydev_log.initialize_debug_stream(reinitialize=True)
|
|
226
236
|
|
|
227
237
|
if setup_tracing:
|
|
228
|
-
pydev_log.debug(
|
|
238
|
+
pydev_log.debug("pydevd on forked process: %s", os.getpid())
|
|
229
239
|
|
|
230
240
|
import pydevd
|
|
241
|
+
|
|
231
242
|
pydevd.threadingCurrentThread().__pydevd_main_thread = True
|
|
232
243
|
pydevd.settrace_forked(setup_tracing=setup_tracing)
|
|
233
244
|
|
|
234
245
|
|
|
235
246
|
def _on_set_trace_for_new_thread(global_debugger):
|
|
236
247
|
if global_debugger is not None:
|
|
237
|
-
|
|
248
|
+
if not PYDEVD_USE_SYS_MONITORING:
|
|
249
|
+
global_debugger.enable_tracing()
|
|
238
250
|
|
|
239
251
|
|
|
240
252
|
def _get_str_type_compatible(s, args):
|
|
241
|
-
|
|
253
|
+
"""
|
|
242
254
|
This method converts `args` to byte/unicode based on the `s' type.
|
|
243
|
-
|
|
255
|
+
"""
|
|
244
256
|
if isinstance(args, (list, tuple)):
|
|
245
257
|
ret = []
|
|
246
258
|
for arg in args:
|
|
@@ -248,30 +260,30 @@ def _get_str_type_compatible(s, args):
|
|
|
248
260
|
ret.append(arg)
|
|
249
261
|
else:
|
|
250
262
|
if isinstance(s, bytes):
|
|
251
|
-
ret.append(arg.encode(
|
|
263
|
+
ret.append(arg.encode("utf-8"))
|
|
252
264
|
else:
|
|
253
|
-
ret.append(arg.decode(
|
|
265
|
+
ret.append(arg.decode("utf-8"))
|
|
254
266
|
return ret
|
|
255
267
|
else:
|
|
256
268
|
if type(s) == type(args):
|
|
257
269
|
return args
|
|
258
270
|
else:
|
|
259
271
|
if isinstance(s, bytes):
|
|
260
|
-
return args.encode(
|
|
272
|
+
return args.encode("utf-8")
|
|
261
273
|
else:
|
|
262
|
-
return args.decode(
|
|
274
|
+
return args.decode("utf-8")
|
|
263
275
|
|
|
264
276
|
|
|
265
|
-
|
|
277
|
+
# ===============================================================================
|
|
266
278
|
# Things related to monkey-patching
|
|
267
|
-
|
|
279
|
+
# ===============================================================================
|
|
268
280
|
def is_python(path):
|
|
269
281
|
single_quote, double_quote = _get_str_type_compatible(path, ["'", '"'])
|
|
270
282
|
|
|
271
283
|
if path.endswith(single_quote) or path.endswith(double_quote):
|
|
272
|
-
path = path[1:len(path) - 1]
|
|
284
|
+
path = path[1 : len(path) - 1]
|
|
273
285
|
filename = os.path.basename(path).lower()
|
|
274
|
-
for name in _get_str_type_compatible(filename, [
|
|
286
|
+
for name in _get_str_type_compatible(filename, ["python", "jython", "pypy"]):
|
|
275
287
|
if filename.find(name) != -1:
|
|
276
288
|
return True
|
|
277
289
|
|
|
@@ -342,8 +354,8 @@ def quote_arg_win32(arg):
|
|
|
342
354
|
#
|
|
343
355
|
# N backslashes in any other position remain as is.
|
|
344
356
|
|
|
345
|
-
arg = re.sub(fix_type(r
|
|
346
|
-
arg = re.sub(fix_type(r
|
|
357
|
+
arg = re.sub(fix_type(r"(\\*)\""), fix_type(r'\1\1\\"'), arg)
|
|
358
|
+
arg = re.sub(fix_type(r"(\\*)$"), fix_type(r"\1\1"), arg)
|
|
347
359
|
return fix_type('"') + arg + fix_type('"')
|
|
348
360
|
|
|
349
361
|
|
|
@@ -355,21 +367,21 @@ def quote_args(args):
|
|
|
355
367
|
|
|
356
368
|
|
|
357
369
|
def patch_args(args, is_exec=False):
|
|
358
|
-
|
|
370
|
+
"""
|
|
359
371
|
:param list args:
|
|
360
372
|
Arguments to patch.
|
|
361
373
|
|
|
362
374
|
:param bool is_exec:
|
|
363
375
|
If it's an exec, the current process will be replaced (this means we have
|
|
364
376
|
to keep the same ppid).
|
|
365
|
-
|
|
377
|
+
"""
|
|
366
378
|
try:
|
|
367
379
|
pydev_log.debug("Patching args: %s", args)
|
|
368
380
|
original_args = args
|
|
369
381
|
try:
|
|
370
382
|
unquoted_args = remove_quotes_from_args(args)
|
|
371
383
|
except InvalidTypeInArgsException as e:
|
|
372
|
-
pydev_log.info(
|
|
384
|
+
pydev_log.info("Unable to monkey-patch subprocess arguments because a type found in the args is invalid: %s", e)
|
|
373
385
|
return original_args
|
|
374
386
|
|
|
375
387
|
# Internally we should reference original_args (if we want to return them) or unquoted_args
|
|
@@ -377,6 +389,7 @@ def patch_args(args, is_exec=False):
|
|
|
377
389
|
del args
|
|
378
390
|
|
|
379
391
|
from pydevd import SetupHolder
|
|
392
|
+
|
|
380
393
|
if not unquoted_args:
|
|
381
394
|
return original_args
|
|
382
395
|
|
|
@@ -386,11 +399,11 @@ def patch_args(args, is_exec=False):
|
|
|
386
399
|
|
|
387
400
|
# Note: we create a copy as string to help with analyzing the arguments, but
|
|
388
401
|
# the final list should have items from the unquoted_args as they were initially.
|
|
389
|
-
args_as_str = _get_str_type_compatible(
|
|
402
|
+
args_as_str = _get_str_type_compatible("", unquoted_args)
|
|
390
403
|
|
|
391
404
|
params_with_value_in_separate_arg = (
|
|
392
|
-
|
|
393
|
-
|
|
405
|
+
"--check-hash-based-pycs",
|
|
406
|
+
"--jit", # pypy option
|
|
394
407
|
)
|
|
395
408
|
|
|
396
409
|
# All short switches may be combined together. The ones below require a value and the
|
|
@@ -412,17 +425,17 @@ def patch_args(args, is_exec=False):
|
|
|
412
425
|
#
|
|
413
426
|
# python -O -Q old -v -c "import sys;print(sys)"
|
|
414
427
|
|
|
415
|
-
params_with_combinable_arg = set((
|
|
428
|
+
params_with_combinable_arg = set(("W", "X", "Q", "c", "m"))
|
|
416
429
|
|
|
417
430
|
module_name = None
|
|
418
|
-
before_module_flag =
|
|
431
|
+
before_module_flag = ""
|
|
419
432
|
module_name_i_start = -1
|
|
420
433
|
module_name_i_end = -1
|
|
421
434
|
|
|
422
435
|
code = None
|
|
423
436
|
code_i = -1
|
|
424
437
|
code_i_end = -1
|
|
425
|
-
code_flag =
|
|
438
|
+
code_flag = ""
|
|
426
439
|
|
|
427
440
|
filename = None
|
|
428
441
|
filename_i = -1
|
|
@@ -433,8 +446,8 @@ def patch_args(args, is_exec=False):
|
|
|
433
446
|
ignore_next = False
|
|
434
447
|
continue
|
|
435
448
|
|
|
436
|
-
if arg_as_str.startswith(
|
|
437
|
-
if arg_as_str ==
|
|
449
|
+
if arg_as_str.startswith("-"):
|
|
450
|
+
if arg_as_str == "-":
|
|
438
451
|
# Contents will be read from the stdin. This is not currently handled.
|
|
439
452
|
pydev_log.debug('Unable to fix arguments to attach debugger on subprocess when reading from stdin ("python ... -").')
|
|
440
453
|
return original_args
|
|
@@ -446,40 +459,39 @@ def patch_args(args, is_exec=False):
|
|
|
446
459
|
|
|
447
460
|
break_out = False
|
|
448
461
|
for j, c in enumerate(arg_as_str):
|
|
449
|
-
|
|
450
462
|
# i.e.: Python supports -X faulthandler as well as -Xfaulthandler
|
|
451
463
|
# (in one case we have to ignore the next and in the other we don't
|
|
452
464
|
# have to ignore it).
|
|
453
465
|
if c in params_with_combinable_arg:
|
|
454
|
-
remainder = arg_as_str[j + 1:]
|
|
466
|
+
remainder = arg_as_str[j + 1 :]
|
|
455
467
|
if not remainder:
|
|
456
468
|
ignore_next = True
|
|
457
469
|
|
|
458
|
-
if c ==
|
|
470
|
+
if c == "m":
|
|
459
471
|
# i.e.: Something as
|
|
460
472
|
# python -qm test
|
|
461
473
|
# python -m test
|
|
462
474
|
# python -qmtest
|
|
463
475
|
before_module_flag = arg_as_str[:j] # before_module_flag would then be "-q"
|
|
464
|
-
if before_module_flag ==
|
|
465
|
-
before_module_flag =
|
|
476
|
+
if before_module_flag == "-":
|
|
477
|
+
before_module_flag = ""
|
|
466
478
|
module_name_i_start = i
|
|
467
479
|
if not remainder:
|
|
468
480
|
module_name = unquoted_args[i + 1]
|
|
469
481
|
module_name_i_end = i + 1
|
|
470
482
|
else:
|
|
471
483
|
# i.e.: python -qmtest should provide 'test' as the module_name
|
|
472
|
-
module_name = unquoted_args[i][j + 1:]
|
|
484
|
+
module_name = unquoted_args[i][j + 1 :]
|
|
473
485
|
module_name_i_end = module_name_i_start
|
|
474
486
|
break_out = True
|
|
475
487
|
break
|
|
476
488
|
|
|
477
|
-
elif c ==
|
|
489
|
+
elif c == "c":
|
|
478
490
|
# i.e.: Something as
|
|
479
491
|
# python -qc "import sys"
|
|
480
492
|
# python -c "import sys"
|
|
481
493
|
# python "-qcimport sys"
|
|
482
|
-
code_flag = arg_as_str[:j + 1] # code_flag would then be "-qc"
|
|
494
|
+
code_flag = arg_as_str[: j + 1] # code_flag would then be "-qc"
|
|
483
495
|
|
|
484
496
|
if not remainder:
|
|
485
497
|
# arg_as_str is something as "-qc", "import sys"
|
|
@@ -513,13 +525,13 @@ def patch_args(args, is_exec=False):
|
|
|
513
525
|
filename_i = i
|
|
514
526
|
|
|
515
527
|
if _is_managed_arg(filename): # no need to add pydevd twice
|
|
516
|
-
pydev_log.debug(
|
|
528
|
+
pydev_log.debug("Skipped monkey-patching as pydevd.py is in args already.")
|
|
517
529
|
return original_args
|
|
518
530
|
|
|
519
531
|
break
|
|
520
532
|
else:
|
|
521
533
|
# We didn't find the filename (something is unexpected).
|
|
522
|
-
pydev_log.debug(
|
|
534
|
+
pydev_log.debug("Unable to fix arguments to attach debugger on subprocess (filename not found).")
|
|
523
535
|
return original_args
|
|
524
536
|
|
|
525
537
|
if code_i != -1:
|
|
@@ -536,13 +548,14 @@ def patch_args(args, is_exec=False):
|
|
|
536
548
|
|
|
537
549
|
first_non_vm_index = max(filename_i, module_name_i_start)
|
|
538
550
|
if first_non_vm_index == -1:
|
|
539
|
-
pydev_log.debug(
|
|
551
|
+
pydev_log.debug("Unable to fix arguments to attach debugger on subprocess (could not resolve filename nor module name).")
|
|
540
552
|
return original_args
|
|
541
553
|
|
|
542
554
|
# Original args should be something as:
|
|
543
555
|
# ['X:\\pysrc\\pydevd.py', '--multiprocess', '--print-in-debugger-startup',
|
|
544
556
|
# '--vm_type', 'python', '--client', '127.0.0.1', '--port', '56352', '--file', 'x:\\snippet1.py']
|
|
545
557
|
from _pydevd_bundle.pydevd_command_line_handling import setup_to_argv
|
|
558
|
+
|
|
546
559
|
new_args = []
|
|
547
560
|
new_args.extend(unquoted_args[:first_non_vm_index])
|
|
548
561
|
if before_module_flag:
|
|
@@ -550,31 +563,32 @@ def patch_args(args, is_exec=False):
|
|
|
550
563
|
|
|
551
564
|
add_module_at = len(new_args) + 1
|
|
552
565
|
|
|
553
|
-
new_args.extend(
|
|
554
|
-
|
|
555
|
-
|
|
556
|
-
|
|
557
|
-
|
|
566
|
+
new_args.extend(
|
|
567
|
+
setup_to_argv(
|
|
568
|
+
_get_setup_updated_with_protocol_and_ppid(SetupHolder.setup, is_exec=is_exec), skip_names=set(("module", "cmd-line"))
|
|
569
|
+
)
|
|
570
|
+
)
|
|
571
|
+
new_args.append("--file")
|
|
558
572
|
|
|
559
573
|
if module_name is not None:
|
|
560
574
|
assert module_name_i_start != -1
|
|
561
575
|
assert module_name_i_end != -1
|
|
562
576
|
# Always after 'pydevd' (i.e.: pydevd "--module" --multiprocess ...)
|
|
563
|
-
new_args.insert(add_module_at,
|
|
577
|
+
new_args.insert(add_module_at, "--module")
|
|
564
578
|
new_args.append(module_name)
|
|
565
|
-
new_args.extend(unquoted_args[module_name_i_end + 1:])
|
|
579
|
+
new_args.extend(unquoted_args[module_name_i_end + 1 :])
|
|
566
580
|
|
|
567
581
|
elif filename is not None:
|
|
568
582
|
assert filename_i != -1
|
|
569
583
|
new_args.append(filename)
|
|
570
|
-
new_args.extend(unquoted_args[filename_i + 1:])
|
|
584
|
+
new_args.extend(unquoted_args[filename_i + 1 :])
|
|
571
585
|
|
|
572
586
|
else:
|
|
573
|
-
raise AssertionError(
|
|
587
|
+
raise AssertionError("Internal error (unexpected condition)")
|
|
574
588
|
|
|
575
589
|
return quote_args(new_args)
|
|
576
590
|
except:
|
|
577
|
-
pydev_log.exception(
|
|
591
|
+
pydev_log.exception("Error patching args (debugger not attached to subprocess).")
|
|
578
592
|
return original_args
|
|
579
593
|
|
|
580
594
|
|
|
@@ -592,21 +606,21 @@ def str_to_args_windows(args):
|
|
|
592
606
|
|
|
593
607
|
state = DEFAULT
|
|
594
608
|
backslashes = 0
|
|
595
|
-
buf =
|
|
609
|
+
buf = ""
|
|
596
610
|
|
|
597
611
|
args_len = len(args)
|
|
598
612
|
for i in range(args_len):
|
|
599
613
|
ch = args[i]
|
|
600
|
-
if
|
|
614
|
+
if ch == "\\":
|
|
601
615
|
backslashes += 1
|
|
602
616
|
continue
|
|
603
|
-
elif
|
|
617
|
+
elif backslashes != 0:
|
|
604
618
|
if ch == '"':
|
|
605
619
|
while backslashes >= 2:
|
|
606
620
|
backslashes -= 2
|
|
607
|
-
buf +=
|
|
608
|
-
if
|
|
609
|
-
if
|
|
621
|
+
buf += "\\"
|
|
622
|
+
if backslashes == 1:
|
|
623
|
+
if state == DEFAULT:
|
|
610
624
|
state = ARG
|
|
611
625
|
|
|
612
626
|
buf += '"'
|
|
@@ -615,21 +629,21 @@ def str_to_args_windows(args):
|
|
|
615
629
|
# else fall through to switch
|
|
616
630
|
else:
|
|
617
631
|
# false alarm, treat passed backslashes literally...
|
|
618
|
-
if
|
|
632
|
+
if state == DEFAULT:
|
|
619
633
|
state = ARG
|
|
620
634
|
|
|
621
635
|
while backslashes > 0:
|
|
622
636
|
backslashes -= 1
|
|
623
|
-
buf +=
|
|
637
|
+
buf += "\\"
|
|
624
638
|
# fall through to switch
|
|
625
|
-
if ch in (
|
|
626
|
-
if
|
|
639
|
+
if ch in (" ", "\t"):
|
|
640
|
+
if state == DEFAULT:
|
|
627
641
|
# skip
|
|
628
642
|
continue
|
|
629
|
-
elif
|
|
643
|
+
elif state == ARG:
|
|
630
644
|
state = DEFAULT
|
|
631
645
|
result.append(buf)
|
|
632
|
-
buf =
|
|
646
|
+
buf = ""
|
|
633
647
|
continue
|
|
634
648
|
|
|
635
649
|
if state in (DEFAULT, ARG):
|
|
@@ -641,7 +655,7 @@ def str_to_args_windows(args):
|
|
|
641
655
|
|
|
642
656
|
elif state == IN_DOUBLE_QUOTE:
|
|
643
657
|
if ch == '"':
|
|
644
|
-
if
|
|
658
|
+
if i + 1 < args_len and args[i + 1] == '"':
|
|
645
659
|
# Undocumented feature in Windows:
|
|
646
660
|
# Two consecutive double quotes inside a double-quoted argument are interpreted as
|
|
647
661
|
# a single double quote.
|
|
@@ -653,7 +667,7 @@ def str_to_args_windows(args):
|
|
|
653
667
|
buf += ch
|
|
654
668
|
|
|
655
669
|
else:
|
|
656
|
-
raise RuntimeError(
|
|
670
|
+
raise RuntimeError("Illegal condition")
|
|
657
671
|
|
|
658
672
|
if len(buf) > 0 or state != DEFAULT:
|
|
659
673
|
result.append(buf)
|
|
@@ -666,14 +680,14 @@ def patch_arg_str_win(arg_str):
|
|
|
666
680
|
# Fix https://youtrack.jetbrains.com/issue/PY-9767 (args may be empty)
|
|
667
681
|
if not args or not is_python(args[0]):
|
|
668
682
|
return arg_str
|
|
669
|
-
arg_str =
|
|
683
|
+
arg_str = " ".join(patch_args(args))
|
|
670
684
|
pydev_log.debug("New args: %s", arg_str)
|
|
671
685
|
return arg_str
|
|
672
686
|
|
|
673
687
|
|
|
674
688
|
def monkey_patch_module(module, funcname, create_func):
|
|
675
689
|
if hasattr(module, funcname):
|
|
676
|
-
original_name =
|
|
690
|
+
original_name = "original_" + funcname
|
|
677
691
|
if not hasattr(module, original_name):
|
|
678
692
|
setattr(module, original_name, getattr(module, funcname))
|
|
679
693
|
setattr(module, funcname, create_func(original_name))
|
|
@@ -692,7 +706,6 @@ def warn_multiproc():
|
|
|
692
706
|
|
|
693
707
|
|
|
694
708
|
def create_warn_multiproc(original_name):
|
|
695
|
-
|
|
696
709
|
def new_warn_multiproc(*args, **kwargs):
|
|
697
710
|
import os
|
|
698
711
|
|
|
@@ -704,7 +717,6 @@ def create_warn_multiproc(original_name):
|
|
|
704
717
|
|
|
705
718
|
|
|
706
719
|
def create_execl(original_name):
|
|
707
|
-
|
|
708
720
|
def new_execl(path, *args):
|
|
709
721
|
"""
|
|
710
722
|
os.execl(path, arg0, arg1, ...)
|
|
@@ -723,7 +735,6 @@ def create_execl(original_name):
|
|
|
723
735
|
|
|
724
736
|
|
|
725
737
|
def create_execv(original_name):
|
|
726
|
-
|
|
727
738
|
def new_execv(path, args):
|
|
728
739
|
"""
|
|
729
740
|
os.execv(path, args)
|
|
@@ -757,7 +768,6 @@ def create_execve(original_name):
|
|
|
757
768
|
|
|
758
769
|
|
|
759
770
|
def create_spawnl(original_name):
|
|
760
|
-
|
|
761
771
|
def new_spawnl(mode, path, *args):
|
|
762
772
|
"""
|
|
763
773
|
os.spawnl(mode, path, arg0, arg1, ...)
|
|
@@ -773,7 +783,6 @@ def create_spawnl(original_name):
|
|
|
773
783
|
|
|
774
784
|
|
|
775
785
|
def create_spawnv(original_name):
|
|
776
|
-
|
|
777
786
|
def new_spawnv(mode, path, args):
|
|
778
787
|
"""
|
|
779
788
|
os.spawnv(mode, path, args)
|
|
@@ -826,6 +835,7 @@ def create_fork_exec(original_name):
|
|
|
826
835
|
|
|
827
836
|
def new_fork_exec(args, *other_args):
|
|
828
837
|
import _posixsubprocess # @UnresolvedImport
|
|
838
|
+
|
|
829
839
|
if _get_apply_arg_patching():
|
|
830
840
|
args = patch_args(args)
|
|
831
841
|
send_process_created_message()
|
|
@@ -843,6 +853,7 @@ def create_warn_fork_exec(original_name):
|
|
|
843
853
|
def new_warn_fork_exec(*args):
|
|
844
854
|
try:
|
|
845
855
|
import _posixsubprocess
|
|
856
|
+
|
|
846
857
|
warn_multiproc()
|
|
847
858
|
return getattr(_posixsubprocess, original_name)(*args)
|
|
848
859
|
except:
|
|
@@ -858,6 +869,7 @@ def create_subprocess_fork_exec(original_name):
|
|
|
858
869
|
|
|
859
870
|
def new_fork_exec(args, *other_args):
|
|
860
871
|
import subprocess
|
|
872
|
+
|
|
861
873
|
if _get_apply_arg_patching():
|
|
862
874
|
args = patch_args(args)
|
|
863
875
|
send_process_created_message()
|
|
@@ -875,6 +887,7 @@ def create_subprocess_warn_fork_exec(original_name):
|
|
|
875
887
|
def new_warn_fork_exec(*args):
|
|
876
888
|
try:
|
|
877
889
|
import subprocess
|
|
890
|
+
|
|
878
891
|
warn_multiproc()
|
|
879
892
|
return getattr(subprocess, original_name)(*args)
|
|
880
893
|
except:
|
|
@@ -920,7 +933,6 @@ def create_CreateProcessWarnMultiproc(original_name):
|
|
|
920
933
|
|
|
921
934
|
|
|
922
935
|
def create_fork(original_name):
|
|
923
|
-
|
|
924
936
|
def new_fork():
|
|
925
937
|
# A simple fork will result in a new python process
|
|
926
938
|
is_new_python_process = True
|
|
@@ -930,12 +942,12 @@ def create_fork(original_name):
|
|
|
930
942
|
|
|
931
943
|
is_subprocess_fork = False
|
|
932
944
|
while frame is not None:
|
|
933
|
-
if frame.f_code.co_name ==
|
|
945
|
+
if frame.f_code.co_name == "_execute_child" and "subprocess" in frame.f_code.co_filename:
|
|
934
946
|
is_subprocess_fork = True
|
|
935
947
|
# If we're actually in subprocess.Popen creating a child, it may
|
|
936
948
|
# result in something which is not a Python process, (so, we
|
|
937
949
|
# don't want to connect with it in the forked version).
|
|
938
|
-
executable = frame.f_locals.get(
|
|
950
|
+
executable = frame.f_locals.get("executable")
|
|
939
951
|
if executable is not None:
|
|
940
952
|
is_new_python_process = False
|
|
941
953
|
if is_python(executable):
|
|
@@ -985,14 +997,14 @@ def patch_new_process_functions():
|
|
|
985
997
|
# os.execve(path, args, env)
|
|
986
998
|
# os.execvp(file, args)
|
|
987
999
|
# os.execvpe(file, args, env)
|
|
988
|
-
monkey_patch_os(
|
|
989
|
-
monkey_patch_os(
|
|
990
|
-
monkey_patch_os(
|
|
991
|
-
monkey_patch_os(
|
|
992
|
-
monkey_patch_os(
|
|
993
|
-
monkey_patch_os(
|
|
994
|
-
monkey_patch_os(
|
|
995
|
-
monkey_patch_os(
|
|
1000
|
+
monkey_patch_os("execl", create_execl)
|
|
1001
|
+
monkey_patch_os("execle", create_execl)
|
|
1002
|
+
monkey_patch_os("execlp", create_execl)
|
|
1003
|
+
monkey_patch_os("execlpe", create_execl)
|
|
1004
|
+
monkey_patch_os("execv", create_execv)
|
|
1005
|
+
monkey_patch_os("execve", create_execve)
|
|
1006
|
+
monkey_patch_os("execvp", create_execv)
|
|
1007
|
+
monkey_patch_os("execvpe", create_execve)
|
|
996
1008
|
|
|
997
1009
|
# os.spawnl(mode, path, ...)
|
|
998
1010
|
# os.spawnle(mode, path, ..., env)
|
|
@@ -1003,28 +1015,30 @@ def patch_new_process_functions():
|
|
|
1003
1015
|
# os.spawnvp(mode, file, args)
|
|
1004
1016
|
# os.spawnvpe(mode, file, args, env)
|
|
1005
1017
|
|
|
1006
|
-
monkey_patch_os(
|
|
1007
|
-
monkey_patch_os(
|
|
1008
|
-
monkey_patch_os(
|
|
1009
|
-
monkey_patch_os(
|
|
1010
|
-
monkey_patch_os(
|
|
1011
|
-
monkey_patch_os(
|
|
1012
|
-
monkey_patch_os(
|
|
1013
|
-
monkey_patch_os(
|
|
1014
|
-
monkey_patch_os(
|
|
1018
|
+
monkey_patch_os("spawnl", create_spawnl)
|
|
1019
|
+
monkey_patch_os("spawnle", create_spawnl)
|
|
1020
|
+
monkey_patch_os("spawnlp", create_spawnl)
|
|
1021
|
+
monkey_patch_os("spawnlpe", create_spawnl)
|
|
1022
|
+
monkey_patch_os("spawnv", create_spawnv)
|
|
1023
|
+
monkey_patch_os("spawnve", create_spawnve)
|
|
1024
|
+
monkey_patch_os("spawnvp", create_spawnv)
|
|
1025
|
+
monkey_patch_os("spawnvpe", create_spawnve)
|
|
1026
|
+
monkey_patch_os("posix_spawn", create_posix_spawn)
|
|
1015
1027
|
|
|
1016
1028
|
if not IS_JYTHON:
|
|
1017
1029
|
if not IS_WINDOWS:
|
|
1018
|
-
monkey_patch_os(
|
|
1030
|
+
monkey_patch_os("fork", create_fork)
|
|
1019
1031
|
try:
|
|
1020
1032
|
import _posixsubprocess
|
|
1021
|
-
|
|
1033
|
+
|
|
1034
|
+
monkey_patch_module(_posixsubprocess, "fork_exec", create_fork_exec)
|
|
1022
1035
|
except ImportError:
|
|
1023
1036
|
pass
|
|
1024
1037
|
|
|
1025
1038
|
try:
|
|
1026
1039
|
import subprocess
|
|
1027
|
-
|
|
1040
|
+
|
|
1041
|
+
monkey_patch_module(subprocess, "_fork_exec", create_subprocess_fork_exec)
|
|
1028
1042
|
except AttributeError:
|
|
1029
1043
|
pass
|
|
1030
1044
|
else:
|
|
@@ -1033,40 +1047,42 @@ def patch_new_process_functions():
|
|
|
1033
1047
|
import _subprocess
|
|
1034
1048
|
except ImportError:
|
|
1035
1049
|
import _winapi as _subprocess
|
|
1036
|
-
monkey_patch_module(_subprocess,
|
|
1050
|
+
monkey_patch_module(_subprocess, "CreateProcess", create_CreateProcess)
|
|
1037
1051
|
|
|
1038
1052
|
|
|
1039
1053
|
def patch_new_process_functions_with_warning():
|
|
1040
|
-
monkey_patch_os(
|
|
1041
|
-
monkey_patch_os(
|
|
1042
|
-
monkey_patch_os(
|
|
1043
|
-
monkey_patch_os(
|
|
1044
|
-
monkey_patch_os(
|
|
1045
|
-
monkey_patch_os(
|
|
1046
|
-
monkey_patch_os(
|
|
1047
|
-
monkey_patch_os(
|
|
1048
|
-
monkey_patch_os(
|
|
1049
|
-
monkey_patch_os(
|
|
1050
|
-
monkey_patch_os(
|
|
1051
|
-
monkey_patch_os(
|
|
1052
|
-
monkey_patch_os(
|
|
1053
|
-
monkey_patch_os(
|
|
1054
|
-
monkey_patch_os(
|
|
1055
|
-
monkey_patch_os(
|
|
1056
|
-
monkey_patch_os(
|
|
1054
|
+
monkey_patch_os("execl", create_warn_multiproc)
|
|
1055
|
+
monkey_patch_os("execle", create_warn_multiproc)
|
|
1056
|
+
monkey_patch_os("execlp", create_warn_multiproc)
|
|
1057
|
+
monkey_patch_os("execlpe", create_warn_multiproc)
|
|
1058
|
+
monkey_patch_os("execv", create_warn_multiproc)
|
|
1059
|
+
monkey_patch_os("execve", create_warn_multiproc)
|
|
1060
|
+
monkey_patch_os("execvp", create_warn_multiproc)
|
|
1061
|
+
monkey_patch_os("execvpe", create_warn_multiproc)
|
|
1062
|
+
monkey_patch_os("spawnl", create_warn_multiproc)
|
|
1063
|
+
monkey_patch_os("spawnle", create_warn_multiproc)
|
|
1064
|
+
monkey_patch_os("spawnlp", create_warn_multiproc)
|
|
1065
|
+
monkey_patch_os("spawnlpe", create_warn_multiproc)
|
|
1066
|
+
monkey_patch_os("spawnv", create_warn_multiproc)
|
|
1067
|
+
monkey_patch_os("spawnve", create_warn_multiproc)
|
|
1068
|
+
monkey_patch_os("spawnvp", create_warn_multiproc)
|
|
1069
|
+
monkey_patch_os("spawnvpe", create_warn_multiproc)
|
|
1070
|
+
monkey_patch_os("posix_spawn", create_warn_multiproc)
|
|
1057
1071
|
|
|
1058
1072
|
if not IS_JYTHON:
|
|
1059
1073
|
if not IS_WINDOWS:
|
|
1060
|
-
monkey_patch_os(
|
|
1074
|
+
monkey_patch_os("fork", create_warn_multiproc)
|
|
1061
1075
|
try:
|
|
1062
1076
|
import _posixsubprocess
|
|
1063
|
-
|
|
1077
|
+
|
|
1078
|
+
monkey_patch_module(_posixsubprocess, "fork_exec", create_warn_fork_exec)
|
|
1064
1079
|
except ImportError:
|
|
1065
1080
|
pass
|
|
1066
1081
|
|
|
1067
1082
|
try:
|
|
1068
1083
|
import subprocess
|
|
1069
|
-
|
|
1084
|
+
|
|
1085
|
+
monkey_patch_module(subprocess, "_fork_exec", create_subprocess_warn_fork_exec)
|
|
1070
1086
|
except AttributeError:
|
|
1071
1087
|
pass
|
|
1072
1088
|
|
|
@@ -1076,11 +1092,10 @@ def patch_new_process_functions_with_warning():
|
|
|
1076
1092
|
import _subprocess
|
|
1077
1093
|
except ImportError:
|
|
1078
1094
|
import _winapi as _subprocess
|
|
1079
|
-
monkey_patch_module(_subprocess,
|
|
1095
|
+
monkey_patch_module(_subprocess, "CreateProcess", create_CreateProcessWarnMultiproc)
|
|
1080
1096
|
|
|
1081
1097
|
|
|
1082
1098
|
class _NewThreadStartupWithTrace:
|
|
1083
|
-
|
|
1084
1099
|
def __init__(self, original_func, args, kwargs):
|
|
1085
1100
|
self.original_func = original_func
|
|
1086
1101
|
self.args = args
|
|
@@ -1097,20 +1112,21 @@ class _NewThreadStartupWithTrace:
|
|
|
1097
1112
|
# the start_new_thread internal machinery and thread._bootstrap has not finished), so, the code below needs
|
|
1098
1113
|
# to make sure that we use the current thread bound to the original function and not use
|
|
1099
1114
|
# threading.current_thread() unless we're sure it's a dummy thread.
|
|
1100
|
-
t = getattr(self.original_func,
|
|
1115
|
+
t = getattr(self.original_func, "__self__", getattr(self.original_func, "im_self", None))
|
|
1101
1116
|
if not isinstance(t, threading.Thread):
|
|
1102
1117
|
# This is not a threading.Thread but a Dummy thread (so, get it as a dummy thread using
|
|
1103
1118
|
# currentThread).
|
|
1104
1119
|
t = threading.current_thread()
|
|
1105
1120
|
|
|
1106
|
-
if not getattr(t,
|
|
1121
|
+
if not getattr(t, "is_pydev_daemon_thread", False):
|
|
1107
1122
|
thread_id = get_current_thread_id(t)
|
|
1108
1123
|
py_db.notify_thread_created(thread_id, t)
|
|
1109
1124
|
_on_set_trace_for_new_thread(py_db)
|
|
1110
1125
|
|
|
1111
|
-
if getattr(py_db,
|
|
1126
|
+
if getattr(py_db, "thread_analyser", None) is not None:
|
|
1112
1127
|
try:
|
|
1113
1128
|
from _pydevd_bundle.pydevd_concurrency_analyser.pydevd_concurrency_logger import log_new_thread
|
|
1129
|
+
|
|
1114
1130
|
log_new_thread(py_db, t)
|
|
1115
1131
|
except:
|
|
1116
1132
|
sys.stderr.write("Failed to detect new thread for visualization")
|
|
@@ -1128,7 +1144,6 @@ class _NewThreadStartupWithTrace:
|
|
|
1128
1144
|
|
|
1129
1145
|
|
|
1130
1146
|
class _NewThreadStartupWithoutTrace:
|
|
1131
|
-
|
|
1132
1147
|
def __init__(self, original_func, args, kwargs):
|
|
1133
1148
|
self.original_func = original_func
|
|
1134
1149
|
self.args = args
|
|
@@ -1158,10 +1173,9 @@ threading_modules_to_patch = _get_threading_modules_to_patch()
|
|
|
1158
1173
|
|
|
1159
1174
|
|
|
1160
1175
|
def patch_thread_module(thread_module):
|
|
1161
|
-
|
|
1162
|
-
if getattr(thread_module, '_original_start_new_thread', None) is None:
|
|
1176
|
+
if getattr(thread_module, "_original_start_new_thread", None) is None:
|
|
1163
1177
|
if thread_module is threading:
|
|
1164
|
-
if not hasattr(thread_module,
|
|
1178
|
+
if not hasattr(thread_module, "_start_new_thread"):
|
|
1165
1179
|
return # Jython doesn't have it.
|
|
1166
1180
|
_original_start_new_thread = thread_module._original_start_new_thread = thread_module._start_new_thread
|
|
1167
1181
|
else:
|
|
@@ -1170,12 +1184,11 @@ def patch_thread_module(thread_module):
|
|
|
1170
1184
|
_original_start_new_thread = thread_module._original_start_new_thread
|
|
1171
1185
|
|
|
1172
1186
|
class ClassWithPydevStartNewThread:
|
|
1173
|
-
|
|
1174
1187
|
def pydev_start_new_thread(self, function, args=(), kwargs={}):
|
|
1175
|
-
|
|
1188
|
+
"""
|
|
1176
1189
|
We need to replace the original thread_module.start_new_thread with this function so that threads started
|
|
1177
1190
|
through it and not through the threading module are properly traced.
|
|
1178
|
-
|
|
1191
|
+
"""
|
|
1179
1192
|
return _original_start_new_thread(_UseNewThreadStartup(function, args, kwargs), ())
|
|
1180
1193
|
|
|
1181
1194
|
# This is a hack for the situation where the thread_module.start_new_thread is declared inside a class, such as the one below
|
|
@@ -1224,17 +1237,17 @@ def undo_patch_thread_modules():
|
|
|
1224
1237
|
|
|
1225
1238
|
|
|
1226
1239
|
def disable_trace_thread_modules():
|
|
1227
|
-
|
|
1240
|
+
"""
|
|
1228
1241
|
Can be used to temporarily stop tracing threads created with thread.start_new_thread.
|
|
1229
|
-
|
|
1242
|
+
"""
|
|
1230
1243
|
global _UseNewThreadStartup
|
|
1231
1244
|
_UseNewThreadStartup = _NewThreadStartupWithoutTrace
|
|
1232
1245
|
|
|
1233
1246
|
|
|
1234
1247
|
def enable_trace_thread_modules():
|
|
1235
|
-
|
|
1248
|
+
"""
|
|
1236
1249
|
Can be used to start tracing threads created with thread.start_new_thread again.
|
|
1237
|
-
|
|
1250
|
+
"""
|
|
1238
1251
|
global _UseNewThreadStartup
|
|
1239
1252
|
_UseNewThreadStartup = _NewThreadStartupWithTrace
|
|
1240
1253
|
|