Change:
Hi - I am getting error messages when installing any extension on a remote Linux server. The remote server is very restricted and I don't have access except for my home folder. However, for some reason VSCode is trying to use a temp folder that I don't have access to. I am not sure how VSCode pciked up this folder. I can't find any reference to it anywhere in the configurations. I would like to know if there is a setting where I can change the temp folder. Below is the error: [2022-07-29 12:22:07.755] [renderer1] [warning] Settings pattern "keyboard." doesn't match any settings [2022-07-29 12:22:09.191] [renderer1] [warning] Settings pattern "keyboard." doesn't match any settings [2022-07-29 12:22:09.514] [renderer1] [info] [attempt 1] Invoking resolveAuthority(ssh-remote) [2022-07-29 12:22:18.740] [renderer1] [error] [Extension Host] (node:) [DEP0005] DeprecationWarning: Buffer() is deprecated due to security and usability issues. Please use the (), Buffer.allocUnsafe(), or () methods instead. (Use to show where the warning was created) [2022-07-29 12:22:18.762] [renderer1] [info] [attempt 1] resolveAuthority(ssh-remote) returned '127.0.0.1:' after 9248 ms [2022-07-29 12:22:20.133] [renderer1] [warning] Settings pattern "keyboard." doesn't match any settings [2022-07-29 12:22:21.184] [renderer1] [warning] Settings pattern "keyboard." doesn't match any settings [2022-07-29 12:22:24.061] [renderer1] [warning] Settings pattern "keyboard." doesn't match any settings [2022-07-29 12:22:59.505] [renderer1] [warning] Settings pattern "keyboard." doesn't match any settings [2022-07-29 12:23:00.832] [renderer1] [info] Setting search error: Unexpected end of JSON input [2022-07-29 12:23:00.858] [renderer1] [info] Setting search error: Unexpected end of JSON input [2022-07-29 12:23:35.530] [renderer1] [error] Error while installing '' extension in the remote server. unable to get local issuer certificate [2022-07-29 12:23:35.531] [renderer1] [info] Downloading the '' extension locally and install [2022-07-29 12:23:36.173] [renderer1] [info] Downloaded extension: /c:/Users/cn188966/AppData/Local/Temp/-8335-4d43-86c5- [2022-07-29 12:23:36.815] [renderer1] [error] ["NoPermissions (FileSystemError): Error: EACCES: permission denied, open '/infashared/td/Temp/fwa/-63b5-4cca-adab-'"," at f ()"," at i.toFileSystemProviderError ()"," at i.toFileSystemProviderWriteError ()"," at i.open ()"] [2022-07-29 12:23:36.829] [renderer1] [error] ["NoPermissions (FileSystemError): Error: EACCES: permission denied, open '/infashared/td/Temp/fwa/-63b5-4cca-adab-'"," at f ()"," at i.toFileSystemProviderError ()"," at i.toFileSystemProviderWriteError ()"," at i.open ()"] [2022-07-29 12:23:36.864] [renderer1] [error] Error: EACCES: permission denied, open '/infashared/td/Temp/fwa/-63b5-4cca-adab-': NoPermissions (FileSystemError): Error: EACCES: permission denied, open '/infashared/td/Temp/fwa/-63b5-4cca-adab-' at f () at i.toFileSystemProviderError () at i.toFileSystemProviderWriteError () at i.open () [2022-07-29 12:27:51.400] [renderer1] [error] Error while installing '' extension in the remote server. unable to get local issuer certificate [2022-07-29 12:27:51.400] [renderer1] [info] Downloading the '' extension locally and install [2022-07-29 12:27:52.319] [renderer1] [info] Downloaded extension: /c:/Users/cn188966/AppData/Local/Temp/-f465-449f-946e- [2022-07-29 12:27:52.954] [renderer1] [error] ["NoPermissions (FileSystemError): Error: EACCES: permission denied, open '/infashared/td/Temp/fwa/-5550-438e-8c7a-'"," at f ()"," at i.toFileSystemProviderError ()"," at i.toFileSystemProviderWriteError ()"," at i.open ()"] [2022-07-29 12:27:52.985] [renderer1] [error] ["NoPermissions (FileSystemError): Error: EACCES: permission denied, open '/infashared/td/Temp/fwa/-5550-438e-8c7a-'"," at f ()"," at i.toFileSystemProviderError ()"," at i.toFileSystemProviderWriteError ()"," at i.open ()"] [2022-07-29 12:27:53.024] [renderer1] [error] Error: EACCES: permission denied, open '/infashared/td/Temp/fwa/-5550-438e-8c7a-': NoPermissions (FileSystemError): Error: EACCES: permission denied, open '/infashared/td/Temp/fwa/-5550-438e-8c7a-' at f () at i.toFileSystemProviderError () at i.toFileSystemProviderWriteError () at i.open ()
Hello - I am new to github. Could you please me know what is the resolution for this? What do I need to do? Thank you, Raj
This is fixed in our main branch and the fix will be available in following releases VS Code Insiders in the end of this week or beginning of this week VS Code Stable in the end of the this month (1.71.0) release
Thank you so much for your response. I updated VS Code to the latest insiders edition and now the extension installed successfully.
<!-- AUTHORVERIFICATIONREQUEST --This bug has been fixed in the latest release of ! you can help us out by commenting if things are now working as expected. If things still don't seem right, please ensure you're on version of Insiders (today's or later - you can use in the command palette to check), and leave a comment letting us know what isn't working as expected. Happy Coding!
This fix is now available in latest insiders. Can you please test if it works and tag it as verified?
Hello - I did update almost a week ago that it is working. I have verified that it is working. However, I don't know how to mark it as fixed. Thanks, Raj
you can comment to mark it verified
/verified

Discussion:
export class ExtensionsDownloader extends Disposable { <del> private readonly extensionsDownloadDir: URI; </del> <ins> readonly extensionsDownloadDir: URI; </ins> private readonly cache: number; private readonly cleanUpPromise: Promise<void>;

@IExtensionGalleryService galleryService: IExtensionGalleryService, @ITelemetryService telemetryService: ITelemetryService, @ILogService logService: ILogService, <del> @INativeEnvironmentService private readonly environmentService: INativeEnvironmentService, </del> <ins> @INativeEnvironmentService environmentService: INativeEnvironmentService, </ins> @IExtensionsScannerService private readonly extensionsScannerService: IExtensionsScannerService, @IExtensionsProfileScannerService private readonly extensionsProfileScannerService: IExtensionsProfileScannerService, @IDownloadService private downloadService: IDownloadService,

async zip(extension: ILocalExtension): Promise<URI> { this.logService.trace('ExtensionManagementService#zip', extension.identifier.id); const files = await this.collectFiles(extension); <del> const location = await zip(joinPath(this.environmentService.tmpDir, generateUuid()).fsPath, files); </del> <ins> const location = await zip(joinPath(this.extensionsDownloader.extensionsDownloadDir, generateUuid()).fsPath, files); </ins> return URI.file(location); }

} async getManifest(vsix: URI): Promise<IExtensionManifest> { <del> const downloadLocation = await this.downloadVsix(vsix); const zipPath = path.resolve(downloadLocation.fsPath); return getManifest(zipPath); </del> <ins> const { location, cleanup } = await this.downloadVsix(vsix); const zipPath = path.resolve(location.fsPath); try { return await getManifest(zipPath); } finally { await cleanup(); } </ins> } getInstalled(type?: ExtensionType, profileLocation?: URI): Promise<ILocalExtension[]> {

async install(vsix: URI, options: ServerInstallVSIXOptions = {}): Promise<ILocalExtension> { this.logService.trace('ExtensionManagementService#install', vsix.toString()); <del> const downloadLocation = await this.downloadVsix(vsix); const manifest = await getManifest(path.resolve(downloadLocation.fsPath)); if (manifest.engines && manifest.engines.vscode && !isEngineValid(manifest.engines.vscode, this.productService.version, this.productService.date)) { throw new Error(nls.localize('incompatible', "Unable to install extension '{0}' as it is not compatible with VS Code '{1}'.", getGalleryExtensionId(manifest.publisher, manifest.name), this.productService.version)); } </del> <ins> const { location, cleanup } = await this.downloadVsix(vsix); try { const manifest = await getManifest(path.resolve(location.fsPath)); if (manifest.engines && manifest.engines.vscode && !isEngineValid(manifest.engines.vscode, this.productService.version, this.productService.date)) { throw new Error(nls.localize('incompatible', "Unable to install extension '{0}' as it is not compatible with VS Code '{1}'.", getGalleryExtensionId(manifest.publisher, manifest.name), this.productService.version)); } </ins> <del> return this.installExtension(manifest, downloadLocation, options); </del> <ins> return await this.installExtension(manifest, location, options); } finally { await cleanup(); } </ins> } getMetadata(extension: ILocalExtension): Promise<Metadata | undefined> {

return this.extensionsScanner.cleanUp(removeOutdated); } <del> private async downloadVsix(vsix: URI): Promise<URI> { </del> <ins> private async downloadVsix(vsix: URI): Promise<{ location: URI; cleanup: () => Promise<void> }> { </ins> if (vsix.scheme === Schemas.file) { <del> return vsix; </del> <ins> return { location: vsix, async cleanup() { } }; </ins> } <del> const downloadedLocation = joinPath(this.environmentService.tmpDir, generateUuid()); await this.downloadService.download(vsix, downloadedLocation); return downloadedLocation; </del> <ins> this.logService.trace('Downloading extension from', vsix.toString()); const location = joinPath(this.extensionsDownloader.extensionsDownloadDir, generateUuid()); await this.downloadService.download(vsix, location); this.logService.info('Downloaded extension to', location.toString()); const cleanup = async () => { try { await this.fileService.del(location); } catch (error) { this.logService.error(error); } }; return { location, cleanup }; </ins> } protected doCreateInstallExtensionTask(manifest: IExtensionManifest, extension: URI | IGalleryExtension, options: ServerInstallOptions & ServerInstallVSIXOptions): IInstallExtensionTask {