aboutsummaryrefslogtreecommitdiffstats
path: root/tests/base.py (unfollow)
Commit message (Collapse)AuthorLines
2020-05-01Added on cog unload news posting tasks canceling on `News` cogGravatar ks129-0/+5
2020-05-01Replace message ID storage to new specific ID storage in `News` cogGravatar ks129-38/+6
- Removed (now) unnecessary helper function `News.check_new_exist`. - Use thread IDs instead message IDs on maillists checking to avoid Discord API calls. - Use PEP number instead message IDs on PEP news checking to avoid Discord API calls.
2020-04-28Simplified New publishing check + removed unnecessary Webhook checkGravatar ks129-6/+2
- Replaced type checking with `TextChannel.is_news()` for simplification to check is possible to publish new - Removed unnecessary `while` loop on `send_webhook` that check is webhook available. No need for this after starting ordering modification.
2020-04-27Minor terminology change on a logGravatar Joseph Banks-1/+1
2020-04-27Make some fixes to ensure data is persisted and the bot does not hangGravatar Joseph Banks-3/+22
2020-04-27Add Python News channel and webhook ID to config-default.ymlGravatar ks129-2/+2
Co-Authored-By: Joseph <[email protected]>
2020-04-27Fixed `BeautifulSoup` parsing warningGravatar ks129-1/+1
Added `features="lxml"` to `BeautifulSoup` class creating to avoid warning.
2020-04-27Improved `News` cogGravatar ks129-10/+22
- Added footer to webhook sent message - Made `send_webhook` return `discord.Message` instead ID of message - Added waiting for Webhook on `send_webhook` - Added message publishing in new loops
2020-04-21Simplified title check even more in PEP newsGravatar ks129-1/+1
2020-04-21`News` Cog improvisationsGravatar ks129-37/+36
- Created new helper function `News.get_webhook_and_channel` to will be run in Cog loading and will fetch #python-news channel and webhook. - Fixed `News.send_webhook` when you pass `None` as author, this will not add author. - Replaced individual channel and webhook fetches with `News.webhook` and `News.channel`. - Replaced positional arguments with kwargs in `send_webhook` uses. - Moved maillists syncing from `News.__init__` to `News.post_maillist_news`. - Simplified `News.post_pep_news` already exist checks.
2020-04-20Implemented maillists news posting, created helper functions + added date checkGravatar ks129-19/+131
- Created helper function `News.get_thread_and_first_mail` - Created helper function `News.send_webhook` - Created helper function `News.check_new_exist` - Task `post_maillist_news`, that send latest maillist threads to news, when they don't exist. - Implemented helper functions to PEP news - Added date check
2020-04-20Defined `chardet` log level to warning to avoid spamGravatar ks129-0/+1
2020-04-20Added new dependency `beatifulsoup4` for Python news HTML parsingGravatar ks129-1/+3
2020-04-20Added new function `News.get_webhook_names` + new variable `News.webhook_names`Gravatar ks129-0/+13
Function fetch display names of these mail lists, that bot will post. These names will be used on Webhook author names. `News.webhook_names` storage these name and display name pairs.
2020-04-20Created PEP news task + minor changes in `News`Gravatar ks129-4/+69
- Created task `post_pep_news` that pull existing news message IDs from API, do checks and send new PEP when it's not already sent. - Removed `get_webhook` - Removed `self.webhook`
2020-04-20Applied constant changes to NewsGravatar ks129-8/+2
Replaced in-file mail lists with constants.py's, replaced webhook ID getting.
2020-04-20Applied Python News config changesGravatar ks129-2/+8
Removed Webhook and Channel from their listings, created new class `PythonNews` that hold them + mail lists.
2020-04-20Added new category `python_news` to config, that hold mail lists, channel ↵Gravatar ks129-5/+15
and webhook. This use local dev environment IDs.
2020-04-20Created helper function `get_webhook` and added property in `News`Gravatar ks129-1/+8
`News.get_webhook` fetch discord.Webhook by ID provided in config. `self.webhook` use webhook that it got from this function.
2020-04-20Added #python-news channel webhook to `Webhooks` in constantsGravatar ks129-0/+1
2020-04-20Added new dependency `feedparser`Gravatar ks129-48/+58
2020-04-20Added helper function `News.sync_maillists`Gravatar ks129-0/+23
Function sync maillists listing with API, that hold IDs of message that have news. PEPs handling is over RSS, so this will added manually in this function.
2020-04-20Added `News` cog loadingGravatar ks129-0/+1
2020-04-20Added #python-news channel ID to constants `Channels`Gravatar ks129-0/+1