Skip to content

Commit

Permalink
Fix style issues. Rebase did not trigger pre-commit.
Browse files Browse the repository at this point in the history
  • Loading branch information
mvanderlee committed Mar 20, 2024
1 parent 4686736 commit 4b8ebbf
Showing 1 changed file with 15 additions and 9 deletions.
24 changes: 15 additions & 9 deletions marshmallow_dataclass/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -44,12 +44,11 @@ class User:
import warnings
from enum import Enum
from functools import lru_cache, partial
from typing import Any, Callable, Dict, FrozenSet, List, Mapping
from typing import NewType as typing_NewType
from typing import (
Any,
Callable,
Dict,
FrozenSet,
Generic,
List,
Mapping,
Expand Down Expand Up @@ -151,7 +150,8 @@ def dataclass(
frozen: bool = False,
base_schema: Optional[Type[marshmallow.Schema]] = None,
cls_frame: Optional[types.FrameType] = None,
) -> Type[_U]: ...
) -> Type[_U]:
...


@overload
Expand All @@ -164,7 +164,8 @@ def dataclass(
frozen: bool = False,
base_schema: Optional[Type[marshmallow.Schema]] = None,
cls_frame: Optional[types.FrameType] = None,
) -> Callable[[Type[_U]], Type[_U]]: ...
) -> Callable[[Type[_U]], Type[_U]]:
...


# _cls should never be specified by keyword, so start it with an
Expand Down Expand Up @@ -223,13 +224,15 @@ def decorator(cls: Type[_U], stacklevel: int = 1) -> Type[_U]:


@overload
def add_schema(_cls: Type[_U]) -> Type[_U]: ...
def add_schema(_cls: Type[_U]) -> Type[_U]:
...


@overload
def add_schema(
base_schema: Optional[Type[marshmallow.Schema]] = None,
) -> Callable[[Type[_U]], Type[_U]]: ...
) -> Callable[[Type[_U]], Type[_U]]:
...


@overload
Expand All @@ -238,7 +241,8 @@ def add_schema(
base_schema: Optional[Type[marshmallow.Schema]] = None,
cls_frame: Optional[types.FrameType] = None,
stacklevel: int = 1,
) -> Type[_U]: ...
) -> Type[_U]:
...


def add_schema(_cls=None, base_schema=None, cls_frame=None, stacklevel=1):
Expand Down Expand Up @@ -289,7 +293,8 @@ def class_schema(
*,
globalns: Optional[Dict[str, Any]] = None,
localns: Optional[Dict[str, Any]] = None,
) -> Type[marshmallow.Schema]: ...
) -> Type[marshmallow.Schema]:
...


@overload
Expand All @@ -299,7 +304,8 @@ def class_schema(
clazz_frame: Optional[types.FrameType] = None,
*,
globalns: Optional[Dict[str, Any]] = None,
) -> Type[marshmallow.Schema]: ...
) -> Type[marshmallow.Schema]:
...


def class_schema(
Expand Down

0 comments on commit 4b8ebbf

Please sign in to comment.