False positive on not-callable when inheriting from typing.IO
#10042
Labels
False Positive 🦟
A message is emitted but nothing is wrong with the code
Needs PR
This issue is accepted, sufficiently specified and now needs an implementation
Bug description
If I write a class which inherits the
typing.IO
abc, pylint complains that class instantiation is not callable when I provide a typevar as well (egX[T]()
, something likelist[str]()
). I think I should be allowed to do this, especially in this case where I want to be explicit about the TypeVar's real type.(lazy) Example. The error is at
Z[str]()
, even thoughX[str]()
andY[str]()
are fine.Command used
pylint x.py
Pylint output
Expected behavior
10/10
Pylint version
pylint 3.3.1
astroid 3.3.5
Python 3.11.10
OS / Environment
Debian 11
The text was updated successfully, but these errors were encountered: