| Commit message (Collapse) | Author | Lines | ||
|---|---|---|---|---|
| 2021-03-30 | HelpChannels: refactor get_closing_time | -43/+43 | ||
| 2021-03-30 | HelpChannels: use aware datetimes everywhere | -27/+34 | ||
| Fix issues converting timestamps to datetimes and vice-versa. The main culprit id `datetime.timestamp()`, which always assumes naïve objects are in local time. That behaviour conflicts with discord.py, which returns naïve objects in UTC rather than local time. Switching from `utcfromtimestamp` to `fromtimestamp` was incorrect since the latter also assumes the timestamp is in local time. | ||||
| 2021-03-30 | Update arrow to 1.0.3 | -267/+336 | ||
| It has some API changes, so it's best to update now before the project starts using the library more. | ||||
| 2021-03-26 | Switch to datetime.fromtimestamp() to avoid over-compensation | -3/+3 | ||
| Previously we were using `utcfromtimestamp()` which would compensate the timestamp when converting to UTC even though the timestamp itself was in UTC: >>> datetime.utcnow() datetime.datetime(2021, 3, 26, 22, 8, 47, 441603) >>> a = datetime.utcnow().timestamp() 1616821624.207364 >>> a = datetime.utcfromtimestamp(a) datetime.datetime(2021, 3, 27, 5, 7, 4, 207364) By switching to `fromtimestamp()` this avoids that behaviour. | ||||
| 2021-03-26 | Use correct constant for each type of help session user | -5/+5 | ||
| 2021-03-26 | Add 1 second due to POSIX timestamps being lower resolution than datetime ↵ | -3/+5 | ||
| objects. | ||||
| 2021-03-26 | Fix error when converting non claimant message | -7/+10 | ||
| datetime.min cannot be converted to a timestamp as it's pre-epoch. Instead wait until we actuall need it and then create the correct datetime object depending on teh cache contents. | ||||
| 2021-03-25 | Convert to timestamp before posting to redis | -2/+2 | ||
| 2021-03-25 | Reset a channel's non-claimant cache on claim, to indicate that the session ↵ | -7/+9 | ||
| has yet to be answered. | ||||
| 2021-03-25 | Refactor if block within help channel system to be more readable | -6/+7 | ||
| 2021-03-25 | Refactor help channel update message cache function for clearer flow | -9/+8 | ||
| 2021-03-25 | Create utc datetime objects from timestamps | -4/+4 | ||
| 2021-03-25 | Change help channel caching logic to use timezone naive stamps | -3/+3 | ||
| 2021-03-25 | Only fetch claimant id once | -2/+3 | ||
| 2021-03-25 | update help channel on_message docstring to reflect unchanged responsibility | -6/+1 | ||
| 2021-03-25 | Schedule channels just opened using claimant configured idle time | -1/+1 | ||
| 2021-03-25 | Check for close on command explictly. | -1/+1 | ||
| 2021-03-25 | Remove unneeded cache clearing | -8/+0 | ||
| 2021-03-25 | Change help channel logic to use timezone naive stamps | -8/+6 | ||
| 2021-03-25 | Don't prepend command closes with auto | -2/+3 | ||
| 2021-03-24 | Add back seperation whitespace | -0/+1 | ||
| 2021-03-24 | Use claiment idle time as default idle minutes. | -1/+1 | ||
| 2021-03-24 | Use fallback behaviour during cog init | -5/+8 | ||
| 2021-03-20 | run precommit with all deps | -1/+1 | ||
| 2021-03-20 | passing pre-commit | -4/+11 | ||
| 2021-03-19 | reset cache on bot start, stats for different close reasons | -28/+39 | ||
| 2021-03-18 | More descriptive comment for when an if block is entered | -1/+1 | ||
| 2021-03-18 | Determine closing time from last message if either cache is empty, rather ↵ | -2/+2 | ||
| than if both are empty | ||||
| 2021-03-18 | If the channel is empty, determine closing time based on last message. | -4/+5 | ||
| 2021-03-18 | Move return behaviour comments to in-line rather than docstring. | -8/+4 | ||
| 2021-03-18 | Delete cached claimant message time. | -0/+1 | ||
| 2021-03-18 | Update function name to describe new behaviour. | -3/+3 | ||
| Also updates the doc string to reflect this new behaviour. | ||||
| 2021-03-18 | Repurpose unanswered cache for storing non-claimant last message times | -59/+48 | ||
| The unanswered cache was previously just a boolen of whether a non-claimant every replied to a help channel. With us now needing to know the time at which a non-claimant messaged in a given channel, we infer the answered status from this cache instead. | ||||
| 2021-03-17 | Improve docs strings and variable names within the help channel system | -20/+20 | ||
| 2021-03-17 | Improve availible channel embed footer | -1/+1 | ||
| 2021-03-16 | Improve trace message. | -1/+1 | ||
| 2021-03-16 | Extend close time logic to differentiate between the claimant and other users. | -29/+75 | ||
| 2021-03-16 | Update help availible footer | -1/+1 | ||
| As we have complicated this logic, we now don't specify exactly how long until the channel will close. | ||||
| 2021-03-16 | Set a reasonable default for `idle_minutes_others`. | -1/+1 | ||
| 2021-03-16 | Split out help channel idle time constants | -3/+8 | ||
| This allows us to configure the idle time allowed for claiments seperate from tohers. | ||||
| 2021-03-15 | Info: account for defcon threshold being None | -1/+2 | ||
| Fixes BOT-XK | ||||
| 2021-03-15 | Defcon: fix naming conflict between threshold cmd and attribute | -2/+2 | ||
| 2021-03-13 | Use .gitattributes to normalise line endings on check-in | -2/+1 | ||
| Remove the mixed line endings pre-commit hook because it is obsolete. Relying on git to handle line endings means contributors have more flexibility with which line endings they want to use on check-out. The settings in .gitattributes only impose which line endings will be used upon check-in (LF), which should not impact local development; git will still respect the core.eol and core.autocrlf settings. | ||||
| 2021-03-13 | master => main | -22/+22 | ||
| 2021-03-13 | Update help channel names from chemical elements to fruit | -126/+59 | ||
| * Update and rename elements.json to fruits.json * Update _name.py * Update _cog.py | ||||
| 2021-03-12 | Added '_' to allowed chars, shortened embed. | -21/+12 | ||
| 2021-03-12 | Fix typo in the token remover | -1/+1 | ||
| 2021-03-11 | Remove invoked command and message after failure. | -27/+35 | ||
| 2021-03-12 | Compose: read all environment variables from '.env' | -4/+2 | ||
| 2021-03-11 | Compose: read GitHub API key from '.env' | -0/+1 | ||