Skip to content

Commit

Permalink
fix linting
Browse files Browse the repository at this point in the history
Signed-off-by: ItsNeil17 <[email protected]>
  • Loading branch information
ItsNeil17 committed Jun 9, 2024
1 parent 61a519c commit cc35c97
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 5 deletions.
2 changes: 0 additions & 2 deletions backend/__init__.py
Original file line number Diff line number Diff line change
@@ -1,2 +0,0 @@
from .route import Route
from .api import API
2 changes: 2 additions & 0 deletions backend/api.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,8 @@
from models import Player, Alliance
from .exceptions import AccessForbidden, ValidationError

__all__ = ("API",)


class API:
def __init__(self, api_key: str):
Expand Down
2 changes: 2 additions & 0 deletions backend/exceptions.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
from __future__ import annotations

__all__ = ("BackendException", "AccessForbidden", "ValidationError")


class BackendException(BaseException):
"""Base exception for all exceptions in this module"""
Expand Down
6 changes: 3 additions & 3 deletions backend/route.py
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
import requests # this is a synchronous application
from models import Player, Alliance
__all__ = "Route"

API_URL = "https://api.willofsteel.me"


class Route:
def __init__(self, path, method):
self.path = API_URL + path
Expand All @@ -18,4 +18,4 @@ def __eq__(self, other):
return self.path == other.path and self.method == other.method

def __hash__(self):
return hash((self.path, self.method))
return hash((self.path, self.method))

0 comments on commit cc35c97

Please sign in to comment.