Skip to content

Commit

Permalink
fix: build error & typo
Browse files Browse the repository at this point in the history
  • Loading branch information
yupix committed Feb 20, 2024
1 parent 303c415 commit bef5c6f
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 8 deletions.
2 changes: 1 addition & 1 deletion mipac/manager/blocking.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
from mipac.manager.client import ClientManager


class ClinetBlockingManager(BlockingActions):
class ClientBlockingManager(BlockingActions):
def __init__(self, user_id: str, *, session: HTTPClient, client: ClientManager):

Check warning on line 14 in mipac/manager/blocking.py

View workflow job for this annotation

GitHub Actions / Qodana Community for Python

Missed call to '__init__' of the super class

Call to __init__ of super class is missed

Check warning on line 14 in mipac/manager/blocking.py

View workflow job for this annotation

GitHub Actions / Qodana Community for Python

Missed call to '__init__' of the super class

Call to __init__ of super class is missed
self.__action: ClientBlockingActions = ClientBlockingActions(
user_id=user_id, session=session, client=client
Expand Down
8 changes: 4 additions & 4 deletions mipac/manager/user.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
from mipac.abstract.manager import AbstractManager
from mipac.actions.user import ClientUserActions, UserActions

Check notice on line 6 in mipac/manager/user.py

View workflow job for this annotation

GitHub Actions / Qodana Community for Python

Accessing a protected member of a class or a module

'ClientUserActions' is not declared in __all__

Check notice on line 6 in mipac/manager/user.py

View workflow job for this annotation

GitHub Actions / Qodana Community for Python

Accessing a protected member of a class or a module

'ClientUserActions' is not declared in __all__
from mipac.http import HTTPClient
from mipac.manager.blocking import BlockingManager, ClinetBlockingManager
from mipac.manager.blocking import BlockingManager, ClientBlockingManager
from mipac.manager.follow import FollowManager
from mipac.manager.users.list import (
ClientPartialUserListManager,
Expand Down Expand Up @@ -33,7 +33,7 @@ def __init__(self, user: PartialUser, *, session: HTTPClient, client: ClientMana
self.mute: ClientMuteManager = ClientMuteManager(
user_id=user.id, session=session, client=client
)
self.block = ClinetBlockingManager(user_id=user.id, session=session, client=client)
self.block = ClientBlockingManager(user_id=user.id, session=session, client=client)
self.list = ClientPartialUserListManager(user_id=user.id, session=session, client=client)

@property
Expand All @@ -58,5 +58,5 @@ def action(self) -> UserActions:
def _create_client_user_list_manager(self, list_id: str) -> ClientUserListManager:
return ClientUserListManager(list_id=list_id, session=self.__session, client=self.__client)

def _create_client_blocking_manager(self, user_id: str) -> ClinetBlockingManager:
return ClinetBlockingManager(user_id=user_id, session=self.__session, client=self.__client)
def _create_client_blocking_manager(self, user_id: str) -> ClientBlockingManager:
return ClientBlockingManager(user_id=user_id, session=self.__session, client=self.__client)
6 changes: 3 additions & 3 deletions mipac/models/blocking.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,13 @@
from datetime import datetime
from typing import TYPE_CHECKING, Any

from mipac.manager.blocking import ClinetBlockingManager
from mipac.models.user import UserDetailedNotMe, packed_user

Check notice on line 6 in mipac/models/blocking.py

View workflow job for this annotation

GitHub Actions / Qodana Community for Python

Accessing a protected member of a class or a module

'packed_user' is not declared in __all__

Check notice on line 6 in mipac/models/blocking.py

View workflow job for this annotation

GitHub Actions / Qodana Community for Python

Accessing a protected member of a class or a module

'UserDetailedNotMe' is not declared in __all__

Check notice on line 6 in mipac/models/blocking.py

View workflow job for this annotation

GitHub Actions / Qodana Community for Python

Accessing a protected member of a class or a module

'packed_user' is not declared in __all__

Check notice on line 6 in mipac/models/blocking.py

View workflow job for this annotation

GitHub Actions / Qodana Community for Python

Accessing a protected member of a class or a module

'UserDetailedNotMe' is not declared in __all__
from mipac.types.blocking import IBlocking
from mipac.utils.format import str_to_datetime

if TYPE_CHECKING:
from mipac.manager.client import ClientManager
from mipac.manager.blocking import ClientBlockingManager


class Blocking:
Expand Down Expand Up @@ -65,12 +65,12 @@ def _get(self, key: str) -> Any | None:
return self.__raw_blocking.get(key)

@property
def api(self) -> ClinetBlockingManager:
def api(self) -> ClientBlockingManager:
"""ブロック対象に対するAPIを利用するためのManager
Returns
-------
ClinetBlockingManager
ClientBlockingManager
ブロック対象に対するAPIを利用するためのManager
"""
return self.__client.user._create_client_blocking_manager(user_id=self.blockee.id)

Check notice on line 76 in mipac/models/blocking.py

View workflow job for this annotation

GitHub Actions / Qodana Community for Python

Accessing a protected member of a class or a module

Access to a protected member _create_client_blocking_manager of a class

Check notice on line 76 in mipac/models/blocking.py

View workflow job for this annotation

GitHub Actions / Qodana Community for Python

Accessing a protected member of a class or a module

Access to a protected member _create_client_blocking_manager of a class
Expand Down

0 comments on commit bef5c6f

Please sign in to comment.