File tree Expand file tree Collapse file tree
src/application/backend/app/db Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -41,7 +41,7 @@ def get_db_credentials():
4141# Check if we're in testing/development mode or should use local database
4242environment = os .getenv ("ENVIRONMENT" , "production" ).lower ()
4343
44- if environment == " testing" :
44+ if environment in [ "development" , " testing"] :
4545 # Use SQLite for testing or local development
4646 print ("Using local SQLite database" )
4747 DATABASE_URL = os .getenv ("DATABASE_URL" , "sqlite:///./test.db" )
@@ -74,7 +74,7 @@ def get_db_credentials():
7474
7575# Export schema name for conditional use in models
7676# SQLite doesn't support schemas, so we only use it for PostgreSQL
77- SCHEMA_NAME = "production" if environment != " testing" else None
77+ SCHEMA_NAME = "production" if environment not in [ "development" , " testing"] else None
7878
7979
8080def get_db ():
You can’t perform that action at this time.
0 commit comments