Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

upgrade ubuntu 18.04 to 20.04 but packages remain +bionic1

after upgrading to ubuntu 20.04 some package remain in +bionic1 version

sudo apt list | grep python3.8


WARNING: apt does not have a stable CLI interface. Use with caution in scripts.

idle-python3.8/focal-updates,focal-updates,focal-security,focal-security 3.8.2-1ubuntu1.1 all
libpython3.8-dbg/focal-updates,focal-security 3.8.2-1ubuntu1.1 amd64
libpython3.8-dbg/focal-updates,focal-security 3.8.2-1ubuntu1.1 i386
libpython3.8-dev/focal-updates,focal-security 3.8.2-1ubuntu1.1 amd64
libpython3.8-dev/focal-updates,focal-security 3.8.2-1ubuntu1.1 i386
libpython3.8-minimal/now 3.8.2-1+bionic1 amd64 [installed,local]
libpython3.8-minimal/focal-updates,focal-security 3.8.2-1ubuntu1.1 i386
libpython3.8-stdlib/now 3.8.2-1+bionic1 amd64 [installed,local]
libpython3.8-stdlib/focal-updates,focal-security 3.8.2-1ubuntu1.1 i386
libpython3.8-testsuite/focal-updates,focal-updates,focal-security,focal-security 3.8.2-1ubuntu1.1 all
libpython3.8/focal-updates,focal-security 3.8.2-1ubuntu1.1 amd64
libpython3.8/focal-updates,focal-security 3.8.2-1ubuntu1.1 i386
python3.8-dbg/focal-updates,focal-security 3.8.2-1ubuntu1.1 amd64
python3.8-dbg/focal-updates,focal-security 3.8.2-1ubuntu1.1 i386
python3.8-dev/focal-updates,focal-security 3.8.2-1ubuntu1.1 amd64
python3.8-dev/focal-updates,focal-security 3.8.2-1ubuntu1.1 i386
python3.8-doc/focal-updates,focal-updates,focal-security,focal-security 3.8.2-1ubuntu1.1 all
python3.8-examples/focal-updates,focal-updates,focal-security,focal-security 3.8.2-1ubuntu1.1 all
python3.8-minimal/now 3.8.2-1+bionic1 amd64 [installed,local]
python3.8-minimal/focal-updates,focal-security 3.8.2-1ubuntu1.1 i386
python3.8-venv/focal-updates,focal-security 3.8.2-1ubuntu1.1 amd64
python3.8-venv/focal-updates,focal-security 3.8.2-1ubuntu1.1 i386
python3.8/now 3.8.2-1+bionic1 amd64 [installed,local]
python3.8/focal-updates,focal-security 3.8.2-1ubuntu1.1 i386

as you can see above python3.8-minimal/now 3.8.2-1+bionic1 amd64 [installed,local] remain in bionic version if I want to purge and install python3.8 then many dependency will removed too and this may cause break my OS how can I push ubuntu to switch all install +bionic1 package to focal version ubuntu1.1 or ubuntu1

like image 332
Ramin Farmani Avatar asked May 06 '20 04:05

Ramin Farmani


1 Answers

Ultimately, the maintainers probably need to make an upstream patch to the Python packages as the version/epoch parser apparently believes the prefix -1+bionic1 to be newer than -1ubuntu1.1.

In my case, the -1+bionic1 prefix for Python 3.8 came from installing Python 3.8 packages from the deadsnakes PPA and not from the canonical repositories.

That said, I was able to force a "downgrade" to the correct Ubuntu-Focal packages using this command:

sudo apt install libpython3.8:amd64=3.8.2-1ubuntu1.1 libpython3.8-dev:amd64=3.8.2-1ubuntu1.1 libpython3.8-minimal:amd64=3.8.2-1ubuntu1.1 libpython3.8-stdlib:amd64=3.8.2-1ubuntu1.1 python3.8=3.8.2-1ubuntu1.1 python3.8-minimal=3.8.2-1ubuntu1.1

I ran into this issue trying to install other Python libraries like python3-venv after an 18.04->20.04 system upgrade and these packages pinned their dependencies to the 3.8.2-1ubuntu1.1 version.

like image 62
pztrick Avatar answered Oct 30 '22 07:10

pztrick