我尝试重新安装 VS 代码(在另一个驱动器 F: 中).我正在使用 python(conda) 解释器. 解决方案 我通过以下方式解决了这个问题:打开 Anaconda 导航器使用顶部的菜单切换到正确的 conda 环境从 Anaconda 导航器打开 VS Code出于某种原因,这使交互式窗口再次工作.This is the error message displayed when I run the code in Interactive window in vs code:C:\Users\rohit\AppData\Roaming\Python\Python38\site-packages\traitlets\traitlets.py:2195: FutureWarning: Supporting extra quotes around Unicode is deprecated in traitlets 5.0. Use 'hmac-sha256' instead of '"hmac-sha256"' – or use CUnicode. warn( C:\Users\rohit\AppData\Roaming\Python\Python38\site-packages\traitlets\traitlets.py:2150: FutureWarning: Supporting extra quotes around Bytes is deprecated in traitlets 5.0. Use '8fe74386-11f1-4831-b37d-5582442edf8a' instead of 'b"8fe74386-11f1-4831-b37d-5582442edf8a"'. warn( Traceback (most recent call last): File "c:\Users\rohit.vscode\extensions\ms-toolsai.jupyter-2021.5.702919634\pythonFiles\vscode_datascience_helpers..\pyvsc-run-isolated.py", line 30, in runpy.run_path(module, run_name="main") File "F:\Anaconda\lib\runpy.py", line 265, in run_path return _run_module_code(code, init_globals, run_name, File "F:\Anaconda\lib\runpy.py", line 97, in _run_module_code _r...I tried re-installing VS code (In another DRIVE F:).I am using python(conda) interpreter. 解决方案 I fixed this by:Opening Anaconda NavigatorSwitching to the correct conda environment with the menu at the topOpening VS Code from the Anaconda navigatorFor some reason, this made the interactive window work again. 这篇关于内核以退出代码 1(VS 代码)死亡的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持! 上岸,阿里云!
08-04 00:27