3 Commits

Author SHA1 Message Date
Abigail 38416d9050 whoopsie 2020-02-20 20:02:45 -05:00
Abigail G 8dcdc22fe4 Merge pull request #202 from miaowware/hamstudy-extra-fix
fix offset-naive and offset-aware datetime conflict
2020-02-20 20:02:07 -05:00
Abigail c57056e586 fix offset-naive and offset-aware datetime conflict
Fixes #201
2020-02-20 01:32:17 -05:00
3 changed files with 9 additions and 3 deletions
+5
View File
@@ -7,6 +7,11 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/).
## [Unreleased] ## [Unreleased]
## [2.2.1] - 2020-02-20
### Fixed
- Fixed issue where some HamStudy pools will become unselectable.
## [2.2.0] - 2020-02-15 ## [2.2.0] - 2020-02-15
### Added ### Added
- Added Trustee field to qrz command for club callsigns. - Added Trustee field to qrz command for club callsigns.
+3 -2
View File
@@ -14,6 +14,7 @@ from datetime import datetime
import asyncio import asyncio
import aiohttp import aiohttp
import pytz
import discord.ext.commands as commands import discord.ext.commands as commands
@@ -88,8 +89,8 @@ class StudyCog(commands.Cog):
else: else:
# look at valid_from and expires dates to find the correct one # look at valid_from and expires dates to find the correct one
for p in pool_matches: for p in pool_matches:
valid_from = datetime.fromisoformat(pools[p]["valid_from"][:-1] + "+00:00") valid_from = datetime.fromisoformat(pools[p]["valid_from"][:-1])
expires = datetime.fromisoformat(pools[p]["expires"][:-1] + "+00:00") expires = datetime.fromisoformat(pools[p]["expires"][:-1])
if valid_from < datetime.utcnow() < expires: if valid_from < datetime.utcnow() < expires:
pool = p pool = p
+1 -1
View File
@@ -12,5 +12,5 @@ authors = ("@ClassAbbyAmplifier#2229", "@0x5c#0639")
description = """A bot with various useful ham radio-related functions, written in Python.""" description = """A bot with various useful ham radio-related functions, written in Python."""
license = "Released under the GNU General Public License v2" license = "Released under the GNU General Public License v2"
contributing = "Check out the source on GitHub, contributions welcome: https://github.com/miaowware/qrm2" contributing = "Check out the source on GitHub, contributions welcome: https://github.com/miaowware/qrm2"
release = "2.2.0" release = "2.2.1"
bot_server = "https://discord.gg/Ntbg3J4" bot_server = "https://discord.gg/Ntbg3J4"