UI Error: Connection Closed After Periods of Inactivity
I've seen error in UI like attached multiple times, it appears to only happen after no activity for a while, and would go away if I refresh the page. The server side error is like
self._adapt_connection.await_(
File "/phoenix/env/sqlalchemy/util/_concurrency_py3k.py", line 132, in await_only
return current.parent.switch(awaitable) # type: ignore[no-any-return,attr-defined] # noqa: E501
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/phoenix/env/sqlalchemy/util/_concurrency_py3k.py", line 196, in greenlet_spawn
value = await result
^^^^^^^^^^^^
File "/phoenix/env/sqlalchemy/dialects/postgresql/asyncpg.py", line 515, in _prepare_and_execute
await adapt_connection._start_transaction()
File "/phoenix/env/sqlalchemy/dialects/postgresql/asyncpg.py", line 845, in _start_transaction
self._handle_exception(error)
File "/phoenix/env/sqlalchemy/dialects/postgresql/asyncpg.py", line 792, in _handle_exception
raise translated_error from error
sqlalchemy.exc.InterfaceError: (sqlalchemy.dialects.postgresql.asyncpg.InterfaceError) <class 'asyncpg.exceptions._base.InterfaceError'>: connection is closed
[SQL: SELECT traces.project_rowid, traces.trace_id, traces.project_session_rowid, traces.start_time, traces.end_time, traces.id
FROM traces
LIMIT $1::INTEGER]
[parameters: (1,)]any idea how to prevent such error?
