diff --git a/CHANGELOG.md b/CHANGELOG.md index c96e44a..a282a93 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -8,6 +8,7 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/). ### Fixed - Issue where embeds would not work for users without avatars (#467). - Issue where embeds would show the wrong timezone. +- Several issues with `?call` caused by issues in a library (#466). ## [2.9.0] - 2023-01-13 diff --git a/exts/callsign.py b/exts/callsign.py index 4561494..89109fa 100644 --- a/exts/callsign.py +++ b/exts/callsign.py @@ -12,7 +12,6 @@ from typing import Dict import aiohttp from callsignlookuptools import QrzAsyncClient, CallsignLookupError, CallsignData -from callsignlookuptools.common.dataclasses import Trustee from discord.ext import commands @@ -74,7 +73,7 @@ class QRZCog(commands.Cog): embed.title = f"QRZ Data for {data.callsign}" embed.colour = cmn.colours.good embed.url = data.url - if data.image is not None and data.image.url is not None: + if data.image is not None: embed.set_thumbnail(url=data.image.url) for title, val in qrz_process_info(data).items(): @@ -101,9 +100,9 @@ def qrz_process_info(data: CallsignData) -> Dict: qsl = dict() if data.qsl is not None: qsl = { - "eQSL?": data.qsl.eqsl.name.title(), - "Paper QSL?": data.qsl.mail.name.title(), - "LotW?": data.qsl.lotw.name.title(), + "eQSL?": data.qsl.eqsl, + "Paper QSL?": data.qsl, + "LotW?": data.qsl.lotw, "QSL Info": data.qsl.info, } @@ -120,7 +119,7 @@ def qrz_process_info(data: CallsignData) -> Dict: "Aliases": ", ".join(data.aliases) if data.aliases else None, "Previous Callsign": data.prev_call, "License Class": data.lic_class, - "Trustee": data.trustee if data.trustee is not None and data.trustee != Trustee(None, None) else None, + "Trustee": data.trustee, "Born": data.born, } | qsl diff --git a/requirements.txt b/requirements.txt index 2feca24..3130a5f 100644 --- a/requirements.txt +++ b/requirements.txt @@ -2,7 +2,7 @@ py-cord~=2.3.2 aiohttp[speedups] ctyparser~=2.0 gridtools~=1.0 -callsignlookuptools[async]~=1.0 +callsignlookuptools[async]~=1.1 beautifulsoup4 pytz cairosvg