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

Bug 539402

Summary: sys-apps/portage: repoman inappropriately accesses ebuilds from the master repo when checking an overlay
Product: Portage Development Reporter: Zac Medico <zmedico>
Component: RepomanAssignee: Portage team <dev-portage>
Status: RESOLVED FIXED    
Severity: normal Keywords: InVCS
Priority: Normal    
Version: unspecified   
Hardware: All   
OS: All   
Whiteboard:
Package list:
Runtime testing required: ---
Bug Depends on:    
Bug Blocks: 484436    
Attachments: match Atom("%s::%s" % (pkg.cp, repo_config.name))

Description Zac Medico gentoo-dev 2015-02-09 00:02:36 UTC
Created attachment 395946 [details, diff]
match Atom("%s::%s" % (pkg.cp, repo_config.name))

In repoman, portdb.xmatch("match-visible", pkg.cp) is used to check the list of visible ebuilds. However, instead of pkg.cp, when checking an overlay it needs use an atom which restricts the match to the appropriate repo. Otherwise, it risks matching ebuilds from the master repo(s). The following digest verification error demonstrates the problem occuring:

jule@localhost ~/git/games-overlay/games-board/stockfish $ repoman full
 
RepoMan scours the neighborhood...
 * Digest verification failed:
 * /usr/portage/games-board/stockfish/stockfish-6.ebuild
 * Reason: Filesize does not match recorded size
 * Got: 1026
 * Expected: 1025

Note that the digest error occurs for the master repository, even though it's games-overlay that is being checked.
Comment 1 Zac Medico gentoo-dev 2015-02-09 00:46:25 UTC
This is in the master branch now:

https://github.com/gentoo/portage/commit/21b4db4b9db1ed79d0f62e9761c29acde490fbc1
Comment 2 Michał Górny archtester Gentoo Infrastructure gentoo-dev Security 2015-02-09 07:47:42 UTC
Just guessing what it does, but wouldn't it cause dependency errors when overlays depend on packages in master?
Comment 3 Zac Medico gentoo-dev 2015-02-09 18:44:47 UTC
(In reply to Michał Górny from comment #2)
> Just guessing what it does, but wouldn't it cause dependency errors when
> overlays depend on packages in master?

The patch just fixes code that checks if the current ebuild being checked is masked, which has nothing to do with dependencies.
Comment 4 Brian Dolbec gentoo-dev 2015-02-12 06:06:56 UTC
Released in portage-2.2.17