Skip to content

Releases: kkrypt0nn/Python-Discord-Bot-Template

Version 3.1.1

16 Nov 14:48
Compare
Choose a tag to compare
  • Fixed TypeError: 'NoneType' object is not iterable for prefix -> Python 3.10

Version 3.1

15 Nov 08:50
Compare
Choose a tag to compare

Changes:

  • Added a @checks.is_owner check which raises a UserNotOwner exception
  • Added a @checks.not_blacklisted check which raises a UserBlacklisted exception
  • Using checks instead of same code for every command
  • Various code cleanup

What's new is mostly the ability to use checks instead of code for checking if, for example, the user trying to execute the command is not an owner.

Before: (Blacklist check, had to be copied on every command)

@cog_ext.cog_slash(
  name="ping",
  description="Check if the bot is alive.",
)
async def ping(self, context: SlashContext):
  with open("blacklist.json") as file:
    blacklist = json.load(file)
  if context.author.id in blacklist["ids"]:
    return
  # Rest of the code

Now:

@cog_ext.cog_slash(
  name="ping",
  description="Check if the bot is alive.",
)
@checks.not_blacklisted() # Here is the difference
async def ping(self, context: SlashContext):
  # Rest of the code

Version 3.0

12 Sep 10:42
Compare
Choose a tag to compare

Now using slash commands

Version 2.8

19 Jun 16:22
Compare
Choose a tag to compare
  • Blacklisted users are now saved in the file
  • Moved config file to JSON
  • Moved the blacklist in a separate file (blacklist.json)
  • The colors are no longer saved in the config file

Version 2.7

09 Jun 17:31
Compare
Choose a tag to compare
  • Added a check for commands.MissingRequiredArgument in the error handler
  • Added a disclaimer section in the README file
  • Added the latency of the bot in the ping command
  • Created the TODO list file
  • Fixed some error embeds having success (green) colors
  • Removed an unnecessary self.bot.logout() statement
  • Removed the dick command, as I want to keep this template safe for work
  • Renamed the names of the arguments in some commands
  • The bot now tries to send an embed in the private message of the command author for the invite and server commands, if this was not successful it will be sent in the channel

Version 2.6

01 Jun 15:41
Compare
Choose a tag to compare
  • Added new dailyfact command that gives a random fact every day, using cool down
  • Fixed some typos in README.md
  • Remade the on_command_error event for CommandOnCooldown

Version 2.5

02 May 13:23
Compare
Choose a tag to compare
  • Code reformat
  • Rewrote the status task
  • Now using the has_permissions decorator for user permissions
  • Using .yaml instead of .py file for config

Version 2.4.3

30 Mar 18:00
Compare
Choose a tag to compare
  • Fixed intents for serverinfo command

Version 2.4.2

22 Mar 20:17
Compare
Choose a tag to compare
  • Blacklisted users are being ignored when executing a command

Version 2.4.1

22 Mar 20:06
Compare
Choose a tag to compare
  • Added config import to moderation cog