Skip to content

Commit 05b975a

Browse files
authored
psutil: deprecate Process.connections (#12174)
1 parent 29f6bc3 commit 05b975a

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

stubs/psutil/psutil/__init__.pyi

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ from _typeshed import Incomplete
33
from collections.abc import Callable, Iterable, Iterator
44
from contextlib import AbstractContextManager
55
from typing import Any, Literal, overload
6-
from typing_extensions import Self, TypeAlias
6+
from typing_extensions import Self, TypeAlias, deprecated
77

88
from psutil._common import (
99
AIX as AIX,
@@ -216,6 +216,7 @@ class Process:
216216
def memory_full_info(self) -> pfullmem: ...
217217
def memory_percent(self, memtype: str = "rss") -> float: ...
218218
def open_files(self) -> list[popenfile]: ...
219+
@deprecated('use "net_connections" method instead')
219220
def connections(self, kind: str = "inet") -> list[pconn]: ...
220221
def send_signal(self, sig: int) -> None: ...
221222
def suspend(self) -> None: ...

0 commit comments

Comments
 (0)