mirror of
https://github.com/microsoft/debugpy.git
synced 2025-12-23 08:48:12 +00:00
Update handlers.py
* Remove named constant * move test when not "noDebug": false
This commit is contained in:
parent
3e90c5a903
commit
891bc7f88b
1 changed files with 4 additions and 7 deletions
|
|
@ -10,9 +10,6 @@ from debugpy import launcher
|
|||
from debugpy.common import json
|
||||
from debugpy.launcher import debuggee
|
||||
|
||||
# see https://github.com/microsoft/debugpy/issues/861
|
||||
PYTHON_311 = sys.version_info[:2] == (3, 11)
|
||||
|
||||
def launch_request(request):
|
||||
debug_options = set(request("debugOptions", json.array(str)))
|
||||
|
||||
|
|
@ -40,11 +37,11 @@ def launch_request(request):
|
|||
python = request("python", json.array(str, size=(1,)))
|
||||
cmdline = list(python)
|
||||
|
||||
# see https://github.com/microsoft/debugpy/issues/861
|
||||
if PYTHON_311:
|
||||
cmdline += ["-X", "frozen_modules=off"]
|
||||
|
||||
if not request("noDebug", json.default(False)):
|
||||
# see https://github.com/microsoft/debugpy/issues/861
|
||||
if sys.version_info[:2] >= (3, 11):
|
||||
cmdline += ["-X", "frozen_modules=off"]
|
||||
|
||||
port = request("port", int)
|
||||
cmdline += [
|
||||
os.path.dirname(debugpy.__file__),
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue