src/vs/workbench/contrib/remote/common/remote.contribution.ts/RemoteInvalidWorkspaceDetector/validateRemoteWorkspace
class RemoteInvalidWorkspaceDetector:	private async validateRemoteWorkspace(): Promise<void> {
		const workspace = this.contextService.getWorkspace();
		const workspaceUriToStat = workspace.configuration ?? firstOrDefault(workspace.folders)?.uri;
		if (!workspaceUriToStat) {
			return; // only when in workspace
		}

		const exists = await this.fileService.exists(workspaceUriToStat);
		if (exists) {
			return; // all good!
		}

		const res = await this.dialogService.confirm({
			type: 'warning',
			message: localize('invalidWorkspaceMessage', "Workspace does not exist"),
			detail: localize('invalidWorkspaceDetail', "The workspace does not exist. Please select another workspace to open."),
			primaryButton: localize('invalidWorkspacePrimary', "&&Open Workspace..."),
			secondaryButton: localize('invalidWorkspaceCancel', "&&Cancel")
		});

		if (res.confirmed) {

			// Pick Workspace
			if (workspace.configuration) {
				return this.fileDialogService.pickWorkspaceAndOpen({});
			}

			// Pick Folder
			return this.fileDialogService.pickFolderAndOpen({});
		}
	}