From f507aed9aa8712a7e09bc680c1114dd91b8c65d3 Mon Sep 17 00:00:00 2001 From: Newbyte Date: Tue, 29 Oct 2024 13:49:37 +0100 Subject: [PATCH] pmb.build.autodetect: Fix return type and docstring for arch() (MR 2464) At some point, this function was updated to use the Arch type instead of plain strings, but the return type was left omitted and the docstring outdated. --- pmb/build/autodetect.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pmb/build/autodetect.py b/pmb/build/autodetect.py index 59b1af08..12766cab 100644 --- a/pmb/build/autodetect.py +++ b/pmb/build/autodetect.py @@ -39,14 +39,14 @@ def arch_from_deviceinfo(pkgname, aport: Path) -> Arch | None: @Cache("package") -def arch(package: str | dict[str, Any]): +def arch(package: str | dict[str, Any]) -> Arch: """ Find a good default in case the user did not specify for which architecture a package should be built. :param package: The name of the package or parsed APKBUILD - :returns: arch string like "x86_64" or "armhf". Preferred order, depending + :returns: Arch object. Preferred order, depending on what is supported by the APKBUILD: * native arch * device arch (this will be preferred instead if build_default_device_arch is true)