From 2635d18f88a4b99b7e605d474ea481365e08bccd Mon Sep 17 00:00:00 2001 From: Tony Narlock Date: Tue, 27 Dec 2022 07:45:08 -0600 Subject: [PATCH] fix(Session.children): Add deprecation warning --- src/libtmux/session.py | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/src/libtmux/session.py b/src/libtmux/session.py index b1ffabf0f..a15864bfb 100644 --- a/src/libtmux/session.py +++ b/src/libtmux/session.py @@ -687,5 +687,11 @@ def list_windows(self) -> t.List["Window"]: warnings.warn("Session.list_windows() is deprecated") return self.windows - #: Was used by TmuxRelationalObject (but that's longer used in this class) - children = windows + @property + def children(self) -> QueryList["Window"]: # type:ignore + """Was used by TmuxRelationalObject (but that's longer used in this class) + + .. deprecated:: 0.16 + """ + warnings.warn("Session.children is deprecated") + return self.windows