Skip to main content

File Structure

This is what the project will look like at its parent folder level (top level).

  1. main.py:
  • This is the core file of the Discord bot where the main functionality is implemented.
  • It initializes the bot, loads the different cogs (modules), and handles events.
  • Team members are not required to modify this file, allowing the functionality to remain stable as they develop features in their own cogs and helper functions.
  1. cogs/my_cog.py:
  • This file is designated for specific features or commands that can be added to the bot.
  • Team members can design their own cogs by defining classes here, which inherit from the base classes provided by Discord.py.
  • This modular approach enables each member to work on their features independently.
  1. utils/:
  • This where we will store source files which aid cog functionality. Within this directory, there is also a helpers.py file that houses generic functions available to all cogs.
  1. utils/helpers.py:
  • This file is intended to contain utility functions that can be used across different modules of the bot.
  • Team members can develop functions that perform specific tasks and can be used in their cogs, promoting code reusability.
  1. cache/:
  • This folder is used to store sub-folders containing cache files for the bot.
  1. config/:
  • This folder is used to store configuration files for the bot/cogs.


\