harris-ferguson / duedatebot Goto Github PK
View Code? Open in Web Editor NEWA discord bot that can track due dates and send reminders.
A discord bot that can track due dates and send reminders.
Daily, Weekly, or Monthly Reminders of important upcoming dates!
Set a reminder to go off at a specific daily time
Set a reminder to go off once every set amount of days
Ping users for important upcoming dates if they have a role matching the class title
Ping @here in a channel matching the course ID
We need a command to change the due date of a given item.
We need a testing suite! pytest would be easy enough to get rolling. With my limited time and this projects small userbase (the use of this app is primarily 1 small school discord server), my priority is in building out features we need, but setting up testing is gunna be invaluable.
We should allow the user to upload a list of Assignment IDs for which they want to be reminded of. If nothing is provided then we give them a reminder for everything in the guild.
We need to check that the proper types are stored in the database. Most of what we store are just strings, however we particularly want to ensure that we are storing python datetime objects instead of a string. Assignment IDs should also be integers instead of strings.
We should store posts in chronological order, and possibly implement a sorter. This will help us do things like
Command will print the days until a specified assignment is due. It would be nice if we could invoke this with the name and title of the assignment but we might have to resort to using the assignment id.
Line 32 in ae17156
We should allow the user to include a time, while avoiding errors if they try to create an assignment without a due-time.
We should take the time to modularize the bot into some Classes using the Cog framework that discord.py provides.
We need a command to clear all the handins from a given document. It's important that is command ensures the handins field is not left empty, as referenced in this issue
the discord api allows us to get the date that the local server has, so we should change our method of getting the current day to use this to avoid bugs in several time related functions.
currently reminders only accept Days and Second (for testing), however we should also allow the user to enter Weeks and Months (and maybe years but im not sure who would use that).
This would involve expanding the following section of code:
Lines 204 to 208 in afb3270
Either we need to check for the first element being "None!" or we should come up with a new way to deal with the hand ins list to be empty (see) Either way we just need to be consistent about it.
Line 3 in 954f62e
this function will break if the field "handins" is empty. Although the function which creates new documents doesn't allow for this field to be empty, this function should be more robust to handle this.
We need a command that checks for everything due in a given week. Dates are stored as datetimes from the Python datetime module, so we can use the features of that to check if something is happening within the current week.
Since we have an event loop running for reminders, we could use the same event loop to check for anything in the assignments database that is past due. We could tie it to a boolean that the user can optionally set, just in case there is a desire to keep assignments for some time after they are due.
We should have a simple way of checking if we have a collision in the AssignmentID hash.
Currently reminders just trigger at a certain number of seconds after the user invoked the command, meaning entering 2 days at 11 will mean you get reminded 2 days later at 11. We should let the command invocation include a "time to remind at" field.
When printing an assingment using the @show command, the Due Today At message will display an incorrect due time. This is because due times are mixing up the second and minute fields.
We need a command that deletes an item. We should also write a function we can call that deletes anything that is past due.
None of the methods have docstrings, we should add them! Simple as that.
We should check through the database without checking for case-matching when looking for documents.
Get an assignment by its ID and print it out to the guild. This is also needed for some other setter/getter functions so we can immediately display any changes made.
Discords new update has a new Slash Command feature. We should support this feature so people can have an easier time navigating our commands. We need to register these slash commands with an HTTP request, see the above link.
We should abstract the behaviour of parsing a datetime to a helper method. Said method should be set up to use Regex and match multiple different formats of datetime to allow for easier usage.
Bulk Add an entire schedule from a csv file.
Ensure everything adding conforms with the type we store in the db. We could either invoke the existing adddate command to add everything or make use of pymongos insert_many command to do it all at once.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.