The fix for bug 635540 prevents downgrades, but upgrades still to do not work correctly.
Patch sent for review: https://archives.gentoo.org/gentoo-portage-dev/message/327626b5c518aae8017c62f1c2072bc9 https://github.com/gentoo/portage/pull/241
The bug has been referenced in the following commit(s): https://gitweb.gentoo.org/proj/portage.git/commit/?id=86ba22da7a2f34848cdb5a6f1090c22c264e577e commit 86ba22da7a2f34848cdb5a6f1090c22c264e577e Author: Zac Medico <zmedico@gentoo.org> AuthorDate: 2018-01-09 03:34:22 +0000 Commit: Zac Medico <zmedico@gentoo.org> CommitDate: 2018-01-11 19:23:34 +0000 dep_zapdeps: install new package, allow upgrade (bug 643974) Prefer to install a new package in order to allow upgrade of an installed package. This generalizes the code from bug 635540 so that it both allows desirable upgrades and prevents unwanted downgrades. Fixes: 7c58e3737616 ("dep_zapdeps: install new package, avoid downgrade (bug 635540)") Bug: https://bugs.gentoo.org/643974 Reviewed-by: Alec Warner <antarus@gentoo.org> pym/portage/dep/dep_check.py | 11 +-- .../tests/resolver/test_or_upgrade_installed.py | 101 +++++++++++++++++++++ 2 files changed, 106 insertions(+), 6 deletions(-)}