You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[1.10/11] Regression with Any in functools.wraps() #17171
aiojobs/aiohttp.py:50:5: error: Type of decorated function contains type "Any"
("_Wrapped[[_RequestView], Coroutine[object, object, _T], [_RequestView], Coroutine[Any, Any, _T]]")
[misc]
async def wrapper(request_or_view: _RequestView) -> _T:
^
It appears to me the problem is that the return type is inferred as Coroutine[Any, Any, _T]. Can't mypy infer this as Coroutine[None, None, _T] or atleast Coroutine[object, object, _T]?
Activity
tmke8 commentedon Apr 25, 2024
Just for reference, this is likely due to #16942.
Add temporary work around for mypy 1.10.0 regression
[-][1.10] Regression with Any in functools.wraps()[/-][+][1.10/11] Regression with Any in functools.wraps()[/+]Dreamsorcerer commentedon Aug 1, 2024
Smaller example, as the Any actually comes from the inner function: