Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/python/325.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181

Warning: file_get_contents(/data/phpspider/zhask/data//catemap/8/visual-studio-code/3.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Python 在VSCode中进入导入的标准模块_Python_Visual Studio Code - Fatal编程技术网

Python 在VSCode中进入导入的标准模块

Python 在VSCode中进入导入的标准模块,python,visual-studio-code,Python,Visual Studio Code,我使用Visual Studio代码编写了以下简单代码: 导入副本 a=3 b=复制。复制(a) 印刷品(b) 希望在调试时看到copy.py的内部作品 VisualStudio代码是否可以实现这一点?如果是,怎么做 我在“import copy”和copy.py(位于C:\Users\\AppData\Local\Programs\Python\Python37-32\Lib\copy.py)的第一行上放置了一个断点。Vscode在调试时默认忽略标准库 将以下内容添加到launch.json

我使用Visual Studio代码编写了以下简单代码:

导入副本
a=3
b=复制。复制(a)
印刷品(b)
希望在调试时看到copy.py的内部作品

VisualStudio代码是否可以实现这一点?如果是,怎么做


我在“import copy”和copy.py(位于C:\Users\\AppData\Local\Programs\Python\Python37-32\Lib\copy.py)的第一行上放置了一个断点。

Vscode在调试时默认忽略标准库

将以下内容添加到
launch.json
中首选的Python调试器配置中:

"debugStdLib": true
这就是我的样子:

{
    // Use IntelliSense to learn about possible attributes.
    // Hover to view descriptions of existing attributes.
    // For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
    "version": "0.2.0",
    "configurations": [

        {
            "name": "Python: Current File (Integrated Terminal)",
            "type": "python",
            "request": "launch",
            "program": "${file}",
            "console": "integratedTerminal",
            "debugStdLib": true
        },
    ]
}
资料来源: