Skip to content

Commit

Permalink
[Hockey] Update for new API. (#328)
Browse files Browse the repository at this point in the history
* [Hockey] Reorganize core loops to utilize new API methods.
Start building around the new API.

* Get previews working.
Fix goals duplicate posting.
Make pickems, gdt, and gdc work on the new API system.
Restructure Schedule to more easily list specific days of games.

* Use GameType Enum properly.
Add header to requests.
Close session when cog is unloaded.

* Update Standings for new API.
Make schedule and games command work. These might require more work in the future.
Allow api schedule commands to specify a date.
  • Loading branch information
TrustyJAID authored Nov 13, 2023
1 parent 95a0073 commit 52af8ed
Show file tree
Hide file tree
Showing 15 changed files with 1,313 additions and 472 deletions.
2 changes: 2 additions & 0 deletions hockey/abc.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
from redbot.core import Config, commands
from redbot.core.bot import Red

from .api import HockeyAPI
from .game import Game
from .helper import (
DateFinder,
Expand Down Expand Up @@ -39,6 +40,7 @@ def __init__(self, *_args):
self.session: aiohttp.ClientSession
self.pickems_config: Config
self._ready: asyncio.Event
self.api: HockeyAPI

#######################################################################
# hockey_commands.py #
Expand Down
Loading

0 comments on commit 52af8ed

Please sign in to comment.