File size: 1,129 Bytes
9f52946
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
e775565
9f52946
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
#!/usr/bin/env python3
"""
TubeMeta Telegram Bot Launcher
Run this script to start the Telegram bot that integrates with the MCP server.
"""

import asyncio
import sys
import logging
from telegram_bot import main

def setup_logging():
    """Setup logging configuration"""
    logging.basicConfig(
        level=logging.INFO,
        format='%(asctime)s - %(name)s - %(levelname)s - %(message)s',
        handlers=[
            logging.FileHandler('telegram_bot.log'),
            logging.StreamHandler(sys.stdout)
        ]
    )

if __name__ == "__main__":
    print("๐Ÿค– Starting TubeMeta Telegram Bot...")
    print("๐Ÿ“‹ Make sure your MCP server is running at: https://youtube-bot.tuttech.net")
    print("๐Ÿ“ฑ Bot username: @tubemeta_bot")
    print("๐Ÿ”— Bot link: https://t.me/tubemeta_bot")
    print("โน๏ธ  Press Ctrl+C to stop\n")
    
    setup_logging()
    
    try:
        asyncio.run(main())
    except KeyboardInterrupt:
        print("\n๐Ÿ›‘ Bot stopped by user")
    except Exception as e:
        print(f"โŒ Error starting bot: {e}")
        logging.error(f"Bot startup error: {e}")
        sys.exit(1)