Skip to content

The Postgres development platform. Supabase gives you a dedicated Postgres database to build your web, mobile, and AI applications.

fix: refetch project detail while project is coming up (#20819)

Alaister Young026d7ee2f30d
diff --git a/apps/studio/data/projects/project-detail-query.ts b/apps/studio/data/projects/project-detail-query.ts
index fa9537f94af..659a2d37f30 100644
--- a/apps/studio/data/projects/project-detail-query.ts
+++ b/apps/studio/data/projects/project-detail-query.ts
@@ -44,6 +44,13 @@ export const useProjectDetailQuery = <TData = ProjectDetailData>(
{
enabled: enabled && typeof ref !== 'undefined',
staleTime: 30 * 1000, // 30 seconds
+ refetchInterval(data) {
+ if (data && (data as unknown as ProjectDetailData).status === 'COMING_UP') {
+ return 5 * 1000 // 5 seconds
+ }
+
+ return false
+ },
...options,
}
)