Skip to content

Commit 2528c3f

Browse files
committed
ManifestTask: set returncode to that of failed gpg process
In order for ManifestScheduler retry to detect an unexpected returncode, ManifestTask must expose the failed gpg process returncode as the ManifestTask returncode. Fixes: 448b774 Bug: https://bugs.gentoo.org/965132 Signed-off-by: Zac Medico <[email protected]>
1 parent be8927e commit 2528c3f

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

lib/portage/package/ebuild/_parallel_manifest/ManifestTask.py

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# Copyright 2012-2018 Gentoo Foundation
1+
# Copyright 2012-2025 Gentoo Authors
22
# Distributed under the terms of the GNU General Public License v2
33

44
import errno
@@ -73,6 +73,8 @@ def _start_with_fetchlist(self, fetchlist_task):
7373
def _manifest_proc_exit(self, manifest_proc):
7474
self._assert_current(manifest_proc)
7575
if manifest_proc.returncode not in (os.EX_OK, manifest_proc.MODIFIED):
76+
# Expose the process returncode so that manifest_scheduler_retry
77+
# can detect an unexpected process returncode (bug 965132).
7678
self.returncode = manifest_proc.returncode
7779
self._current_task = None
7880
self.wait()
@@ -205,6 +207,9 @@ def _start_gpg_proc(self):
205207

206208
def _gpg_proc_exit(self, gpg_proc):
207209
if self._default_exit(gpg_proc) != os.EX_OK:
210+
# Expose the process returncode so that manifest_scheduler_retry
211+
# can detect an unexpected process returncode (bug 965132).
212+
self.returncode = gpg_proc.returncode
208213
self.wait()
209214
return
210215

0 commit comments

Comments
 (0)