Taskord
About
Taskord ("task" + "discord") is a Discord task management bot we wrote in Kotlin. We used Exposed to connect to a MySQL database which allowed persistence across runs.
Motivation
Taskord is inspired by the lack of a streamlined task management system for organizations that communicate on Discord. Particularly, one of the developers, a student organization leader at UTD, added requirements that would streamline the task delegation process in his organization: in just one place the bot would allow him to create and assign tasks to users, view an auto-updating list of tasks organized by officer and deadline, set up automated reminders that would PM the officers, and get notifications from a master log that would notify him whenever officers completed tasks or were nearing a deadline.
What we learned
From this project, we learned how to use a bunch of new tools: for instance, we strengthened our competencies in MySQL and especially JetBrains's Exposed library. Moreover, we learned the internals of creating a bot, including the workflow of queued actions and callback chains. In addition, we greatly improved our familiarity with the Kotlin language, including the use of dependency managers like Maven as well as the syntax of Kotlin's lambda expressions.
Challenges
One mysterious challenge we faced was that after every few minutes of running the bot, restarting the bot would cause an exception stating the bot token was invalid. Strangely, when we checked the bot developer portal, we saw the bot token had changed by itself. Several times we would copy the new token and update our code only for it to eventually fail again. After researching this issue, we had found the root cause: at this stage, for simplicity, we had included our bot token directly in our main method. Discord had found our repository and would reset our token each time we pushed. Fortunately, the fix was simple: we refactored our API token and MySQL login to a secrets.kt file which we added to the .gitignore and shared manually.
Built With
- exposed
- jda
- kotlin
- kutils
- mysql
Log in or sign up for Devpost to join the conversation.