-
Notifications
You must be signed in to change notification settings - Fork 3
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add logger #48
Merged
Merged
Add logger #48
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Current dependencies on/for this PR:
This stack of pull requests is managed by Graphite. |
This was referenced Nov 1, 2023
Merged
Merged
akotadi
changed the base branch from
akotadi/remove-local-database
to
develop
November 8, 2023 04:59
akotadi
force-pushed
the
akotadi/add-logger
branch
from
November 8, 2023 05:01
a5f36d0
to
66fe596
Compare
akotadi
added a commit
that referenced
this pull request
Dec 29, 2023
# Description ### Context In order to improve the system we'll go back to using a database that can be accessed easily from different places. The previous Sqlite3 database will be used just as "cache" on the bot, while MongoDB will be set up to be used widely. ### This diff * Add and configure a basic logger on the bot ### Incoming diffs * Add logger to track the interaction with the database * Configure the bot to work with MongoDB * Add handler to interact with the database * Add Guild Model again on MongoDB # Type of change - [ ] Bug fix (non-breaking change which fixes an issue) - [x] New feature (non-breaking change which adds functionality) - [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected) - [ ] Documentation update # How Has This Been Tested? Locally tested to see that is working fine # Checklist: - [x] I have commented my code, particularly in hard-to-understand areas - [x] My changes generate no new warnings - [ ] I have added tests that prove my fix is effective or that my feature works
akotadi
added a commit
that referenced
this pull request
Dec 29, 2023
# Description ### Context In order to improve the system we'll go back to using a database that can be accessed easily from different places. The previous Sqlite3 database will be used just as "cache" on the bot, while MongoDB will be set up to be used widely. ### This diff * Add and configure a basic logger on the bot ### Incoming diffs * Add logger to track the interaction with the database * Configure the bot to work with MongoDB * Add handler to interact with the database * Add Guild Model again on MongoDB # Type of change - [ ] Bug fix (non-breaking change which fixes an issue) - [x] New feature (non-breaking change which adds functionality) - [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected) - [ ] Documentation update # How Has This Been Tested? Locally tested to see that is working fine # Checklist: - [x] I have commented my code, particularly in hard-to-understand areas - [x] My changes generate no new warnings - [ ] I have added tests that prove my fix is effective or that my feature works
akotadi
added a commit
that referenced
this pull request
Dec 30, 2023
* Add poetry skeleton * Add precommit file config * Add discord as dependency * Add tox configuration files and pass precommit * Change the author of the project * GitHub actions (#2) Create build using github action * Bot skeleton (#4) * Add dummy commit to test GH * Change name of precommit file * Add dummy skeleton to test build * Add Dockerfile * Add production github action * Add author to dockerfile * Fix docker file not getting image in FROM (#5) * Docker file fix v2 (#6) Fix problem with name in the registry * Add PR template file (#7) * Add PR template file * Change semantic of type of change * Add documentation as option * Rename az registries information (#8) * Rename az registries information * Rename pull request template * Rename PR template * React with reaction (#9) * Test PR template * Update version of discordpy dependency * Initial architecture of bot * Change tox and preconfig files * Test build * Add cog automatical registration * Add discord token as secure env var * Test no cog registration (#10) * Fix problem with relative path (#11) * Fix linter config (#14) * Unit test and documentation for blueprint bot (#12) * Add unit test for intent registration * Add unit testing for startup * Add test for startup cogs * Create unit testing for formatters * Update constants.py Co-Authored-By: Manuel CH <26100917+akotadi@users.noreply.github.com> * Test precommit * Create unit testing for formatters * Add Readme * Fix typo in readme * Ignore rule to avoid unneccesary comments * Delete unnecesary comments * Move fixture to conftest Co-authored-by: Manuel CH <26100917+akotadi@users.noreply.github.com> * Add initial base for timeline (#15) * Add initial base for timeline * Add unit testing for hiring formatter * Add cron testing * Add unit testing for cog * Change formatter access * Migrate cron to enum * Add annoucement channel as secret for deployment * Add start stop cron schedule * Missing root folder name was failing deploy to Azure (#16) * Debug state * Change to PR * Add analytics to container * Add cogs again * Remove path * Enable cogs again * Test * Rename Docker root file * Add module parameter to Dockerfile * Add complete path * Uncomment cogs * Comment hiring * Add logg * Test * Add complete path to cogs * Put release again on merge * Fix tox passing failing tests * Fix tox * Change tox * FIx tox * Tox should trigger * Skip update dependency * Delete install * Add pytest * Return pytest * Test should fail * Change test to build * Uncomment test cog * Revert push to prod to merge * Prepare deploy with different envs * Test dev deploy * Test secrets * Add env vars for deploy * Fix if * Split dev and prod * Comment test phase * Disable beta command (#18) * Comment beta command * Modify tests * Add logging decorator (#20) * Add logging decorator * Test log in az dev * Test in developent environment * Change policy (#23) * Change policy * Disable push in pull request * Fix lintern problems * Comment logger (#26) * Enable Logging (#24) * Add poetry skeleton * Add precommit file config * Add discord as dependency * Add tox configuration files and pass precommit * Change the author of the project * GitHub actions (#2) Create build using github action * Bot skeleton (#4) * Add dummy commit to test GH * Change name of precommit file * Add dummy skeleton to test build * Add Dockerfile * Add production github action * Add author to dockerfile * Fix docker file not getting image in FROM (#5) * Docker file fix v2 (#6) Fix problem with name in the registry * Add PR template file (#7) * Add PR template file * Change semantic of type of change * Add documentation as option * Rename az registries information (#8) * Rename az registries information * Rename pull request template * Rename PR template * React with reaction (#9) * Test PR template * Update version of discordpy dependency * Initial architecture of bot * Change tox and preconfig files * Test build * Add cog automatical registration * Add discord token as secure env var * Test no cog registration (#10) * Fix problem with relative path (#11) * Fix linter config (#14) * Unit test and documentation for blueprint bot (#12) * Add unit test for intent registration * Add unit testing for startup * Add test for startup cogs * Create unit testing for formatters * Update constants.py Co-Authored-By: Manuel CH <26100917+akotadi@users.noreply.github.com> * Test precommit * Create unit testing for formatters * Add Readme * Fix typo in readme * Ignore rule to avoid unneccesary comments * Delete unnecesary comments * Move fixture to conftest Co-authored-by: Manuel CH <26100917+akotadi@users.noreply.github.com> * Add initial base for timeline (#15) * Add initial base for timeline * Add unit testing for hiring formatter * Add cron testing * Add unit testing for cog * Change formatter access * Migrate cron to enum * Add annoucement channel as secret for deployment * Add start stop cron schedule * Missing root folder name was failing deploy to Azure (#16) * Debug state * Change to PR * Add analytics to container * Add cogs again * Remove path * Enable cogs again * Test * Rename Docker root file * Add module parameter to Dockerfile * Add complete path * Uncomment cogs * Comment hiring * Add logg * Test * Add complete path to cogs * Put release again on merge * Fix tox passing failing tests * Fix tox * Change tox * FIx tox * Tox should trigger * Skip update dependency * Delete install * Add pytest * Return pytest * Test should fail * Change test to build * Uncomment test cog * Revert push to prod to merge * Prepare deploy with different envs * Test dev deploy * Test secrets * Add env vars for deploy * Fix if * Split dev and prod * Comment test phase * Disable beta command (#18) * Comment beta command * Modify tests * Add logging decorator (#20) * Add logging decorator * Test log in az dev * Test in developent environment * Change policy (#23) * Change policy * Disable push in pull request * Fix lintern problems Co-authored-by: Manuel CH <26100917+akotadi@users.noreply.github.com> * Comment logger --------- Co-authored-by: Manuel CH <26100917+akotadi@users.noreply.github.com> * Akotadi/update common rules (#25) * Update pre-commit and fix issues * Fix issues * Remove eof * Update pre-commit and address comments * Add readme env variables * Linter * Add documentation for command * Disable logging (#32) * Add reaction check handler (#29) * Update pre-commit and fix issues * Fix issues * Remove eof * Update pre-commit and address comments * Add readme env variables * Linter * Add role when react to welcome message * Update readme * Add tests * Add test * Update description * Address comments * Update pytest version * Create settings file * Add comment * Add orm with guild checks (#34) * Remove local database (#47) # Description ### Context In order to improve the system we'll go back to using a database that can be accessed easily from different places. The previous Sqlite3 database will be used just as "cache" on the bot, while MongoDB will be set up to be used widely. ### This diff * Remove the previous local database and let it as local cache ### Incoming diffs * Add logger to track the interaction with the database * Configure the bot to work with MongoDB * Add handler to interact with the database * Add Guild Model again on MongoDB # Type of change - [ ] Bug fix (non-breaking change which fixes an issue) - [x] New feature (non-breaking change which adds functionality) - [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected) - [ ] Documentation update # How Has This Been Tested? Locally run to be sure that is still working fine # Checklist: - [x] I have commented my code, particularly in hard-to-understand areas - [x] My changes generate no new warnings - [ ] I have added tests that prove my fix is effective or that my feature works * Add logger (#48) # Description ### Context In order to improve the system we'll go back to using a database that can be accessed easily from different places. The previous Sqlite3 database will be used just as "cache" on the bot, while MongoDB will be set up to be used widely. ### This diff * Add and configure a basic logger on the bot ### Incoming diffs * Add logger to track the interaction with the database * Configure the bot to work with MongoDB * Add handler to interact with the database * Add Guild Model again on MongoDB # Type of change - [ ] Bug fix (non-breaking change which fixes an issue) - [x] New feature (non-breaking change which adds functionality) - [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected) - [ ] Documentation update # How Has This Been Tested? Locally tested to see that is working fine # Checklist: - [x] I have commented my code, particularly in hard-to-understand areas - [x] My changes generate no new warnings - [ ] I have added tests that prove my fix is effective or that my feature works * Add external database (MongoDB) (#49) # Description ### Context In order to improve the system we'll go back to using a database that can be accessed easily from different places. The previous Sqlite3 database will be used just as "cache" on the bot, while MongoDB will be set up to be used widely. ### This diff * Add logger to track the interaction with the database * Configure the bot to work with MongoDB * Configure docker to work with MongoDB if desired * Update documentation ### Incoming diffs * Add handler to interact with the database * Add Guild Model again on MongoDB # Type of change - [ ] Bug fix (non-breaking change which fixes an issue) - [x] New feature (non-breaking change which adds functionality) - [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected) - [x] Documentation update # How Has This Been Tested? Locally tested to see that is working fine # Checklist: - [x] I have commented my code, particularly in hard-to-understand areas - [x] My changes generate no new warnings - [ ] I have added tests that prove my fix is effective or that my feature works * Add guild model (#50) # Description ### Context In order to improve the system we'll go back to using a database that can be accessed easily from different places. The previous Sqlite3 database will be used just as "cache" on the bot, while MongoDB will be set up to be used widely. ### This diff * Add handler to interact with the database * Add Guild Model again on MongoDB # Type of change - [ ] Bug fix (non-breaking change which fixes an issue) - [x] New feature (non-breaking change which adds functionality) - [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected) - [ ] Documentation update # How Has This Been Tested? Locally tested and added unit tests # Checklist: - [x] I have commented my code, particularly in hard-to-understand areas - [x] My changes generate no new warnings - [x] I have added tests that prove my fix is effective or that my feature works * Improve testing (#52) # Description Including tests and clean/improve a bit the test files. # Type of change - [ ] Bug fix (non-breaking change which fixes an issue) - [ ] New feature (non-breaking change which adds functionality) - [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected) - [x] Documentation update # How Has This Been Tested? Running `pytest` # Checklist: - [x] I have commented my code, particularly in hard-to-understand areas - [x] My changes generate no new warnings - [x] I have added tests that prove my fix is effective or that my feature works * Add a command template for reference (#46) * Add a command template for reference * Add interview match model (#56) # Description ### Context The interview match activity that happens every week is one of the remaining activities in the previous bot. To finish the deprecation process we're migrating the activity to the new bot. ### This diff * Add handler to interact with the database * Add InterviewMatch Model for MongoDB ### Incoming diffs * Create image utils * Add interview match command # Type of change - [ ] Bug fix (non-breaking change which fixes an issue) - [x] New feature (non-breaking change which adds functionality) - [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected) - [ ] Documentation update # How Has This Been Tested? Locally tested and added unit tests # Checklist: - [x] I have commented my code, particularly in hard-to-understand areas - [x] My changes generate no new warnings - [x] I have added tests that prove my fix is effective or that my feature works * Create image utils (#57) # Description ### Context The interview match activity that happens every week is one of the remaining activities in the previous bot. To finish the deprecation process we're migrating the activity to the new bot. ### This diff * Create image utils ### Incoming diffs * Add interview match command # Type of change - [ ] Bug fix (non-breaking change which fixes an issue) - [x] New feature (non-breaking change which adds functionality) - [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected) - [ ] Documentation update # How Has This Been Tested? Locally tested and added unit tests # Checklist: - [x] I have commented my code, particularly in hard-to-understand areas - [x] My changes generate no new warnings - [x] I have added tests that prove my fix is effective or that my feature works * Add interview match activity (#30) # Description ### Context The interview match activity that happens every week is one of the remaining activities in the previous bot. To finish the deprecation process we're migrating the activity to the new bot. ### This diff * Add interview match command # Type of change - [ ] Bug fix (non-breaking change which fixes an issue) - [x] New feature (non-breaking change which adds functionality) - [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected) - [ ] Documentation update # How Has This Been Tested? `pre-commit` ran locally. Then tested with a test bot on a test server. # Checklist: - [x] I have commented my code, particularly in hard-to-understand areas - [x] My changes generate no new warnings - [ ] I have added tests that prove my fix is effective or that my feature works * Fix workflows (#58) # Description Fixing the prefix change made some PRs before. For the workflows, removing the option to deploy the bot to dev until is pushed to develop branch (before is tried to deploy every time that is a PR), and allowing to run the build workflow (run bot and test) for any pull request created. # Type of change - [x] Bug fix (non-breaking change which fixes an issue) - [ ] New feature (non-breaking change which adds functionality) - [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected) - [ ] Documentation update # How Has This Been Tested? Locally tested # Checklist: - [ ] I have commented my code, particularly in hard-to-understand areas - [x] My changes generate no new warnings - [ ] I have added tests that prove my fix is effective or that my feature works * Use logger in interview match (#59) # Description As title. # Type of change - [x] Bug fix (non-breaking change which fixes an issue) - [ ] New feature (non-breaking change which adds functionality) - [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected) - [ ] Documentation update # How Has This Been Tested? Locally tested # Checklist: - [ ] I have commented my code, particularly in hard-to-understand areas - [x] My changes generate no new warnings - [ ] I have added tests that prove my fix is effective or that my feature works * Merge master to develop (#64) Develop (#33) * Add poetry skeleton * Add precommit file config * Add discord as dependency * Add tox configuration files and pass precommit * Change the author of the project * GitHub actions (#2) Create build using github action * Bot skeleton (#4) * Add dummy commit to test GH * Change name of precommit file * Add dummy skeleton to test build * Add Dockerfile * Add production github action * Add author to dockerfile * Fix docker file not getting image in FROM (#5) * Docker file fix v2 (#6) Fix problem with name in the registry * Add PR template file (#7) * Add PR template file * Change semantic of type of change * Add documentation as option * Rename az registries information (#8) * Rename az registries information * Rename pull request template * Rename PR template * React with reaction (#9) * Test PR template * Update version of discordpy dependency * Initial architecture of bot * Change tox and preconfig files * Test build * Add cog automatical registration * Add discord token as secure env var * Test no cog registration (#10) * Fix problem with relative path (#11) * Fix linter config (#14) * Unit test and documentation for blueprint bot (#12) * Add unit test for intent registration * Add unit testing for startup * Add test for startup cogs * Create unit testing for formatters * Update constants.py * Test precommit * Create unit testing for formatters * Add Readme * Fix typo in readme * Ignore rule to avoid unneccesary comments * Delete unnecesary comments * Move fixture to conftest * Add initial base for timeline (#15) * Add initial base for timeline * Add unit testing for hiring formatter * Add cron testing * Add unit testing for cog * Change formatter access * Migrate cron to enum * Add annoucement channel as secret for deployment * Add start stop cron schedule * Missing root folder name was failing deploy to Azure (#16) * Debug state * Change to PR * Add analytics to container * Add cogs again * Remove path * Enable cogs again * Test * Rename Docker root file * Add module parameter to Dockerfile * Add complete path * Uncomment cogs * Comment hiring * Add logg * Test * Add complete path to cogs * Put release again on merge * Fix tox passing failing tests * Fix tox * Change tox * FIx tox * Tox should trigger * Skip update dependency * Delete install * Add pytest * Return pytest * Test should fail * Change test to build * Uncomment test cog * Revert push to prod to merge * Prepare deploy with different envs * Test dev deploy * Test secrets * Add env vars for deploy * Fix if * Split dev and prod * Comment test phase * Disable beta command (#18) * Comment beta command * Modify tests * Add logging decorator (#20) * Add logging decorator * Test log in az dev * Test in developent environment * Change policy (#23) * Change policy * Disable push in pull request * Fix lintern problems * Comment logger (#26) * Enable Logging (#24) * Add poetry skeleton * Add precommit file config * Add discord as dependency * Add tox configuration files and pass precommit * Change the author of the project * GitHub actions (#2) Create build using github action * Bot skeleton (#4) * Add dummy commit to test GH * Change name of precommit file * Add dummy skeleton to test build * Add Dockerfile * Add production github action * Add author to dockerfile * Fix docker file not getting image in FROM (#5) * Docker file fix v2 (#6) Fix problem with name in the registry * Add PR template file (#7) * Add PR template file * Change semantic of type of change * Add documentation as option * Rename az registries information (#8) * Rename az registries information * Rename pull request template * Rename PR template * React with reaction (#9) * Test PR template * Update version of discordpy dependency * Initial architecture of bot * Change tox and preconfig files * Test build * Add cog automatical registration * Add discord token as secure env var * Test no cog registration (#10) * Fix problem with relative path (#11) * Fix linter config (#14) * Unit test and documentation for blueprint bot (#12) * Add unit test for intent registration * Add unit testing for startup * Add test for startup cogs * Create unit testing for formatters * Update constants.py * Test precommit * Create unit testing for formatters * Add Readme * Fix typo in readme * Ignore rule to avoid unneccesary comments * Delete unnecesary comments * Move fixture to conftest * Add initial base for timeline (#15) * Add initial base for timeline * Add unit testing for hiring formatter * Add cron testing * Add unit testing for cog * Change formatter access * Migrate cron to enum * Add annoucement channel as secret for deployment * Add start stop cron schedule * Missing root folder name was failing deploy to Azure (#16) * Debug state * Change to PR * Add analytics to container * Add cogs again * Remove path * Enable cogs again * Test * Rename Docker root file * Add module parameter to Dockerfile * Add complete path * Uncomment cogs * Comment hiring * Add logg * Test * Add complete path to cogs * Put release again on merge * Fix tox passing failing tests * Fix tox * Change tox * FIx tox * Tox should trigger * Skip update dependency * Delete install * Add pytest * Return pytest * Test should fail * Change test to build * Uncomment test cog * Revert push to prod to merge * Prepare deploy with different envs * Test dev deploy * Test secrets * Add env vars for deploy * Fix if * Split dev and prod * Comment test phase * Disable beta command (#18) * Comment beta command * Modify tests * Add logging decorator (#20) * Add logging decorator * Test log in az dev * Test in developent environment * Change policy (#23) * Change policy * Disable push in pull request * Fix lintern problems * Comment logger --------- * Akotadi/update common rules (#25) * Update pre-commit and fix issues * Fix issues * Remove eof * Update pre-commit and address comments * Add readme env variables * Linter * Add documentation for command * Disable logging (#32) --------- Co-authored-by: Roberto <reyesfragosoroberto@gmail.com> * Update new_user_joins.py * Fix env variables issues (#66) * Fix env variables issues (#67) --------- Co-authored-by: goberinfinity <reyesfragosoroberto@gmail.com>
akotadi
added a commit
that referenced
this pull request
Sep 23, 2024
* Add poetry skeleton * Add precommit file config * Add discord as dependency * Add tox configuration files and pass precommit * Change the author of the project * GitHub actions (#2) Create build using github action * Bot skeleton (#4) * Add dummy commit to test GH * Change name of precommit file * Add dummy skeleton to test build * Add Dockerfile * Add production github action * Add author to dockerfile * Fix docker file not getting image in FROM (#5) * Docker file fix v2 (#6) Fix problem with name in the registry * Add PR template file (#7) * Add PR template file * Change semantic of type of change * Add documentation as option * Rename az registries information (#8) * Rename az registries information * Rename pull request template * Rename PR template * React with reaction (#9) * Test PR template * Update version of discordpy dependency * Initial architecture of bot * Change tox and preconfig files * Test build * Add cog automatical registration * Add discord token as secure env var * Test no cog registration (#10) * Fix problem with relative path (#11) * Fix linter config (#14) * Unit test and documentation for blueprint bot (#12) * Add unit test for intent registration * Add unit testing for startup * Add test for startup cogs * Create unit testing for formatters * Update constants.py Co-Authored-By: Manuel CH <26100917+akotadi@users.noreply.github.com> * Test precommit * Create unit testing for formatters * Add Readme * Fix typo in readme * Ignore rule to avoid unneccesary comments * Delete unnecesary comments * Move fixture to conftest Co-authored-by: Manuel CH <26100917+akotadi@users.noreply.github.com> * Add initial base for timeline (#15) * Add initial base for timeline * Add unit testing for hiring formatter * Add cron testing * Add unit testing for cog * Change formatter access * Migrate cron to enum * Add annoucement channel as secret for deployment * Add start stop cron schedule * Missing root folder name was failing deploy to Azure (#16) * Debug state * Change to PR * Add analytics to container * Add cogs again * Remove path * Enable cogs again * Test * Rename Docker root file * Add module parameter to Dockerfile * Add complete path * Uncomment cogs * Comment hiring * Add logg * Test * Add complete path to cogs * Put release again on merge * Fix tox passing failing tests * Fix tox * Change tox * FIx tox * Tox should trigger * Skip update dependency * Delete install * Add pytest * Return pytest * Test should fail * Change test to build * Uncomment test cog * Revert push to prod to merge * Prepare deploy with different envs * Test dev deploy * Test secrets * Add env vars for deploy * Fix if * Split dev and prod * Comment test phase * Disable beta command (#18) * Comment beta command * Modify tests * Add logging decorator (#20) * Add logging decorator * Test log in az dev * Test in developent environment * Change policy (#23) * Change policy * Disable push in pull request * Fix lintern problems * Comment logger (#26) * Enable Logging (#24) * Add poetry skeleton * Add precommit file config * Add discord as dependency * Add tox configuration files and pass precommit * Change the author of the project * GitHub actions (#2) Create build using github action * Bot skeleton (#4) * Add dummy commit to test GH * Change name of precommit file * Add dummy skeleton to test build * Add Dockerfile * Add production github action * Add author to dockerfile * Fix docker file not getting image in FROM (#5) * Docker file fix v2 (#6) Fix problem with name in the registry * Add PR template file (#7) * Add PR template file * Change semantic of type of change * Add documentation as option * Rename az registries information (#8) * Rename az registries information * Rename pull request template * Rename PR template * React with reaction (#9) * Test PR template * Update version of discordpy dependency * Initial architecture of bot * Change tox and preconfig files * Test build * Add cog automatical registration * Add discord token as secure env var * Test no cog registration (#10) * Fix problem with relative path (#11) * Fix linter config (#14) * Unit test and documentation for blueprint bot (#12) * Add unit test for intent registration * Add unit testing for startup * Add test for startup cogs * Create unit testing for formatters * Update constants.py Co-Authored-By: Manuel CH <26100917+akotadi@users.noreply.github.com> * Test precommit * Create unit testing for formatters * Add Readme * Fix typo in readme * Ignore rule to avoid unneccesary comments * Delete unnecesary comments * Move fixture to conftest Co-authored-by: Manuel CH <26100917+akotadi@users.noreply.github.com> * Add initial base for timeline (#15) * Add initial base for timeline * Add unit testing for hiring formatter * Add cron testing * Add unit testing for cog * Change formatter access * Migrate cron to enum * Add annoucement channel as secret for deployment * Add start stop cron schedule * Missing root folder name was failing deploy to Azure (#16) * Debug state * Change to PR * Add analytics to container * Add cogs again * Remove path * Enable cogs again * Test * Rename Docker root file * Add module parameter to Dockerfile * Add complete path * Uncomment cogs * Comment hiring * Add logg * Test * Add complete path to cogs * Put release again on merge * Fix tox passing failing tests * Fix tox * Change tox * FIx tox * Tox should trigger * Skip update dependency * Delete install * Add pytest * Return pytest * Test should fail * Change test to build * Uncomment test cog * Revert push to prod to merge * Prepare deploy with different envs * Test dev deploy * Test secrets * Add env vars for deploy * Fix if * Split dev and prod * Comment test phase * Disable beta command (#18) * Comment beta command * Modify tests * Add logging decorator (#20) * Add logging decorator * Test log in az dev * Test in developent environment * Change policy (#23) * Change policy * Disable push in pull request * Fix lintern problems Co-authored-by: Manuel CH <26100917+akotadi@users.noreply.github.com> * Comment logger --------- Co-authored-by: Manuel CH <26100917+akotadi@users.noreply.github.com> * Akotadi/update common rules (#25) * Update pre-commit and fix issues * Fix issues * Remove eof * Update pre-commit and address comments * Add readme env variables * Linter * Add documentation for command * Disable logging (#32) * Add reaction check handler (#29) * Update pre-commit and fix issues * Fix issues * Remove eof * Update pre-commit and address comments * Add readme env variables * Linter * Add role when react to welcome message * Update readme * Add tests * Add test * Update description * Address comments * Update pytest version * Create settings file * Add comment * Add orm with guild checks (#34) * Remove local database (#47) # Description ### Context In order to improve the system we'll go back to using a database that can be accessed easily from different places. The previous Sqlite3 database will be used just as "cache" on the bot, while MongoDB will be set up to be used widely. ### This diff * Remove the previous local database and let it as local cache ### Incoming diffs * Add logger to track the interaction with the database * Configure the bot to work with MongoDB * Add handler to interact with the database * Add Guild Model again on MongoDB # Type of change - [ ] Bug fix (non-breaking change which fixes an issue) - [x] New feature (non-breaking change which adds functionality) - [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected) - [ ] Documentation update # How Has This Been Tested? Locally run to be sure that is still working fine # Checklist: - [x] I have commented my code, particularly in hard-to-understand areas - [x] My changes generate no new warnings - [ ] I have added tests that prove my fix is effective or that my feature works * Add logger (#48) # Description ### Context In order to improve the system we'll go back to using a database that can be accessed easily from different places. The previous Sqlite3 database will be used just as "cache" on the bot, while MongoDB will be set up to be used widely. ### This diff * Add and configure a basic logger on the bot ### Incoming diffs * Add logger to track the interaction with the database * Configure the bot to work with MongoDB * Add handler to interact with the database * Add Guild Model again on MongoDB # Type of change - [ ] Bug fix (non-breaking change which fixes an issue) - [x] New feature (non-breaking change which adds functionality) - [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected) - [ ] Documentation update # How Has This Been Tested? Locally tested to see that is working fine # Checklist: - [x] I have commented my code, particularly in hard-to-understand areas - [x] My changes generate no new warnings - [ ] I have added tests that prove my fix is effective or that my feature works * Add external database (MongoDB) (#49) # Description ### Context In order to improve the system we'll go back to using a database that can be accessed easily from different places. The previous Sqlite3 database will be used just as "cache" on the bot, while MongoDB will be set up to be used widely. ### This diff * Add logger to track the interaction with the database * Configure the bot to work with MongoDB * Configure docker to work with MongoDB if desired * Update documentation ### Incoming diffs * Add handler to interact with the database * Add Guild Model again on MongoDB # Type of change - [ ] Bug fix (non-breaking change which fixes an issue) - [x] New feature (non-breaking change which adds functionality) - [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected) - [x] Documentation update # How Has This Been Tested? Locally tested to see that is working fine # Checklist: - [x] I have commented my code, particularly in hard-to-understand areas - [x] My changes generate no new warnings - [ ] I have added tests that prove my fix is effective or that my feature works * Add guild model (#50) # Description ### Context In order to improve the system we'll go back to using a database that can be accessed easily from different places. The previous Sqlite3 database will be used just as "cache" on the bot, while MongoDB will be set up to be used widely. ### This diff * Add handler to interact with the database * Add Guild Model again on MongoDB # Type of change - [ ] Bug fix (non-breaking change which fixes an issue) - [x] New feature (non-breaking change which adds functionality) - [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected) - [ ] Documentation update # How Has This Been Tested? Locally tested and added unit tests # Checklist: - [x] I have commented my code, particularly in hard-to-understand areas - [x] My changes generate no new warnings - [x] I have added tests that prove my fix is effective or that my feature works * Improve testing (#52) # Description Including tests and clean/improve a bit the test files. # Type of change - [ ] Bug fix (non-breaking change which fixes an issue) - [ ] New feature (non-breaking change which adds functionality) - [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected) - [x] Documentation update # How Has This Been Tested? Running `pytest` # Checklist: - [x] I have commented my code, particularly in hard-to-understand areas - [x] My changes generate no new warnings - [x] I have added tests that prove my fix is effective or that my feature works * Add a command template for reference (#46) * Add a command template for reference * Add interview match model (#56) # Description ### Context The interview match activity that happens every week is one of the remaining activities in the previous bot. To finish the deprecation process we're migrating the activity to the new bot. ### This diff * Add handler to interact with the database * Add InterviewMatch Model for MongoDB ### Incoming diffs * Create image utils * Add interview match command # Type of change - [ ] Bug fix (non-breaking change which fixes an issue) - [x] New feature (non-breaking change which adds functionality) - [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected) - [ ] Documentation update # How Has This Been Tested? Locally tested and added unit tests # Checklist: - [x] I have commented my code, particularly in hard-to-understand areas - [x] My changes generate no new warnings - [x] I have added tests that prove my fix is effective or that my feature works * Create image utils (#57) # Description ### Context The interview match activity that happens every week is one of the remaining activities in the previous bot. To finish the deprecation process we're migrating the activity to the new bot. ### This diff * Create image utils ### Incoming diffs * Add interview match command # Type of change - [ ] Bug fix (non-breaking change which fixes an issue) - [x] New feature (non-breaking change which adds functionality) - [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected) - [ ] Documentation update # How Has This Been Tested? Locally tested and added unit tests # Checklist: - [x] I have commented my code, particularly in hard-to-understand areas - [x] My changes generate no new warnings - [x] I have added tests that prove my fix is effective or that my feature works * Add interview match activity (#30) # Description ### Context The interview match activity that happens every week is one of the remaining activities in the previous bot. To finish the deprecation process we're migrating the activity to the new bot. ### This diff * Add interview match command # Type of change - [ ] Bug fix (non-breaking change which fixes an issue) - [x] New feature (non-breaking change which adds functionality) - [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected) - [ ] Documentation update # How Has This Been Tested? `pre-commit` ran locally. Then tested with a test bot on a test server. # Checklist: - [x] I have commented my code, particularly in hard-to-understand areas - [x] My changes generate no new warnings - [ ] I have added tests that prove my fix is effective or that my feature works * Fix workflows (#58) # Description Fixing the prefix change made some PRs before. For the workflows, removing the option to deploy the bot to dev until is pushed to develop branch (before is tried to deploy every time that is a PR), and allowing to run the build workflow (run bot and test) for any pull request created. # Type of change - [x] Bug fix (non-breaking change which fixes an issue) - [ ] New feature (non-breaking change which adds functionality) - [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected) - [ ] Documentation update # How Has This Been Tested? Locally tested # Checklist: - [ ] I have commented my code, particularly in hard-to-understand areas - [x] My changes generate no new warnings - [ ] I have added tests that prove my fix is effective or that my feature works * Use logger in interview match (#59) # Description As title. # Type of change - [x] Bug fix (non-breaking change which fixes an issue) - [ ] New feature (non-breaking change which adds functionality) - [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected) - [ ] Documentation update # How Has This Been Tested? Locally tested # Checklist: - [ ] I have commented my code, particularly in hard-to-understand areas - [x] My changes generate no new warnings - [ ] I have added tests that prove my fix is effective or that my feature works * Merge master to develop (#64) Develop (#33) * Add poetry skeleton * Add precommit file config * Add discord as dependency * Add tox configuration files and pass precommit * Change the author of the project * GitHub actions (#2) Create build using github action * Bot skeleton (#4) * Add dummy commit to test GH * Change name of precommit file * Add dummy skeleton to test build * Add Dockerfile * Add production github action * Add author to dockerfile * Fix docker file not getting image in FROM (#5) * Docker file fix v2 (#6) Fix problem with name in the registry * Add PR template file (#7) * Add PR template file * Change semantic of type of change * Add documentation as option * Rename az registries information (#8) * Rename az registries information * Rename pull request template * Rename PR template * React with reaction (#9) * Test PR template * Update version of discordpy dependency * Initial architecture of bot * Change tox and preconfig files * Test build * Add cog automatical registration * Add discord token as secure env var * Test no cog registration (#10) * Fix problem with relative path (#11) * Fix linter config (#14) * Unit test and documentation for blueprint bot (#12) * Add unit test for intent registration * Add unit testing for startup * Add test for startup cogs * Create unit testing for formatters * Update constants.py * Test precommit * Create unit testing for formatters * Add Readme * Fix typo in readme * Ignore rule to avoid unneccesary comments * Delete unnecesary comments * Move fixture to conftest * Add initial base for timeline (#15) * Add initial base for timeline * Add unit testing for hiring formatter * Add cron testing * Add unit testing for cog * Change formatter access * Migrate cron to enum * Add annoucement channel as secret for deployment * Add start stop cron schedule * Missing root folder name was failing deploy to Azure (#16) * Debug state * Change to PR * Add analytics to container * Add cogs again * Remove path * Enable cogs again * Test * Rename Docker root file * Add module parameter to Dockerfile * Add complete path * Uncomment cogs * Comment hiring * Add logg * Test * Add complete path to cogs * Put release again on merge * Fix tox passing failing tests * Fix tox * Change tox * FIx tox * Tox should trigger * Skip update dependency * Delete install * Add pytest * Return pytest * Test should fail * Change test to build * Uncomment test cog * Revert push to prod to merge * Prepare deploy with different envs * Test dev deploy * Test secrets * Add env vars for deploy * Fix if * Split dev and prod * Comment test phase * Disable beta command (#18) * Comment beta command * Modify tests * Add logging decorator (#20) * Add logging decorator * Test log in az dev * Test in developent environment * Change policy (#23) * Change policy * Disable push in pull request * Fix lintern problems * Comment logger (#26) * Enable Logging (#24) * Add poetry skeleton * Add precommit file config * Add discord as dependency * Add tox configuration files and pass precommit * Change the author of the project * GitHub actions (#2) Create build using github action * Bot skeleton (#4) * Add dummy commit to test GH * Change name of precommit file * Add dummy skeleton to test build * Add Dockerfile * Add production github action * Add author to dockerfile * Fix docker file not getting image in FROM (#5) * Docker file fix v2 (#6) Fix problem with name in the registry * Add PR template file (#7) * Add PR template file * Change semantic of type of change * Add documentation as option * Rename az registries information (#8) * Rename az registries information * Rename pull request template * Rename PR template * React with reaction (#9) * Test PR template * Update version of discordpy dependency * Initial architecture of bot * Change tox and preconfig files * Test build * Add cog automatical registration * Add discord token as secure env var * Test no cog registration (#10) * Fix problem with relative path (#11) * Fix linter config (#14) * Unit test and documentation for blueprint bot (#12) * Add unit test for intent registration * Add unit testing for startup * Add test for startup cogs * Create unit testing for formatters * Update constants.py * Test precommit * Create unit testing for formatters * Add Readme * Fix typo in readme * Ignore rule to avoid unneccesary comments * Delete unnecesary comments * Move fixture to conftest * Add initial base for timeline (#15) * Add initial base for timeline * Add unit testing for hiring formatter * Add cron testing * Add unit testing for cog * Change formatter access * Migrate cron to enum * Add annoucement channel as secret for deployment * Add start stop cron schedule * Missing root folder name was failing deploy to Azure (#16) * Debug state * Change to PR * Add analytics to container * Add cogs again * Remove path * Enable cogs again * Test * Rename Docker root file * Add module parameter to Dockerfile * Add complete path * Uncomment cogs * Comment hiring * Add logg * Test * Add complete path to cogs * Put release again on merge * Fix tox passing failing tests * Fix tox * Change tox * FIx tox * Tox should trigger * Skip update dependency * Delete install * Add pytest * Return pytest * Test should fail * Change test to build * Uncomment test cog * Revert push to prod to merge * Prepare deploy with different envs * Test dev deploy * Test secrets * Add env vars for deploy * Fix if * Split dev and prod * Comment test phase * Disable beta command (#18) * Comment beta command * Modify tests * Add logging decorator (#20) * Add logging decorator * Test log in az dev * Test in developent environment * Change policy (#23) * Change policy * Disable push in pull request * Fix lintern problems * Comment logger --------- * Akotadi/update common rules (#25) * Update pre-commit and fix issues * Fix issues * Remove eof * Update pre-commit and address comments * Add readme env variables * Linter * Add documentation for command * Disable logging (#32) --------- Co-authored-by: Roberto <reyesfragosoroberto@gmail.com> * Update new_user_joins.py * Fix env variables issues (#66) * Fix env variables issues (#67) * Create send message util (#68) # Description ### Context Currently the hiring timelines announcements depends on an ENV variable to send the message, that approach is not extensible to other guilds and other channels, and is not maintainable in the time. Because of that we're migrating the configuration to the database. ### This diff * Create a send message util to use the embed and catch any errors to avoid repetitive code ### Incoming diffs * Add announcement config model * Update the hiring timeline command to use the new configuration from the database # Type of change - [ ] Bug fix (non-breaking change which fixes an issue) - [x] New feature (non-breaking change which adds functionality) - [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected) - [ ] Documentation update # How Has This Been Tested? Added unit test # Checklist: - [x] I have commented my code, particularly in hard-to-understand areas - [x] My changes generate no new warnings - [x] I have added tests that prove my fix is effective or that my feature works * Add role config model (#71) # Description ### Context Currently giving the base role (`OTTER_ROLE`) depends on an ENV variable when a user reacts to the message, that approach is not extensible to other guilds and other channels, and is not maintainable in the time. Because of that we're migrating the configuration to the database. ### This diff * Add base role config model ### Incoming diffs * Add welcome messages role command * Update `on_raw_reaction_add` event to use the database data # Type of change - [ ] Bug fix (non-breaking change which fixes an issue) - [x] New feature (non-breaking change which adds functionality) - [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected) - [ ] Documentation update # How Has This Been Tested? Added unit tests # Checklist: - [x] I have commented my code, particularly in hard-to-understand areas - [x] My changes generate no new warnings - [x] I have added tests that prove my fix is effective or that my feature works * Add welcome messages role command (#72) # Description ### Context Currently giving the base role (`OTTER_ROLE`) depends on an ENV variable when a user reacts to the message, that approach is not extensible to other guilds and other channels, and is not maintainable in the time. Because of that we're migrating the configuration to the database. ### This diff * Add welcome messages role command ### Incoming diffs * Update `on_raw_reaction_add` event to use the database data # Type of change - [ ] Bug fix (non-breaking change which fixes an issue) - [x] New feature (non-breaking change which adds functionality) - [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected) - [ ] Documentation update # How Has This Been Tested? Manually tested on a test server # Checklist: - [x] I have commented my code, particularly in hard-to-understand areas - [x] My changes generate no new warnings - [x] I have added tests that prove my fix is effective or that my feature works * Update on_reaction_add to use database data (#73) # Description ### Context Currently giving the base role (`OTTER_ROLE`) depends on an ENV variable when a user reacts to the message, that approach is not extensible to other guilds and other channels, and is not maintainable in the time. Because of that we're migrating the configuration to the database. ### This diff * Update `on_raw_reaction_add` event to use the database data # Type of change - [ ] Bug fix (non-breaking change which fixes an issue) - [x] New feature (non-breaking change which adds functionality) - [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected) - [ ] Documentation update # How Has This Been Tested? Updated unit tests and manually tested on a test server # Checklist: - [x] I have commented my code, particularly in hard-to-understand areas - [x] My changes generate no new warnings - [x] I have added tests that prove my fix is effective or that my feature works * Update hiring timeline cog to use db model (#70) # Description ### Context Currently the hiring timelines announcements depends on an ENV variable to send the message, that approach is not extensible to other guilds and other channels, and is not maintainable in the time. Because of that we're migrating the configuration to the database. ### This diff * Update the hiring timeline command to use the new configuration from the database # Type of change - [ ] Bug fix (non-breaking change which fixes an issue) - [x] New feature (non-breaking change which adds functionality) - [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected) - [ ] Documentation update # How Has This Been Tested? Tested manually in a test server # Checklist: - [x] I have commented my code, particularly in hard-to-understand areas - [x] My changes generate no new warnings - [ ] I have added tests that prove my fix is effective or that my feature works --------- Co-authored-by: goberinfinity <reyesfragosoroberto@gmail.com>
akotadi
added a commit
that referenced
this pull request
Oct 11, 2024
* Add poetry skeleton * Add precommit file config * Add discord as dependency * Add tox configuration files and pass precommit * Change the author of the project * GitHub actions (#2) Create build using github action * Bot skeleton (#4) * Add dummy commit to test GH * Change name of precommit file * Add dummy skeleton to test build * Add Dockerfile * Add production github action * Add author to dockerfile * Fix docker file not getting image in FROM (#5) * Docker file fix v2 (#6) Fix problem with name in the registry * Add PR template file (#7) * Add PR template file * Change semantic of type of change * Add documentation as option * Rename az registries information (#8) * Rename az registries information * Rename pull request template * Rename PR template * React with reaction (#9) * Test PR template * Update version of discordpy dependency * Initial architecture of bot * Change tox and preconfig files * Test build * Add cog automatical registration * Add discord token as secure env var * Test no cog registration (#10) * Fix problem with relative path (#11) * Fix linter config (#14) * Unit test and documentation for blueprint bot (#12) * Add unit test for intent registration * Add unit testing for startup * Add test for startup cogs * Create unit testing for formatters * Update constants.py Co-Authored-By: Manuel CH <26100917+akotadi@users.noreply.github.com> * Test precommit * Create unit testing for formatters * Add Readme * Fix typo in readme * Ignore rule to avoid unneccesary comments * Delete unnecesary comments * Move fixture to conftest Co-authored-by: Manuel CH <26100917+akotadi@users.noreply.github.com> * Add initial base for timeline (#15) * Add initial base for timeline * Add unit testing for hiring formatter * Add cron testing * Add unit testing for cog * Change formatter access * Migrate cron to enum * Add annoucement channel as secret for deployment * Add start stop cron schedule * Missing root folder name was failing deploy to Azure (#16) * Debug state * Change to PR * Add analytics to container * Add cogs again * Remove path * Enable cogs again * Test * Rename Docker root file * Add module parameter to Dockerfile * Add complete path * Uncomment cogs * Comment hiring * Add logg * Test * Add complete path to cogs * Put release again on merge * Fix tox passing failing tests * Fix tox * Change tox * FIx tox * Tox should trigger * Skip update dependency * Delete install * Add pytest * Return pytest * Test should fail * Change test to build * Uncomment test cog * Revert push to prod to merge * Prepare deploy with different envs * Test dev deploy * Test secrets * Add env vars for deploy * Fix if * Split dev and prod * Comment test phase * Disable beta command (#18) * Comment beta command * Modify tests * Add logging decorator (#20) * Add logging decorator * Test log in az dev * Test in developent environment * Change policy (#23) * Change policy * Disable push in pull request * Fix lintern problems * Comment logger (#26) * Enable Logging (#24) * Add poetry skeleton * Add precommit file config * Add discord as dependency * Add tox configuration files and pass precommit * Change the author of the project * GitHub actions (#2) Create build using github action * Bot skeleton (#4) * Add dummy commit to test GH * Change name of precommit file * Add dummy skeleton to test build * Add Dockerfile * Add production github action * Add author to dockerfile * Fix docker file not getting image in FROM (#5) * Docker file fix v2 (#6) Fix problem with name in the registry * Add PR template file (#7) * Add PR template file * Change semantic of type of change * Add documentation as option * Rename az registries information (#8) * Rename az registries information * Rename pull request template * Rename PR template * React with reaction (#9) * Test PR template * Update version of discordpy dependency * Initial architecture of bot * Change tox and preconfig files * Test build * Add cog automatical registration * Add discord token as secure env var * Test no cog registration (#10) * Fix problem with relative path (#11) * Fix linter config (#14) * Unit test and documentation for blueprint bot (#12) * Add unit test for intent registration * Add unit testing for startup * Add test for startup cogs * Create unit testing for formatters * Update constants.py Co-Authored-By: Manuel CH <26100917+akotadi@users.noreply.github.com> * Test precommit * Create unit testing for formatters * Add Readme * Fix typo in readme * Ignore rule to avoid unneccesary comments * Delete unnecesary comments * Move fixture to conftest Co-authored-by: Manuel CH <26100917+akotadi@users.noreply.github.com> * Add initial base for timeline (#15) * Add initial base for timeline * Add unit testing for hiring formatter * Add cron testing * Add unit testing for cog * Change formatter access * Migrate cron to enum * Add annoucement channel as secret for deployment * Add start stop cron schedule * Missing root folder name was failing deploy to Azure (#16) * Debug state * Change to PR * Add analytics to container * Add cogs again * Remove path * Enable cogs again * Test * Rename Docker root file * Add module parameter to Dockerfile * Add complete path * Uncomment cogs * Comment hiring * Add logg * Test * Add complete path to cogs * Put release again on merge * Fix tox passing failing tests * Fix tox * Change tox * FIx tox * Tox should trigger * Skip update dependency * Delete install * Add pytest * Return pytest * Test should fail * Change test to build * Uncomment test cog * Revert push to prod to merge * Prepare deploy with different envs * Test dev deploy * Test secrets * Add env vars for deploy * Fix if * Split dev and prod * Comment test phase * Disable beta command (#18) * Comment beta command * Modify tests * Add logging decorator (#20) * Add logging decorator * Test log in az dev * Test in developent environment * Change policy (#23) * Change policy * Disable push in pull request * Fix lintern problems Co-authored-by: Manuel CH <26100917+akotadi@users.noreply.github.com> * Comment logger --------- Co-authored-by: Manuel CH <26100917+akotadi@users.noreply.github.com> * Akotadi/update common rules (#25) * Update pre-commit and fix issues * Fix issues * Remove eof * Update pre-commit and address comments * Add readme env variables * Linter * Add documentation for command * Disable logging (#32) * Add reaction check handler (#29) * Update pre-commit and fix issues * Fix issues * Remove eof * Update pre-commit and address comments * Add readme env variables * Linter * Add role when react to welcome message * Update readme * Add tests * Add test * Update description * Address comments * Update pytest version * Create settings file * Add comment * Add orm with guild checks (#34) * Remove local database (#47) # Description ### Context In order to improve the system we'll go back to using a database that can be accessed easily from different places. The previous Sqlite3 database will be used just as "cache" on the bot, while MongoDB will be set up to be used widely. ### This diff * Remove the previous local database and let it as local cache ### Incoming diffs * Add logger to track the interaction with the database * Configure the bot to work with MongoDB * Add handler to interact with the database * Add Guild Model again on MongoDB # Type of change - [ ] Bug fix (non-breaking change which fixes an issue) - [x] New feature (non-breaking change which adds functionality) - [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected) - [ ] Documentation update # How Has This Been Tested? Locally run to be sure that is still working fine # Checklist: - [x] I have commented my code, particularly in hard-to-understand areas - [x] My changes generate no new warnings - [ ] I have added tests that prove my fix is effective or that my feature works * Add logger (#48) # Description ### Context In order to improve the system we'll go back to using a database that can be accessed easily from different places. The previous Sqlite3 database will be used just as "cache" on the bot, while MongoDB will be set up to be used widely. ### This diff * Add and configure a basic logger on the bot ### Incoming diffs * Add logger to track the interaction with the database * Configure the bot to work with MongoDB * Add handler to interact with the database * Add Guild Model again on MongoDB # Type of change - [ ] Bug fix (non-breaking change which fixes an issue) - [x] New feature (non-breaking change which adds functionality) - [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected) - [ ] Documentation update # How Has This Been Tested? Locally tested to see that is working fine # Checklist: - [x] I have commented my code, particularly in hard-to-understand areas - [x] My changes generate no new warnings - [ ] I have added tests that prove my fix is effective or that my feature works * Add external database (MongoDB) (#49) # Description ### Context In order to improve the system we'll go back to using a database that can be accessed easily from different places. The previous Sqlite3 database will be used just as "cache" on the bot, while MongoDB will be set up to be used widely. ### This diff * Add logger to track the interaction with the database * Configure the bot to work with MongoDB * Configure docker to work with MongoDB if desired * Update documentation ### Incoming diffs * Add handler to interact with the database * Add Guild Model again on MongoDB # Type of change - [ ] Bug fix (non-breaking change which fixes an issue) - [x] New feature (non-breaking change which adds functionality) - [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected) - [x] Documentation update # How Has This Been Tested? Locally tested to see that is working fine # Checklist: - [x] I have commented my code, particularly in hard-to-understand areas - [x] My changes generate no new warnings - [ ] I have added tests that prove my fix is effective or that my feature works * Add guild model (#50) # Description ### Context In order to improve the system we'll go back to using a database that can be accessed easily from different places. The previous Sqlite3 database will be used just as "cache" on the bot, while MongoDB will be set up to be used widely. ### This diff * Add handler to interact with the database * Add Guild Model again on MongoDB # Type of change - [ ] Bug fix (non-breaking change which fixes an issue) - [x] New feature (non-breaking change which adds functionality) - [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected) - [ ] Documentation update # How Has This Been Tested? Locally tested and added unit tests # Checklist: - [x] I have commented my code, particularly in hard-to-understand areas - [x] My changes generate no new warnings - [x] I have added tests that prove my fix is effective or that my feature works * Improve testing (#52) # Description Including tests and clean/improve a bit the test files. # Type of change - [ ] Bug fix (non-breaking change which fixes an issue) - [ ] New feature (non-breaking change which adds functionality) - [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected) - [x] Documentation update # How Has This Been Tested? Running `pytest` # Checklist: - [x] I have commented my code, particularly in hard-to-understand areas - [x] My changes generate no new warnings - [x] I have added tests that prove my fix is effective or that my feature works * Add a command template for reference (#46) * Add a command template for reference * Add interview match model (#56) # Description ### Context The interview match activity that happens every week is one of the remaining activities in the previous bot. To finish the deprecation process we're migrating the activity to the new bot. ### This diff * Add handler to interact with the database * Add InterviewMatch Model for MongoDB ### Incoming diffs * Create image utils * Add interview match command # Type of change - [ ] Bug fix (non-breaking change which fixes an issue) - [x] New feature (non-breaking change which adds functionality) - [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected) - [ ] Documentation update # How Has This Been Tested? Locally tested and added unit tests # Checklist: - [x] I have commented my code, particularly in hard-to-understand areas - [x] My changes generate no new warnings - [x] I have added tests that prove my fix is effective or that my feature works * Create image utils (#57) # Description ### Context The interview match activity that happens every week is one of the remaining activities in the previous bot. To finish the deprecation process we're migrating the activity to the new bot. ### This diff * Create image utils ### Incoming diffs * Add interview match command # Type of change - [ ] Bug fix (non-breaking change which fixes an issue) - [x] New feature (non-breaking change which adds functionality) - [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected) - [ ] Documentation update # How Has This Been Tested? Locally tested and added unit tests # Checklist: - [x] I have commented my code, particularly in hard-to-understand areas - [x] My changes generate no new warnings - [x] I have added tests that prove my fix is effective or that my feature works * Add interview match activity (#30) # Description ### Context The interview match activity that happens every week is one of the remaining activities in the previous bot. To finish the deprecation process we're migrating the activity to the new bot. ### This diff * Add interview match command # Type of change - [ ] Bug fix (non-breaking change which fixes an issue) - [x] New feature (non-breaking change which adds functionality) - [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected) - [ ] Documentation update # How Has This Been Tested? `pre-commit` ran locally. Then tested with a test bot on a test server. # Checklist: - [x] I have commented my code, particularly in hard-to-understand areas - [x] My changes generate no new warnings - [ ] I have added tests that prove my fix is effective or that my feature works * Fix workflows (#58) # Description Fixing the prefix change made some PRs before. For the workflows, removing the option to deploy the bot to dev until is pushed to develop branch (before is tried to deploy every time that is a PR), and allowing to run the build workflow (run bot and test) for any pull request created. # Type of change - [x] Bug fix (non-breaking change which fixes an issue) - [ ] New feature (non-breaking change which adds functionality) - [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected) - [ ] Documentation update # How Has This Been Tested? Locally tested # Checklist: - [ ] I have commented my code, particularly in hard-to-understand areas - [x] My changes generate no new warnings - [ ] I have added tests that prove my fix is effective or that my feature works * Use logger in interview match (#59) # Description As title. # Type of change - [x] Bug fix (non-breaking change which fixes an issue) - [ ] New feature (non-breaking change which adds functionality) - [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected) - [ ] Documentation update # How Has This Been Tested? Locally tested # Checklist: - [ ] I have commented my code, particularly in hard-to-understand areas - [x] My changes generate no new warnings - [ ] I have added tests that prove my fix is effective or that my feature works * Merge master to develop (#64) Develop (#33) * Add poetry skeleton * Add precommit file config * Add discord as dependency * Add tox configuration files and pass precommit * Change the author of the project * GitHub actions (#2) Create build using github action * Bot skeleton (#4) * Add dummy commit to test GH * Change name of precommit file * Add dummy skeleton to test build * Add Dockerfile * Add production github action * Add author to dockerfile * Fix docker file not getting image in FROM (#5) * Docker file fix v2 (#6) Fix problem with name in the registry * Add PR template file (#7) * Add PR template file * Change semantic of type of change * Add documentation as option * Rename az registries information (#8) * Rename az registries information * Rename pull request template * Rename PR template * React with reaction (#9) * Test PR template * Update version of discordpy dependency * Initial architecture of bot * Change tox and preconfig files * Test build * Add cog automatical registration * Add discord token as secure env var * Test no cog registration (#10) * Fix problem with relative path (#11) * Fix linter config (#14) * Unit test and documentation for blueprint bot (#12) * Add unit test for intent registration * Add unit testing for startup * Add test for startup cogs * Create unit testing for formatters * Update constants.py * Test precommit * Create unit testing for formatters * Add Readme * Fix typo in readme * Ignore rule to avoid unneccesary comments * Delete unnecesary comments * Move fixture to conftest * Add initial base for timeline (#15) * Add initial base for timeline * Add unit testing for hiring formatter * Add cron testing * Add unit testing for cog * Change formatter access * Migrate cron to enum * Add annoucement channel as secret for deployment * Add start stop cron schedule * Missing root folder name was failing deploy to Azure (#16) * Debug state * Change to PR * Add analytics to container * Add cogs again * Remove path * Enable cogs again * Test * Rename Docker root file * Add module parameter to Dockerfile * Add complete path * Uncomment cogs * Comment hiring * Add logg * Test * Add complete path to cogs * Put release again on merge * Fix tox passing failing tests * Fix tox * Change tox * FIx tox * Tox should trigger * Skip update dependency * Delete install * Add pytest * Return pytest * Test should fail * Change test to build * Uncomment test cog * Revert push to prod to merge * Prepare deploy with different envs * Test dev deploy * Test secrets * Add env vars for deploy * Fix if * Split dev and prod * Comment test phase * Disable beta command (#18) * Comment beta command * Modify tests * Add logging decorator (#20) * Add logging decorator * Test log in az dev * Test in developent environment * Change policy (#23) * Change policy * Disable push in pull request * Fix lintern problems * Comment logger (#26) * Enable Logging (#24) * Add poetry skeleton * Add precommit file config * Add discord as dependency * Add tox configuration files and pass precommit * Change the author of the project * GitHub actions (#2) Create build using github action * Bot skeleton (#4) * Add dummy commit to test GH * Change name of precommit file * Add dummy skeleton to test build * Add Dockerfile * Add production github action * Add author to dockerfile * Fix docker file not getting image in FROM (#5) * Docker file fix v2 (#6) Fix problem with name in the registry * Add PR template file (#7) * Add PR template file * Change semantic of type of change * Add documentation as option * Rename az registries information (#8) * Rename az registries information * Rename pull request template * Rename PR template * React with reaction (#9) * Test PR template * Update version of discordpy dependency * Initial architecture of bot * Change tox and preconfig files * Test build * Add cog automatical registration * Add discord token as secure env var * Test no cog registration (#10) * Fix problem with relative path (#11) * Fix linter config (#14) * Unit test and documentation for blueprint bot (#12) * Add unit test for intent registration * Add unit testing for startup * Add test for startup cogs * Create unit testing for formatters * Update constants.py * Test precommit * Create unit testing for formatters * Add Readme * Fix typo in readme * Ignore rule to avoid unneccesary comments * Delete unnecesary comments * Move fixture to conftest * Add initial base for timeline (#15) * Add initial base for timeline * Add unit testing for hiring formatter * Add cron testing * Add unit testing for cog * Change formatter access * Migrate cron to enum * Add annoucement channel as secret for deployment * Add start stop cron schedule * Missing root folder name was failing deploy to Azure (#16) * Debug state * Change to PR * Add analytics to container * Add cogs again * Remove path * Enable cogs again * Test * Rename Docker root file * Add module parameter to Dockerfile * Add complete path * Uncomment cogs * Comment hiring * Add logg * Test * Add complete path to cogs * Put release again on merge * Fix tox passing failing tests * Fix tox * Change tox * FIx tox * Tox should trigger * Skip update dependency * Delete install * Add pytest * Return pytest * Test should fail * Change test to build * Uncomment test cog * Revert push to prod to merge * Prepare deploy with different envs * Test dev deploy * Test secrets * Add env vars for deploy * Fix if * Split dev and prod * Comment test phase * Disable beta command (#18) * Comment beta command * Modify tests * Add logging decorator (#20) * Add logging decorator * Test log in az dev * Test in developent environment * Change policy (#23) * Change policy * Disable push in pull request * Fix lintern problems * Comment logger --------- * Akotadi/update common rules (#25) * Update pre-commit and fix issues * Fix issues * Remove eof * Update pre-commit and address comments * Add readme env variables * Linter * Add documentation for command * Disable logging (#32) --------- Co-authored-by: Roberto <reyesfragosoroberto@gmail.com> * Update new_user_joins.py * Fix env variables issues (#66) * Fix env variables issues (#67) * Create send message util (#68) # Description ### Context Currently the hiring timelines announcements depends on an ENV variable to send the message, that approach is not extensible to other guilds and other channels, and is not maintainable in the time. Because of that we're migrating the configuration to the database. ### This diff * Create a send message util to use the embed and catch any errors to avoid repetitive code ### Incoming diffs * Add announcement config model * Update the hiring timeline command to use the new configuration from the database # Type of change - [ ] Bug fix (non-breaking change which fixes an issue) - [x] New feature (non-breaking change which adds functionality) - [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected) - [ ] Documentation update # How Has This Been Tested? Added unit test # Checklist: - [x] I have commented my code, particularly in hard-to-understand areas - [x] My changes generate no new warnings - [x] I have added tests that prove my fix is effective or that my feature works * Add role config model (#71) # Description ### Context Currently giving the base role (`OTTER_ROLE`) depends on an ENV variable when a user reacts to the message, that approach is not extensible to other guilds and other channels, and is not maintainable in the time. Because of that we're migrating the configuration to the database. ### This diff * Add base role config model ### Incoming diffs * Add welcome messages role command * Update `on_raw_reaction_add` event to use the database data # Type of change - [ ] Bug fix (non-breaking change which fixes an issue) - [x] New feature (non-breaking change which adds functionality) - [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected) - [ ] Documentation update # How Has This Been Tested? Added unit tests # Checklist: - [x] I have commented my code, particularly in hard-to-understand areas - [x] My changes generate no new warnings - [x] I have added tests that prove my fix is effective or that my feature works * Add welcome messages role command (#72) # Description ### Context Currently giving the base role (`OTTER_ROLE`) depends on an ENV variable when a user reacts to the message, that approach is not extensible to other guilds and other channels, and is not maintainable in the time. Because of that we're migrating the configuration to the database. ### This diff * Add welcome messages role command ### Incoming diffs * Update `on_raw_reaction_add` event to use the database data # Type of change - [ ] Bug fix (non-breaking change which fixes an issue) - [x] New feature (non-breaking change which adds functionality) - [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected) - [ ] Documentation update # How Has This Been Tested? Manually tested on a test server # Checklist: - [x] I have commented my code, particularly in hard-to-understand areas - [x] My changes generate no new warnings - [x] I have added tests that prove my fix is effective or that my feature works * Update on_reaction_add to use database data (#73) # Description ### Context Currently giving the base role (`OTTER_ROLE`) depends on an ENV variable when a user reacts to the message, that approach is not extensible to other guilds and other channels, and is not maintainable in the time. Because of that we're migrating the configuration to the database. ### This diff * Update `on_raw_reaction_add` event to use the database data # Type of change - [ ] Bug fix (non-breaking change which fixes an issue) - [x] New feature (non-breaking change which adds functionality) - [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected) - [ ] Documentation update # How Has This Been Tested? Updated unit tests and manually tested on a test server # Checklist: - [x] I have commented my code, particularly in hard-to-understand areas - [x] My changes generate no new warnings - [x] I have added tests that prove my fix is effective or that my feature works * Update hiring timeline cog to use db model (#70) # Description ### Context Currently the hiring timelines announcements depends on an ENV variable to send the message, that approach is not extensible to other guilds and other channels, and is not maintainable in the time. Because of that we're migrating the configuration to the database. ### This diff * Update the hiring timeline command to use the new configuration from the database # Type of change - [ ] Bug fix (non-breaking change which fixes an issue) - [x] New feature (non-breaking change which adds functionality) - [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected) - [ ] Documentation update # How Has This Been Tested? Tested manually in a test server # Checklist: - [x] I have commented my code, particularly in hard-to-understand areas - [x] My changes generate no new warnings - [ ] I have added tests that prove my fix is effective or that my feature works * Add graphql service (#80) # Description Adding a new handler to send graphql requests, this will be used to communicate with leetcode # Type of change - [ ] Bug fix (non-breaking change which fixes an issue) - [x] New feature (non-breaking change which adds functionality) - [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected) - [ ] Documentation update # How Has This Been Tested? Locally tested using the terminal and added some unit tests as well. # Checklist: - [x] I have commented my code, particularly in hard-to-understand areas - [x] My changes generate no new warnings - [x] I have added tests that prove my fix is effective or that my feature works * Akotadi/create-leetcode-handler (#81) # Description Add a new handler for leetcode requests, currently only use two methods to retrieve the user profile and the daily challenge. Confirmed the queries using the [leetcode-playground](https://akotadi.github.io/leetcode-playground/). The schema used was retrieved using reverse-engineering from the queries used on the leetcode website. # Type of change - [ ] Bug fix (non-breaking change which fixes an issue) - [x] New feature (non-breaking change which adds functionality) - [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected) - [ ] Documentation update # How Has This Been Tested? Manually tested and added unit tests for it. # Checklist: - [x] I have commented my code, particularly in hard-to-understand areas - [x] My changes generate no new warnings - [x] I have added tests that prove my fix is effective or that my feature works * [Fix] Rename graphql to gql_service (#84) # Description Naming graphql to the folder is causing issues ([example](graphql-python/gql#224 (comment))), I'm renaming it to fix the issue # Type of change - [x] Bug fix (non-breaking change which fixes an issue) - [ ] New feature (non-breaking change which adds functionality) - [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected) - [ ] Documentation update # How Has This Been Tested? No warnings + manually ran bot # Checklist: - [ ] I have commented my code, particularly in hard-to-understand areas - [x] My changes generate no new warnings - [ ] I have added tests that prove my fix is effective or that my feature works * Add leetcode gql schemas (#82) # Description Adding schemas to be used with [pydantic](https://docs.pydantic.dev/latest/) during the next PR, this will give structure to the graphql response received. Also updated discord.py version to 2.4.0 and fixed a test because of that update. # Type of change - [ ] Bug fix (non-breaking change which fixes an issue) - [x] New feature (non-breaking change which adds functionality) - [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected) - [ ] Documentation update # How Has This Been Tested? Not required, to be tested during the next PR when used. # Checklist: - [x] I have commented my code, particularly in hard-to-understand areas - [x] My changes generate no new warnings - [ ] I have added tests that prove my fix is effective or that my feature works * Type leetcode responses (#83) # Description Following the previous diff, used [pydantic](https://docs.pydantic.dev/latest/) to return the leetcode response as a typed classes. # Type of change - [ ] Bug fix (non-breaking change which fixes an issue) - [x] New feature (non-breaking change which adds functionality) - [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected) - [ ] Documentation update # How Has This Been Tested? Manually tested and added unit tests for it. # Checklist: - [x] I have commented my code, particularly in hard-to-understand areas - [x] My changes generate no new warnings - [x] I have added tests that prove my fix is effective or that my feature works * Create leetcode cog (#85) # Description Adding a new leetcode command group, used for leetcode related features. Currently just added one command to start publishing the daily challenge problem. ``` leetcode daily_challenge start <text_channel>: Configure daily challenge announcements leetcode daily_challenge stop: Stop daily challenge announcements leetcode daily_challenge run check: Manually trigger the daily challenge check leetcode daily_challenge run start_task: Start the daily challenge task leetcode daily_challenge run stop_task: Stop the daily challenge task ``` ![image](https://github.com/user-attachments/assets/dc643bb8-e550-4eba-bb5d-0dc1572c6a93) # Type of change - [ ] Bug fix (non-breaking change which fixes an issue) - [x] New feature (non-breaking change which adds functionality) - [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected) - [ ] Documentation update # How Has This Been Tested? Manually tested on a discord server. # Checklist: - [x] I have commented my code, particularly in hard-to-understand areas - [x] My changes generate no new warnings - [ ] I have added tests that prove my fix is effective or that my feature works * Fix poetry version on Docker (#86) # Description As title # Type of change - [x] Bug fix (non-breaking change which fixes an issue) - [ ] New feature (non-breaking change which adds functionality) - [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected) - [ ] Documentation update # How Has This Been Tested? Locally ran docker build # Checklist: - [ ] I have commented my code, particularly in hard-to-understand areas - [x] My changes generate no new warnings - [ ] I have added tests that prove my fix is effective or that my feature works --------- Co-authored-by: goberinfinity <reyesfragosoroberto@gmail.com>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
Context
In order to improve the system we'll go back to using a database that can be accessed easily from different places. The previous Sqlite3 database will be used just as "cache" on the bot, while MongoDB will be set up to be used widely.
This diff
Incoming diffs
Type of change
How Has This Been Tested?
Locally tested to see that is working fine
Checklist: