skurnia001 / discord-dn-bot

As wise man once said, computer scientist makes a 5 minutes routine task into 5 hours of scripting.
MIT License
0 stars 0 forks source link

Add reminder to login for rewards #10

Closed skurnia001 closed 3 years ago

skurnia001 commented 3 years ago

@hanstananda bisa kasih requirements? Format, past data, dll

skurnia001 commented 3 years ago

Can use a scheduler to invoke the bot. Every certain time, it will check the DB for any event. If there is any, it will print the event in the discord. Else, it will either print no event or print nothing. Can see here for how to have scheduled message.

Adding event to DB is also through another command.

skurnia001 commented 3 years ago

Closed implemented in b3b32746492a68403100831fa8ff632b84676c61

skurnia001 commented 3 years ago
C:\Users\Steven\AppData\Local\Programs\Python\Python38\lib\asyncio\base_events.py:1860: RuntimeWarning: coroutine 'Command.__call__' was never awaited
  handle = None  # Needed to break cycles when an exception occurs.
RuntimeWarning: Enable tracemalloc to get the object allocation traceback

Error in APScheduler preventing Cron job to call respective function successfully.

skurnia001 commented 3 years ago

Fixed in ce1507fa42bae53953c1170457eb13bc2f01a5b3