time.perf_counter() issues, vault_updater bug fix, and moving to f-strings (amongst other cosmetic changes)#49
time.perf_counter() issues, vault_updater bug fix, and moving to f-strings (amongst other cosmetic changes)#49CobraCoral wants to merge 6 commits intoMalarne:masterfrom
Conversation
Switched to time.time() as time.perf_counter() is not supposed to be
persisted and checked again after long (>1min) periods of time
- Fixed oob not being set to True when a player was bailed out
- Fixed cosmetic issue when player_time is 0 (should be checked first)
- Added a unique_id for !heist play, to fix a small issue where if a player started a heist, and then
immediately did !heist play again, he would be added to his own
heist as if he was a crew member
- Added f-strings everywhere to make code more readable
- Fixed bug on vaulter_updater (it was trying to access the key which is
a string as if it was the dictionary)
|
You should check with repo maintainers before making cosmetic choices, for example fstrings breaks any potential for i18n support that they may or may not be wanting to add in the future. |
|
Good point. I could try to split the bug fixes in their own commit and the f-strings in a separate commit if so desired by the repo maintainer. I will wait to see what they say first though, thanks for your input. |
|
heist.py line 142 ctx.prefix for i18n support, i really need to take time to rewrite this entire cog so, for now, not planned until then. |
|
@Malarne so do you want me to fix those open items before you merge? Thanks! |
|
yeah please |
Switched to time.time() as time.perf_counter() is not supposed to be
persisted and checked again after long (>1min) periods of time
immediately did !heist play again, he would be added to his own
heist as if he was a crew member
a string as if it was the dictionary)