From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by finch.gentoo.org (Postfix) with ESMTPS id 194371382C5 for ; Sat, 28 Apr 2018 22:26:21 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 36720E081B; Sat, 28 Apr 2018 22:26:20 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id 14980E081B for ; Sat, 28 Apr 2018 22:26:19 +0000 (UTC) Received: from oystercatcher.gentoo.org (unknown [IPv6:2a01:4f8:202:4333:225:90ff:fed9:fc84]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id BEC4B335C99 for ; Sat, 28 Apr 2018 22:26:18 +0000 (UTC) Received: from localhost.localdomain (localhost [IPv6:::1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id 96F32272 for ; Sat, 28 Apr 2018 22:26:16 +0000 (UTC) From: "Zac Medico" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Zac Medico" Message-ID: <1524954321.54256075a4b525e86d6837a3ecf6502eb484d3a0.zmedico@gentoo> Subject: [gentoo-commits] proj/portage:master commit in: pym/_emerge/ X-VCS-Repository: proj/portage X-VCS-Files: pym/_emerge/AsynchronousTask.py X-VCS-Directories: pym/_emerge/ X-VCS-Committer: zmedico X-VCS-Committer-Name: Zac Medico X-VCS-Revision: 54256075a4b525e86d6837a3ecf6502eb484d3a0 X-VCS-Branch: master Date: Sat, 28 Apr 2018 22:26:16 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org X-Archives-Salt: 9cc48637-b567-4022-99b8-98fae1dca0e2 X-Archives-Hash: eee1d5d47cf3e80d620211be3682637f commit: 54256075a4b525e86d6837a3ecf6502eb484d3a0 Author: Zac Medico gentoo org> AuthorDate: Sat Apr 28 22:25:21 2018 +0000 Commit: Zac Medico gentoo org> CommitDate: Sat Apr 28 22:25:21 2018 +0000 URL: https://gitweb.gentoo.org/proj/portage.git/commit/?id=54256075 AsynchronousTask: fix deprecated _wait usage (bug 653856) Make the default _start implementation call _async_wait() instead of wait(). Bug: https://bugs.gentoo.org/653856 pym/_emerge/AsynchronousTask.py | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/pym/_emerge/AsynchronousTask.py b/pym/_emerge/AsynchronousTask.py index 7d2e6253b..4e664d00e 100644 --- a/pym/_emerge/AsynchronousTask.py +++ b/pym/_emerge/AsynchronousTask.py @@ -12,7 +12,7 @@ class AsynchronousTask(SlotObject): to public methods can be wrapped for implementing hooks such as exit listener notification. - Sublasses should call self.wait() to notify exit listeners after + Sublasses should call self._async_wait() to notify exit listeners after the task is complete and self.returncode has been set. """ @@ -51,7 +51,7 @@ class AsynchronousTask(SlotObject): def _start(self): self.returncode = os.EX_OK - self.wait() + self._async_wait() def isAlive(self): return self.returncode is None @@ -81,6 +81,9 @@ class AsynchronousTask(SlotObject): return self.returncode def _wait(self): + """ + Deprecated. Use _async_wait() instead. + """ return self.returncode def _async_wait(self):