Skip to content

Commit

Permalink
removed unneeded tests and used relative imports
Browse files Browse the repository at this point in the history
  • Loading branch information
borolepratik committed Jan 24, 2024
1 parent ec95170 commit 8be7375
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 475 deletions.
9 changes: 5 additions & 4 deletions app/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
from fastapi.middleware.cors import CORSMiddleware
from fastf1.ergast import Ergast

from app.constants import (
from .constants import (
EVENT_SCHEDULE_DATETIME_DTYPE_LIST,
MAX_SUPPORTED_ROUND,
MAX_SUPPORTED_SESSION,
Expand All @@ -16,8 +16,8 @@
MIN_SUPPORTED_SESSION,
MIN_SUPPORTED_YEAR,
)
from app.models import HealthCheck, Results, Schedule, Standings
from app.utils import get_default_year
from .models import HealthCheck, Results, Schedule, Standings
from .utils import get_default_year

# fastf1.set_log_level("WARNING") # TODO use for production and staging

Expand Down Expand Up @@ -288,5 +288,6 @@ def get_results(
)
except KeyError as ke:
raise HTTPException(
status_code=status.HTTP_404_NOT_FOUND, detail=f". {str(ke)}"
status_code=status.HTTP_404_NOT_FOUND,
detail=f"Likely an error when fetching results data for a session that has yet to happen. {str(ke)}",
)
Loading

0 comments on commit 8be7375

Please sign in to comment.