in #15654, these attributes were made less typesafe by changing their type from IO[AnyStr] to IO[Any]:
from subprocess import PIPE, Popen
with Popen(["echo", "hi"], stdout=PIPE, text=True) as process:
if process.stdout:
for line in process.stdout:
line.asdfasdf # no type error, crashes at runtime
there didn't seem to be any explanation for this change in that PR which is why i'm opening a new issue. is there a reason the types can't be IO[AnyStr]?
in #15654, these attributes were made less typesafe by changing their type from
IO[AnyStr]toIO[Any]:there didn't seem to be any explanation for this change in that PR which is why i'm opening a new issue. is there a reason the types can't be
IO[AnyStr]?