This code in my Django project raises a false-positive error:
@classproperty
@override
def view_is_async(cls) -> bool: # noqa: N805 # pyright: ignore[reportIncompatibleVariableOverride] # pyrefly: ignore[bad-override]
"""We already know this in advance, no need to recalculate."""
# This is a part of the `django.View` API, so it must be there.
return cls.is_async is True
ERROR Class member `Controller.view_is_async` overrides a member in a parent class but is missing an `@override` decorator [missing-override-decorator]
--> dmr/controller.py:538:9
|
538 | def view_is_async(cls) -> bool: # noqa: N805 # pyright: ignore[reportIncompatibleVariableOverride] # pyrefly: ignore[bad-ove...
| ^^^^^^^^^^^^^
|
This only happens with 1.0.0 and preset = 'strict'
Link: https://github.com/wemake-services/django-modern-rest/blob/3fc6f921bf1e410fbf836117edb012bcbd763a54/dmr/controller.py#L536-L541
This code in my Django project raises a false-positive error:
This only happens with
1.0.0andpreset = 'strict'Link: https://github.com/wemake-services/django-modern-rest/blob/3fc6f921bf1e410fbf836117edb012bcbd763a54/dmr/controller.py#L536-L541