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