Skip to content

Commit 782365b

Browse files
committed
PTHMINT-46: Fix ruff ANN204
1 parent 02e1d69 commit 782365b

File tree

23 files changed

+32
-29
lines changed

23 files changed

+32
-29
lines changed

pyproject.toml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -98,7 +98,6 @@ extend-safe-fixes = [
9898
"D415", # docstrings should end with a period, question mark, or exclamation point
9999
]
100100
ignore = [
101-
"ANN204",
102101
"ANN401",
103102
"ARG002",
104103
"B006",

src/multisafepay/api/base/abstract_manager.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ class AbstractManager:
1919
2020
"""
2121

22-
def __init__(self: "AbstractManager", client: Client):
22+
def __init__(self: "AbstractManager", client: Client) -> None:
2323
"""
2424
Initialize the AbstractManager with a Client instance.
2525

src/multisafepay/api/base/listings/listing.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55

66
# See the DISCLAIMER.md file for disclaimer details.
77

8-
from typing import Any, Dict, Generic, List, TypeVar
8+
from typing import Any, Dict, Generic, Iterator, List, TypeVar
99

1010
from pydantic.main import BaseModel
1111

@@ -29,7 +29,7 @@ def __init__(
2929
data: List[Any],
3030
class_type: type,
3131
**kwargs: Dict[str, Any],
32-
):
32+
) -> None:
3333
"""
3434
Initialize the Listing with data and a class type.
3535
@@ -53,7 +53,7 @@ def __init__(
5353

5454
super().__init__(data=elements)
5555

56-
def __iter__(self: "Listing"):
56+
def __iter__(self: "Listing") -> Iterator[T]:
5757
"""
5858
Return an iterator over the items in the listing.
5959
@@ -79,7 +79,7 @@ def __getitem__(self: "Listing", index: int) -> T:
7979
"""
8080
return self.data[index]
8181

82-
def __len__(self: "Listing"):
82+
def __len__(self: "Listing") -> int:
8383
"""
8484
Get the number of items in the listing.
8585

src/multisafepay/api/base/listings/listing_pager.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ def __init__(
2828
data: list,
2929
pager: Optional[Pager],
3030
class_type: type,
31-
):
31+
) -> None:
3232
"""
3333
Initialize the ListingPager with data, pager, and class type.
3434

src/multisafepay/api/base/response/custom_api_response.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ def __init__(
2626
self: "CustomApiResponse",
2727
data: Optional[Any],
2828
**kwargs: Dict[str, Any],
29-
):
29+
) -> None:
3030
"""
3131
Initialize the CustomApiResponse with optional data and additional keyword arguments.
3232

src/multisafepay/api/paths/auth/auth_manager.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ class AuthManager(AbstractManager):
2222
A manager class for handling authentication-related operations.
2323
"""
2424

25-
def __init__(self: "AuthManager", client: Client):
25+
def __init__(self: "AuthManager", client: Client) -> None:
2626
"""
2727
Initialize the CaptureManager with a client.
2828

src/multisafepay/api/paths/capture/capture_manager.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ class CaptureManager(AbstractManager):
2626
A class to manage capture operations.
2727
"""
2828

29-
def __init__(self: "CaptureManager", client: Client):
29+
def __init__(self: "CaptureManager", client: Client) -> None:
3030
"""
3131
Initialize the CaptureManager with a client.
3232

src/multisafepay/api/paths/categories/category_manager.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ class CategoryManager(AbstractManager):
2020
A manager class for handling category-related API requests.
2121
"""
2222

23-
def __init__(self: "CategoryManager", client: Client):
23+
def __init__(self: "CategoryManager", client: Client) -> None:
2424
"""
2525
Initialize the CategoryManager with a client.
2626

src/multisafepay/api/paths/gateways/gateway_manager.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ class GatewayManager(AbstractManager):
2828
Manages gateway-related operations.
2929
"""
3030

31-
def __init__(self: "GatewayManager", client: Client):
31+
def __init__(self: "GatewayManager", client: Client) -> None:
3232
"""
3333
Initialize the CategoryManager with a client.
3434

src/multisafepay/api/paths/issuers/issuer_manager.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ class IssuerManager(AbstractManager):
2424
Manager class for handling issuer-related operations.
2525
"""
2626

27-
def __init__(self: "IssuerManager", client: Client):
27+
def __init__(self: "IssuerManager", client: Client) -> None:
2828
"""
2929
Initialize the IssuerManager with a client.
3030

0 commit comments

Comments
 (0)