Cannot install "python-all" package, python2.4-minimal crashes saying i must use python2.5.
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
python2.4 (Ubuntu) |
Invalid
|
Undecided
|
Unassigned |
Bug Description
Binary package hint: python-all
version 2.4.5-5ubuntu1
I think my problem looks a lot like bug #75557
I can't install or uninstall python2.4-minimal. The application says that I must use python2.5. The error is:
ValueError: /usr/bin/python does not match the python default version. It must be reset to point to python2.5
But this is the version I use:
python -V
Python 2.5.2
This is when the error occured: I installed python3.0, then I wanted to use it so I typed:
sudo update-alternatives --install /usr/bin/python python python2.5 10
sudo update-alternatives --install /usr/bin/python python python3.0 20
After this, I tried to compile Blender with this new version. But it didn't work so I turned back to 2.5
sudo update-alternatives --remove-all python
sudo update-alternatives --install /usr/bin/python python python2.5
After this I decided to install python-all package for no real reason, then the bug happened.
Ubuntu 8.10 amd64
ProblemType: Package
Architecture: amd64
Dependencies:
DistroRelease: Ubuntu 8.10
ErrorMessage: le sous-processus pre-installation script a retourné une erreur de sortie d'état 1
NonfreeKernelMo
Package: python-uno None [modified: /var/lib/
SourcePackage: openoffice.org
Title: package python-uno None [modified: /var/lib/
Uname: Linux 2.6.27-11-generic x86_64
description: | updated |
description: | updated |
Ok I found a way to fix this, and the reason why it happened, maybe it will help someone!
the problem was: when I made my synlink with
sudo update-alternatives --install /usr/bin/python python python2.5 10
update-altertative didn't write this path to the synlink, but: /etc/alternativ es/python (I don't know why...) this is what confused python. In /usr/share/ pycentral- data/pyversions .py, the script that checks if the right version of python is used, they search for python2.5 in "os.readlink" the return of readlink was: /etc/alternativ es/python. .. no python2.5 in this string!
So how to fix this:
sudo python #open python in super-user mode '/usr/bin/ python' ) #remove the old link '/usr/bin/ python' ,'/usr/ bin/python2. 5') #make the new link, this is made by python itself, so it must work!!
import os #we are in python now, so this import the os functions
os.unlink(
os.symlink(
this works fine for me, python now installs fine, and works fine too (with version 2.5 though...)