Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 11 additions & 1 deletion marshmallow_dataclass/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -91,6 +91,9 @@ def dataclass(
order: bool = False,
unsafe_hash: bool = False,
frozen: bool = False,
match_args=True,
kw_only=False,
slots=False,
base_schema: Optional[Type[marshmallow.Schema]] = None,
cls_frame: Optional[types.FrameType] = None,
) -> Type[_U]:
Expand All @@ -105,6 +108,9 @@ def dataclass(
order: bool = False,
unsafe_hash: bool = False,
frozen: bool = False,
match_args=True,
kw_only=False,
slots=False,
base_schema: Optional[Type[marshmallow.Schema]] = None,
cls_frame: Optional[types.FrameType] = None,
) -> Callable[[Type[_U]], Type[_U]]:
Expand All @@ -122,6 +128,9 @@ def dataclass(
order: bool = False,
unsafe_hash: bool = False,
frozen: bool = False,
match_args=True,
kw_only=False,
slots=False,
base_schema: Optional[Type[marshmallow.Schema]] = None,
cls_frame: Optional[types.FrameType] = None,
) -> Union[Type[_U], Callable[[Type[_U]], Type[_U]]]:
Expand Down Expand Up @@ -152,7 +161,8 @@ def dataclass(
"""
# dataclass's typing doesn't expect it to be called as a function, so ignore type check
dc = dataclasses.dataclass( # type: ignore
_cls, repr=repr, eq=eq, order=order, unsafe_hash=unsafe_hash, frozen=frozen
_cls, repr=repr, eq=eq, order=order, unsafe_hash=unsafe_hash, frozen=frozen, match_args=match_args,
kw_only=kw_only, slots=slots
)
if not cls_frame:
current_frame = inspect.currentframe()
Expand Down