Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 919419

Summary: sys-apps/portage: emerge throws backtrace when trying to pkgmove signed binpkgs
Product: Portage Development Reporter: Marc Schiffbauer <mschiff>
Component: Binary packages supportAssignee: Portage team <dev-portage>
Status: RESOLVED FIXED    
Severity: normal CC: sam, syu.os
Priority: Normal Keywords: InVCS, PullRequest
Version: unspecified   
Hardware: All   
OS: Linux   
See Also: https://github.com/gentoo/portage/pull/1043
https://bugs.gentoo.org/show_bug.cgi?id=920095
Whiteboard:
Package list:
Runtime testing required: ---
Bug Depends on: 918929    
Bug Blocks: 913020    

Description Marc Schiffbauer gentoo-dev 2023-12-07 19:54:10 UTC
Currently, portage is not able to pkgmove signed binpkgs.

As long as there are to-be-moved binpkgs around you have to use "--package-moves=n" in order to use emerge for any package action

Ideally emerge would support to pkgmove and resign binpkgs on the fly or at least either just warn that it is not possible and skip or offer to delete the affected binpkg
Comment 1 Larry the Git Cow gentoo-dev 2023-12-08 07:27:36 UTC
The bug has been referenced in the following commit(s):

https://gitweb.gentoo.org/proj/portage.git/commit/?id=a7bbb4fc4d38f770fc943f3b856c5de56e315fe4

commit a7bbb4fc4d38f770fc943f3b856c5de56e315fe4
Author:     Sheng Yu <syu.os@protonmail.com>
AuthorDate: 2023-12-08 00:43:29 +0000
Commit:     Sam James <sam@gentoo.org>
CommitDate: 2023-12-08 07:25:44 +0000

    Fix move_ent with signed binpkg
    
    The gpkg file that cannot be updated will be removed.
    
    [sam: We did discuss stripping the signatures to re-use them but that
    feels messier and likely unexpected by the user. We also don't distinguish
    between locally-made vs fetched binpkgs (where perhaps for local ones, we could
    just re-sign if signed).
    
    It was also raised that for fetched binpkgs, we could not worry once it's
    been verified the first time, but that's again complicated.
    
    Simply dropping these binpkgs seems like the best solution and to allow
    the binhost to re-sign it on updating instead.]
    
    Bug: https://bugs.gentoo.org/919419
    Signed-off-by: Sheng Yu <syu.os@protonmail.com>
    Closes: https://github.com/gentoo/portage/pull/1043
    Signed-off-by: Sam James <sam@gentoo.org>

 lib/portage/dbapi/bintree.py                       |  21 ++-
 lib/portage/exception.py                           |   4 +
 lib/portage/gpkg.py                                |   6 +-
 .../tests/gpkg/test_gpkg_metadata_update.py        |   2 +-
 lib/portage/tests/update/test_move_ent.py          | 108 +++++++++++++++
 lib/portage/tests/update/test_move_slot_ent.py     | 148 +++++++++++++++++++-
 lib/portage/tests/update/test_update_dbentry.py    | 152 ++++++++++++++++++++-
 7 files changed, 436 insertions(+), 5 deletions(-)
Comment 2 Larry the Git Cow gentoo-dev 2023-12-08 07:29:03 UTC
The bug has been referenced in the following commit(s):

https://gitweb.gentoo.org/proj/portage.git/commit/?id=8cd13830c511bcdc57d033ea18843f1d55f8abfe

commit 8cd13830c511bcdc57d033ea18843f1d55f8abfe
Author:     Sam James <sam@gentoo.org>
AuthorDate: 2023-12-08 07:28:32 +0000
Commit:     Sam James <sam@gentoo.org>
CommitDate: 2023-12-08 07:28:57 +0000

    NEWS: update
    
    Bug: https://bugs.gentoo.org/919419
    Signed-off-by: Sam James <sam@gentoo.org>

 NEWS | 3 +++
 1 file changed, 3 insertions(+)
Comment 3 Larry the Git Cow gentoo-dev 2023-12-10 22:35:32 UTC
The bug has been closed via the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=0d365d80099d206e49b592abb30030642f8f09f9

commit 0d365d80099d206e49b592abb30030642f8f09f9
Author:     Sam James <sam@gentoo.org>
AuthorDate: 2023-12-10 22:34:47 +0000
Commit:     Sam James <sam@gentoo.org>
CommitDate: 2023-12-10 22:34:52 +0000

    sys-apps/portage: add 3.0.57
    
    Closes: https://bugs.gentoo.org/918929
    Closes: https://bugs.gentoo.org/913628
    Closes: https://bugs.gentoo.org/915474
    Closes: https://bugs.gentoo.org/918597
    Closes: https://bugs.gentoo.org/919072
    Closes: https://bugs.gentoo.org/919105
    Closes: https://bugs.gentoo.org/919174
    Closes: https://bugs.gentoo.org/919311
    Closes: https://bugs.gentoo.org/919419
    Closes: https://bugs.gentoo.org/919668
    Signed-off-by: Sam James <sam@gentoo.org>

 sys-apps/portage/Manifest              |   1 +
 sys-apps/portage/portage-3.0.57.ebuild | 242 +++++++++++++++++++++++++++++++++
 2 files changed, 243 insertions(+)