File tree Expand file tree Collapse file tree 1 file changed +5
-10
lines changed Expand file tree Collapse file tree 1 file changed +5
-10
lines changed Original file line number Diff line number Diff line change 1
1
from news_bot import BotTelegramNews
2
- from keys import TOKEN_API_TELEGRAM ,API_NEW_TOKEN
2
+ from keys import TOKEN_API_TELEGRAM ,API_NEW_TOKEN , CHANNEL_ID
3
3
import schedule
4
4
import time
5
5
6
6
7
7
8
8
9
9
if __name__ == '__main__' :
10
- bot = BotTelegramNews ('NewsBot' , TOKEN_API_TELEGRAM , API_NEW_TOKEN )
10
+ bot = BotTelegramNews ('NewsBot' , TOKEN_API_TELEGRAM , API_NEW_TOKEN , CHANNEL_ID )
11
11
bot .esperar_comando ("start" , bot .start )
12
12
bot .esperar_comando ("menu" , bot .menu_conf )
13
13
bot .contestar_consulta (bot .getNewMessage )
14
-
14
+
15
+ schedule .every (50 ).minutes .do (bot .sendSportNews )
15
16
schedule .every (1 ).hours .do (bot .backupAPI )
16
17
while True :
17
18
schedule .run_pending ()
18
- time .sleep (1 )
19
-
20
-
21
-
22
-
23
-
24
-
19
+ time .sleep (1 )
You can’t perform that action at this time.
0 commit comments