Add remaining database name prefix changes

This commit is contained in:
nolash
2021-11-10 09:55:30 +01:00
parent 140b72a72b
commit 995d4e0bd0
4 changed files with 5 additions and 3 deletions

View File

@@ -9,6 +9,7 @@ from .list import (
tag_transaction,
add_tag,
)
from cic_cache.db.models.base import SessionBase
logg = logging.getLogger()
@@ -24,6 +25,7 @@ def dsn_from_config(config, name):
database_name = '{}_{}'.format(config.get('DATABASE_PREFIX'), database_name)
dsn = ''
if config.get('DATABASE_ENGINE') == 'sqlite':
SessionBase.poolable = False
dsn = '{}:///{}'.format(
scheme,
database_name,