aboutsummaryrefslogtreecommitdiffstats
path: root/bot/help.py (unfollow)
Commit message (Collapse)AuthorLines
2020-03-18Deseasonify: remove excessive info embed informationGravatar kwzrd-8/+2
Previously we were showing the entire queue of coming-up icons. As we're now showing full paths (rather than just filenames), this creates a lot of visual clutter that is unnecessary. It's not critical to know in which order the icons will be cycled, as there's no way for us to affect it anyway. This list of all available icons is still displayed above. The information about configured cycle frequency goes in the footer, if we're cycling.
2020-03-18Deseasonify: refer to bot icons as avatarsGravatar kwzrd-1/+1
There is an annoying collision in the "server icon" vs "bot icon" nomenclature, so I made the decision to always refer to the bot's image as avatar. This choice is already visible through the module, we only need to adjust the actual filename that we're looking for. The filenames will be adjusted in the branding repository.
2020-03-18Deseasonify: make asset filenames module constantsGravatar kwzrd-7/+11
Less error-prone; easier to adjust.
2020-03-18Deseasonify: fallback on evergreen on incomplete brandingGravatar kwzrd-3/+23
The previous implementation would simply ignore assets not present in the current season's directory. On the condition that at least one asset is missing, and the current season is not the evergreen, we also poll the evergreen directory, and use it as fallback. This behaviour is shielded such that we only make the extra API call if there is a missing asset, i.e. if there is something to be gained.
2020-03-18Deseasonify: keep track of `path` on github filesGravatar kwzrd-11/+7
Since the banner and avatar assets will always have the same filename, we need their full paths to differentiate between assets of different seasons. Rather than introducing more complexity to the `pretty_files` function and deconstructing the download urls, we can just store the path as provided by the API. We also now print the `path` instead of showing bools in the status embed, as just the fact that there is some banner is not enough information - we want to know which season's banner has been picked up during refresh.
2020-03-17Deseasonify: allow `set` to take multi-word argsGravatar kwzrd-1/+1
We do not have any multi-word seasons at the moment, but there is no reason to restrict the command to just one word.
2020-03-17Deseasonify: improve `SeasonBase` docstring wordingGravatar kwzrd-2/+2
2020-03-15Deseasonify: relax type annotationGravatar kwzrd-1/+1
Asyncio's sleep will accept both, and we default to an int, so might as well not break our own promise.
2020-03-15Deseasonify: remove fragile attr dependency in `seasonal_task`Gravatar kwzrd-6/+5
Importing the bot instance will allow us to safely access the `wait_until_ready` method without having to make fragile assumptions about the arguments passed to the decorated method. Although still not perfect, this feels a lot cleaner and safer than the previous approach.
2020-03-15Deseasonify: move the branding module from seasons to bot directoryGravatar kwzrd-0/+0
It makes more sense for it to be positioned alongside other core bot features.
2020-03-15Deseasonify: apply seasonal task mechanism to tasks as appropriateGravatar kwzrd-21/+6
2020-03-15Deseasonify: add convenience decorator for seasonal tasksGravatar kwzrd-0/+39
See docstring for implementation details.
2020-03-15Deseasonify: season-lock listeners where appropriateGravatar kwzrd-1/+8
We want to prevent listeners from performing season-specific behaviour outside of specific months.
2020-03-15Deseasonify: add listener decorator for season lockingGravatar kwzrd-0/+22
A guarded listener will abort if the triggering event happens outside of `allowed_months`. This provides a convenient way of season-locking listeners without having to write guards directly within their bodies.
2020-03-15Deseasonify: improve `in_month` command checkGravatar kwzrd-4/+15
Raise a custom exception if the command fails. This is then handled in the error handler, and the user will be informed of which months allow the invoked command.
2020-03-15Deseasonify: lock branding commands to moderation rolesGravatar kwzrd-1/+3
2020-03-15Deseasonify: use more descriptive name for `Record` namedtupleGravatar kwzrd-15/+15
2020-03-14Deseasonify: improve logic in `set` commandGravatar kwzrd-14/+15
Prevent re-applying branding if the user requests an already active season. This saves us an expensive operation. Only trigger typing if season switch was successful and `apply` will be called, as otherwise the bot will respond immediately.