mirror of
https://github.com/danswer-ai/danswer.git
synced 2025-03-26 17:51:54 +01:00
Fix sync DB engine (#32)
This commit is contained in:
parent
20b25e322f
commit
da8031c1aa
@ -10,6 +10,7 @@ from sqlalchemy.ext.asyncio import create_async_engine
|
||||
from sqlalchemy.orm import Session
|
||||
|
||||
|
||||
SYNC_DB_API = "psycopg2"
|
||||
ASYNC_DB_API = "asyncpg"
|
||||
# below are intended to match the env variables names used by the official
|
||||
# postgres docker image https://hub.docker.com/_/postgres
|
||||
@ -33,7 +34,7 @@ def build_connection_string(
|
||||
|
||||
|
||||
def build_engine() -> Engine:
|
||||
connection_string = build_connection_string()
|
||||
connection_string = build_connection_string(db_api=SYNC_DB_API)
|
||||
return create_engine(connection_string)
|
||||
|
||||
|
||||
|
@ -14,6 +14,8 @@ httpx-oauth==0.11.2
|
||||
Mako==1.2.4
|
||||
openai==0.27.6
|
||||
playwright==1.32.1
|
||||
psycopg2==2.9.6
|
||||
psycopg2-binary==2.9.6
|
||||
pydantic==1.10.7
|
||||
PyGithub==1.58.2
|
||||
PyPDF2==3.0.1
|
||||
|
Loading…
x
Reference in New Issue
Block a user