Skip to content

Commit 71f356d

Browse files
authored
Quote arguments systematically when calling conda (#121)
Moved quoting conda arguments to `runConda` to systematically handle paths with spaces (related to #113)
1 parent 48c24bf commit 71f356d

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/managers/conda/condaUtils.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -143,6 +143,7 @@ async function runConda(args: string[], token?: CancellationToken): Promise<stri
143143
const conda = await getConda();
144144

145145
const deferred = createDeferred<string>();
146+
args = quoteArgs(args);
146147
const proc = ch.spawn(conda, args, { shell: true });
147148

148149
token?.onCancellationRequested(() => {
@@ -586,7 +587,7 @@ async function createPrefixCondaEnvironment(
586587
}
587588

588589
export async function deleteCondaEnvironment(environment: PythonEnvironment, log: LogOutputChannel): Promise<boolean> {
589-
let args = quoteArgs(['env', 'remove', '--yes', '--prefix', environment.environmentPath.fsPath]);
590+
let args = ['env', 'remove', '--yes', '--prefix', environment.environmentPath.fsPath];
590591
return await withProgress(
591592
{
592593
location: ProgressLocation.Notification,

0 commit comments

Comments
 (0)