core/services/main.py
2023-10-27 00:07:35 +03:00

14 lines
455 B
Python

from services.search import SearchService
from services.stat.viewed import ViewedStorage
from base.orm import local_session
async def storages_init():
with local_session() as session:
print('[main] initialize SearchService')
await SearchService.init(session)
print('[main] SearchService initialized')
print('[main] initialize storages')
await ViewedStorage.init()
print('[main] storages initialized')