question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

'terminal.integrated.shell.windows' of workspace is ignored by python launcher

See original GitHub issue

Environment data

  • VS Code version: 1.44.0
  • Extension version (available under the Extensions sidebar): 2020.3.71659
  • OS and version: Windows 10 ver.1909
  • Python version (& distribution if applicable, e.g. Anaconda): 3.7.7
  • Type of virtual environment used (N/A | venv | virtualenv | conda | …): venv
  • Relevant/affected Python packages and their versions: (None)
  • Relevant/affected Python-related VS Code extensions and their versions: (None)
  • Jedi or Language Server? (i.e. what is "python.jediEnabled" set to; more info #3977): True
  • Value of the python.languageServer setting: Microsoft

Expected behaviour

If ‘terminal.integrated.shell.windows’ is set in XXX.code-workspace file, it overrides the same value of user level setting.

Actual behaviour

Python launches on ‘terminal.integrated.shell.windows’ of user setting, and it ignores ‘terminal.integrated.shell.windows’ of workspace setting.

Steps to reproduce:

  1. Set workspace Create test.code-workspace as the following;
{
	"folders": [
		{
			"path": "."
		}
	],
	"settings": {
		"terminal.integrated.shell.windows": "${env:SystemRoot}\\system32\\cmd.exe"
	}
}
  1. Open this workspace from menu [Open Workspace]

  2. Open terminal (i.e. [Ctrl]+[j])

Command Prompt is opened.

Select [Allow], if VSC shows the message about ‘Terminal change’.

  1. Change default terminal to PowerShell in terminal menu ‘Select Default Shell’

  2. Open terminal again (i.e. [+] button of terminal window top)

Command Prompt is opened.

  1. Open python code on editor and start debug (i.e. [F5])

Python launches on PowerShell

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:9 (3 by maintainers)

github_iconTop GitHub Comments

2reactions
ImpulseAdventurecommented, Aug 10, 2020

@Hoshino-Roxy – for future reference & for others also encountering your issue:

  • The workspace-scoped override of the terminal.integrated.shell settings are disabled by default in vscode.
  • You can enable this from View -> Command Palette and selecting “Terminal: Manage Workspace Shell Permissions”.
0reactions
ericsnowcurrentlycommented, May 27, 2020

I’m not seeing anything useful in the extension’s logs. As noted earlier, you’ll need to open a new issue against VS Code. Sorry we couldn’t help.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Troubleshoot Terminal launch failures - Visual Studio Code
Try running your designated integrated terminal shell outside VS Code from an external terminal or command prompt. Some terminal launch failures may be...
Read more >
The new way to configure default shell and argument ...
"terminal.integrated.defaultProfile.windows": "Command Prompt",. We can achieve this by pressing Ctrl + Shift + P and searching for Terminal ...
Read more >
Manage Workspace Shell Permissions" In Command Palette
Launch the VS code app then press "Ctrl+`" to open a terminal. ... terminal.integrated.shell.windows' of workspace is ignored by python launcher #11107.
Read more >
Python in VSCode: Running and Debugging
How to use Python in VSCode. Learn how to run and debug your code, use VSCode with a Python virtualenv, and select the...
Read more >
How to use Python's py launcher for Windows - InfoWorld
Take control of multiple Python installations in Windows with the py launcher, available as part of a standard Python installation.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found