2022-08-31 10:20:49 +00:00
|
|
|
from src import listener_context, listener_mention, imdb_datasets_worker
|
|
|
|
from config import logger_default_level
|
2022-09-06 23:55:12 +00:00
|
|
|
from loguru import logger
|
2022-09-03 15:42:13 +00:00
|
|
|
import time
|
2022-09-06 23:55:12 +00:00
|
|
|
import sys
|
2022-08-31 10:20:49 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
def main():
|
2022-09-06 23:55:12 +00:00
|
|
|
logger.remove()
|
|
|
|
logger.add(sink=sys.stderr, level=logger_default_level)
|
2022-09-12 14:41:31 +00:00
|
|
|
logger.add(sink='suggestions.log', level='INFO', filter='src.listener_context')
|
2022-08-31 10:20:49 +00:00
|
|
|
|
2022-09-01 13:17:36 +00:00
|
|
|
listener_mention.run_scan_notif() # Слушаем упоминания в фоне
|
2022-09-03 15:42:13 +00:00
|
|
|
time.sleep(1)
|
2022-08-31 10:20:49 +00:00
|
|
|
|
|
|
|
listener_context.scan_context_thread() # Слушаем тред на новые предложения фильмов
|
|
|
|
|
|
|
|
if __name__ == '__main__':
|
|
|
|
main()
|