Skip to content

Commit

Permalink
Relax Converter type on configure_tagged_union
Browse files Browse the repository at this point in the history
  • Loading branch information
VincentVanlaer committed Jan 22, 2024
1 parent 4ab2815 commit 074fa61
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
2 changes: 2 additions & 0 deletions HISTORY.md
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,8 @@ Our backwards-compatibility policy can be found [here](https://github.com/python
- The documentation has been significantly reworked.
([#473](https://github.com/python-attrs/cattrs/pull/473))
- The docs now use the Inter font.
- Make type annotations for `include_subclasses` and `tagged_union` more lenient.
([#431](https://github.com/python-attrs/cattrs/pull/431))

## 23.2.3 (2023-11-30)

Expand Down
4 changes: 2 additions & 2 deletions src/cattrs/strategies/_unions.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

from attrs import NOTHING

from cattrs import BaseConverter, Converter
from cattrs import BaseConverter
from cattrs._compat import get_newtype_base, is_literal, is_subclass, is_union_type

__all__ = [
Expand All @@ -20,7 +20,7 @@ def default_tag_generator(typ: Type) -> str:

def configure_tagged_union(
union: Any,
converter: Converter,
converter: BaseConverter,
tag_generator: Callable[[Type], str] = default_tag_generator,
tag_name: str = "_type",
default: Optional[Type] = NOTHING,
Expand Down

0 comments on commit 074fa61

Please # to comment.