Skip to content

Commit f4e2736

Browse files
committed
undo fs changes
1 parent b2a4734 commit f4e2736

File tree

1 file changed

+1
-15
lines changed
  • packages/core/src/shared/fs

1 file changed

+1
-15
lines changed

packages/core/src/shared/fs/fs.ts

Lines changed: 1 addition & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -304,12 +304,6 @@ export class FileSystem {
304304
}
305305

306306
await write(uri)
307-
if (isWin()) {
308-
const success = await waitUntil(async () => await fs.exists(uri), { timeout: 5000, truthy: true })
309-
if (!success) {
310-
throw new ToolkitError(`Failed to write file ${uri.toString()}`)
311-
}
312-
}
313307
}
314308

315309
/**
@@ -434,7 +428,7 @@ export class FileSystem {
434428
})
435429
}
436430

437-
vfs.delete(uri, opt).then(undefined, async (err) => {
431+
return vfs.delete(uri, opt).then(undefined, async (err) => {
438432
const notFound = isFileNotFoundError(err)
439433

440434
if (notFound && opt.force) {
@@ -467,14 +461,6 @@ export class FileSystem {
467461

468462
throw err
469463
})
470-
471-
// Windows race condition
472-
if (isWin()) {
473-
const success = await waitUntil(async () => !(await fs.exists(fileOrDir)), { timeout: 5000, truthy: true })
474-
if (!success) {
475-
throw new ToolkitError(`Failed to delete file ${uri.toString()}`)
476-
}
477-
}
478464
}
479465

480466
async readdir(uri: vscode.Uri | string): Promise<[string, vscode.FileType][]> {

0 commit comments

Comments
 (0)