From 5273dbca3bb2a11db22521fd70dba1e9fcfd5a54 Mon Sep 17 00:00:00 2001 From: Siddhanth Rathod Date: Thu, 28 Sep 2023 23:37:42 +0530 Subject: [PATCH] Fix: Recent decision to make FEATURES=pkgdir-index-trusted is now on by default breaks eclean-invalids feature See_also: https://github.com/gentoo/portage/commit/3bc7bfef51d88fd716e882d3931f2873e3493e01 Signed-off-by: Siddhanth Rathod --- pym/gentoolkit/eclean/search.py | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/pym/gentoolkit/eclean/search.py b/pym/gentoolkit/eclean/search.py index dedd0862..77d7b8a8 100644 --- a/pym/gentoolkit/eclean/search.py +++ b/pym/gentoolkit/eclean/search.py @@ -580,10 +580,14 @@ def findPackages( dead_binpkgs: dict[str, list[str]] = {} keep_binpkgs = {} - bin_dbapi = portage.binarytree(pkgdir=pkgdir, settings=var_dbapi.settings).dbapi + # FEATURES=pkgdir-index-trusted is now on by default which makes portages inavlids + # inaccessible + settings = var_dbapi.settings + settings.unlock() + settings.features.remove("pkgdir-index-trusted") + bin_dbapi = portage.binarytree(pkgdir=pkgdir, settings=settings).dbapi for cpv in bin_dbapi.cpv_all(): cp = portage.cpv_getkey(cpv) - # Exclude per --exclude-file=... if exclDictMatchCP(exclude, cp): continue