Convert our `Empty` class usage to `typing_extensions.Sentinel`
featuregood first issuehelp wanted
Current way: https://github.com/wemake-services/django-modern-rest/blob/5ca7975fb54112432769fe0b267773409ba78201/dmr/types.py#L48-L55
New (modern) way: https://typing-extensions.readthedocs.io/en/latest/#typing_extensions.Sentinel
1. We need to change how `EmptyObj` is defined to be `EMPTY: Final = Sentinel('EMPTY')`
2. We need to change all `isinstance(..., Empty)` to check for the sentinel
This is a very easy task for new contributors :)
3 条评论