Temporary fix for Appwrite issue https://github.com/appwrite/appwrite/issues/1171
This commit is contained in:
parent
974691b538
commit
cf36de1ffb
4 changed files with 7 additions and 4 deletions
|
@ -6,6 +6,8 @@ Check [Keep a Changelog](http://keepachangelog.com/) for recommendations on how
|
|||
|
||||
## [Unreleased]
|
||||
|
||||
## [0.0.8] - 2021-5-21
|
||||
- Temp fix for Appwrite https://github.com/appwrite/appwrite/issues/1171
|
||||
|
||||
## [0.0.7] - 2021-5-14
|
||||
### Fixed
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
"name": "vscode-appwrite",
|
||||
"displayName": "Appwrite",
|
||||
"description": "Manage your Appwrite resources right from VS Code!",
|
||||
"version": "0.0.7",
|
||||
"version": "0.0.8",
|
||||
"engines": {
|
||||
"vscode": "^1.55.0"
|
||||
},
|
||||
|
|
|
@ -11,7 +11,7 @@ export class Health {
|
|||
/**
|
||||
* @returns The health of all Appwrite services.
|
||||
*/
|
||||
public async checkup(): Promise<AppwriteHealth> {
|
||||
public async checkup(): Promise<Partial<AppwriteHealth>> {
|
||||
return {
|
||||
HTTP: await this.health.get(),
|
||||
DB: await this.health.getDB(),
|
||||
|
@ -24,7 +24,7 @@ export class Health {
|
|||
QueueCertificates: await this.health.getQueueCertificates(),
|
||||
QueueFunctions: await this.health.getQueueFunctions(),
|
||||
StorageLocal: await this.health.getStorageLocal(),
|
||||
AntiVirus: await this.health.getAntiVirus(),
|
||||
// AntiVirus: await this.health.getAntiVirus(),
|
||||
};
|
||||
}
|
||||
}
|
||||
|
|
|
@ -35,12 +35,13 @@ export class HealthTreeItemProvider implements vscode.TreeDataProvider<vscode.Tr
|
|||
// get children for root
|
||||
if (element === undefined) {
|
||||
try {
|
||||
const health = await promiseWithTimeout<AppwriteHealth | undefined>(
|
||||
const health = await promiseWithTimeout<Partial<AppwriteHealth> | undefined>(
|
||||
10000,
|
||||
async () => {
|
||||
try {
|
||||
return await healthClient?.checkup();
|
||||
} catch (e) {
|
||||
ext.outputChannel?.append('Error: ' + e.message);
|
||||
vscode.window.showErrorMessage('Could not connect to Appwrite project');
|
||||
}
|
||||
},
|
||||
|
|
Loading…
Reference in a new issue