-
Notifications
You must be signed in to change notification settings - Fork 24
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
Tasks with -c in args get mangled (was: deprecated parameters in settings.json) #11
Comments
I don't think the error is related to the deprecation. Can you give reproduction instructions for the error - is this with https://marketplace.visualstudio.com/items?itemName=ms-azuretools.vscode-azurefunctions ? It's not obvious to me why/how the terminal arguments would be manipulated to produce an error like that. |
For some background the capsh invocation is to avoid problems because the user's UID is actually effectively root in the container and gets root like capabilities - in particular cap_dac_override, which means that it completely overrides file permissions. The error is likely caused by some dodgy code in Visual Studio Code: // Set shellArgs to the value from the config
// Set toAdd to ['-c']
toAdd.forEach(element => {
if (!shellArgs.some(arg => arg.toLowerCase() === element)) {
shellArgs.push(element);
}
});
shellArgs.push(commandLine); Because
ends up as:
I can't see any way that skipping -c could ever produce the right result. So, I think there's a Visual Studio code bug here. This part of the code was added as part of a larger commit, so it's not clear what the intent is - a pretty safe change would be to limit the the skipping to the Windows case, though I doubt it is correct in this case either. I don't know a great workaround here - one thing we could do is set "terminal.integrated.automationShell.linux" to bash - we'd still have funky capabilities in the automated task case, which could be confusing, but the scope would be limited. |
Filed a vscode issue - microsoft/vscode#136459 - will need a workaround here however. |
https://github.com/owtaylor/toolbox-vscode/blob/main/code.sh#L371-L381
Also, these parameters causing errors for some tasks.
Example:
The text was updated successfully, but these errors were encountered: