文章目录 原因解决方法参考 原因 runcode插件默认包含执行选中文本功能,当运行程序时会优先执行光标选中的代码并生成temp文件 解决方法 在设置中搜索 ignoreSelection 并勾选Whether to ignore selection to always run entire file. 参考 如何让VSCode不生成 tempcoderunnerfile.py