Skip to content

Commit

Permalink
Fix ruff errors
Browse files Browse the repository at this point in the history
  • Loading branch information
SeoulSKY committed Aug 30, 2024
1 parent abcadd6 commit b1534b7
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 2 deletions.
2 changes: 2 additions & 0 deletions tests/history/__init__.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
"""Contains the utility functions for testing."""

from datetime import UTC, datetime

from ytnoti import Channel, Timestamp, Video
Expand Down
2 changes: 2 additions & 0 deletions tests/history/test_inmemory.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
"""Test class InMemoryFileHistory."""

import pytest

from tests.history import get_video
Expand Down
2 changes: 2 additions & 0 deletions tests/test_errors.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
"""Test errors."""

from http import HTTPStatus

from ytnoti.errors import HTTPError
Expand Down
5 changes: 3 additions & 2 deletions ytnoti/models/history.py
Original file line number Diff line number Diff line change
Expand Up @@ -91,9 +91,10 @@ class FileVideoHistory(VideoHistory):
def __init__(self, *, dir_path: str | PathLike[str], num_videos: int = 100) -> None:
"""Create a new FileVideoHistory instance.
:param dir_path: The path to the directory to store the history files
:param dir_path: The path to the directory to store the history files.
:param num_videos: The number of videos to keep in the history file.
If the number of videos exceeds this value, the oldest videos will be removed.
If the number of videos exceeds this value, the oldest videos will be
removed.
"""
self._logger = logging.getLogger(self.__class__.__name__)
self._dir_path = Path(dir_path)
Expand Down

0 comments on commit b1534b7

Please sign in to comment.