SupabaseS
Supabase3mo ago
xobzoo

PostgREST Schema Cache issue – `PGRST002`

I've been having problems with the REST API of one project.

I know the DB is still happy, because actual SQL queries work just fine (both in the browser and DBeaver).

The REST part is failing, though. At least mostly.
  • https://{{server}}/auth/v1/… works fine (sign in, sign out, current user info …/auth/v1/user)
  • https://{{server}}/rest/v1/… returns 503 Service Unavailable
The full error response:
{
  "code": "PGRST002",
  "details": null,
  "hint": null,
  "message": "Could not query the database for the schema cache. Retrying."
}


The PostgREST documentation says that error means
Could not connect with the database when building the Schema Cache due to the PostgreSQL service not running.

But SQL queries still work fine. (probably “the PostgreSQL service” is not what I think it sounds like)
Schema_Cache_Issueweb_UI_displayed_error.png
Was this page helpful?