Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Enable controlling shell expansion via "argsCanBeInterpretedByShell" #1001

Closed
roblourens opened this issue Aug 2, 2022 · 2 comments · Fixed by #1004
Closed

Enable controlling shell expansion via "argsCanBeInterpretedByShell" #1001

roblourens opened this issue Aug 2, 2022 · 2 comments · Fixed by #1004
Assignees
Labels
enhancement New feature or request

Comments

@roblourens
Copy link
Member

We now have the ability to let the user decide whether arguments passed to a debuggee in a terminal should be escaped for the shell. This is adopted in js-debug, microsoft/vscode-js-debug#1335, also see microsoft/vscode#149910, would love to see it adopted for python in August. In js-debug, the args property can be a string or an array of strings. If it's just a string, the args are not escaped. I can talk more about what it will take to adopt this if needed.

@karthiknadig karthiknadig transferred this issue from microsoft/vscode-python Aug 3, 2022
@int19h
Copy link
Contributor

int19h commented Aug 3, 2022

Unless there are any specific reasons to not do so, I think we should follow the pattern established by JS, so that configs are consistent across languages as much as possible. Implementing this in debugpy should be straightforward.

@int19h int19h added the enhancement New feature or request label Aug 3, 2022
@int19h int19h self-assigned this Aug 3, 2022
@int19h int19h changed the title Adopt argsCanBeInterpretedByShell for RunInTerminalRequest Enable controlling shell expansion via "argsCanBeInterpretedByShell" Aug 4, 2022
int19h pushed a commit to int19h/debugpy that referenced this issue Aug 4, 2022
…InterpretedByShell"

Fix microsoft#357: "argsExpansion" does not do what it says in VSCode

Treat non-array "args" in debug config as a request to prevent shell argument escaping and allow shell expansion.

Remove "argsExpansion".
@int19h int19h mentioned this issue Aug 4, 2022
@roblourens
Copy link
Member Author

Thanks for getting to this so quickly!

rchiodo pushed a commit to rchiodo/debugpy that referenced this issue Aug 5, 2022
…InterpretedByShell"

Fix microsoft#357: "argsExpansion" does not do what it says in VSCode

Treat non-array "args" in debug config as a request to prevent shell argument escaping and allow shell expansion.

Remove "argsExpansion".
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants