User:Sam/Portage help/Upgrading Portage

Background
Portage is Gentoo's main package manager.

For many years, Portage would always recommend updating itself before anything else. This ended up causing various problems when there was a "global Python target change" pending (e.g. PYTHON_TARGETS in the profiles changed from PYTHON_TARGETS="python3_8" to PYTHON_TARGETS="python3_9"). Its behaviour was later updated in to silence the message when such a change is detected.

The current version of portage supports EAPI '7'
Portage 3.0.20 and above supports EAPI 8, but earlier versions can't read ebuilds with this newer format specification.

Problem
The standard error looks like this when trying to upgrade :

PYTHON_TARGETS hack
First, run. If you see output like the following:

then it means that Python 3.8 is currently enabled, but will be disabled (say, due to a change in the profile defaults).

As a hack, we can force Portage to just update itself and minimise its dependencies, so that we get a version which supports EAPI 8.

Try the following:

Then proceed with trying to complete a world upgrade.