psutil: sconn.pid can be None (#9853)

Found out about this the hard way.

The code path that allows None is here: 2da9950223/psutil/_pslinux.py (L923)
This commit is contained in:
Jelle Zijlstra
2023-03-07 14:07:54 -08:00
committed by GitHub
parent 81f2f22a03
commit bff9d7a7df

View File

@@ -117,7 +117,7 @@ class sconn(NamedTuple):
laddr: addr | tuple[()]
raddr: addr | tuple[()]
status: str
pid: int
pid: int | None
class snicaddr(NamedTuple):
family: AddressFamily