Ich hatte ein 64-Bit-Ubuntu-10.04-System. Ich hatte Probleme damit ubuntu-desktop
, da ich mich nicht anmelden konnte. Also habe ich das 32-Bit-System Ubuntu 12.04 über ein ISO-Image auf einer DVD installiert und dabei denselben Benutzernamen beibehalten. Während der Installation habe ich die Partitionen des früheren Systems wiederverwendet und auch denselben Benutzernamen gewählt, um die Daten intakt zu halten /home
.
mercurial
Ich habe es auf Ubuntu 12.04 installiert sudo apt-get
. Aber wenn ich es ausführe, erhalte ich diesen Stacktrace. Ich bin sicher, dass Mercurial versucht, auf ein früheres 64-Bit-System zuzugreifen. Denn ich habe festgestellt, dass /usr/local/lib/
es zwei Python-Installationen gibt – 2.6 und 2.7.
Um dieses Problem zu beheben, wird Hilfe benötigt.
Error in sys.excepthook:
Traceback (most recent call last):
File "/usr/lib/python2.7/dist-packages/apport_python_hook.py", line 66, in apport_excepthook
from apport.fileutils import likely_packaged, get_recent_crashes
File "/usr/local/lib/python2.6/dist-packages/mercurial/demandimport.py", line 95, in _demandimport
return _import(name, globals, locals, fromlist, level)
File "/usr/lib/python2.7/dist-packages/apport/__init__.py", line 1, in <module>
from apport.report import Report
File "/usr/local/lib/python2.6/dist-packages/mercurial/demandimport.py", line 114, in _demandimport
mod = _origimport(name, globals, locals)
File "/usr/lib/python2.7/dist-packages/apport/report.py", line 155, in <module>
class Report(problem_report.ProblemReport):
File "/usr/local/lib/python2.6/dist-packages/mercurial/demandimport.py", line 86, in __getattribute__
self._load()
File "/usr/local/lib/python2.6/dist-packages/mercurial/demandimport.py", line 58, in _load
mod = _origimport(head, globals, locals)
File "/usr/lib/python2.7/dist-packages/problem_report.py", line 93, in <module>
class ProblemReport(UserDict):
TypeError: Error when calling the metaclass bases
module.__init__() takes at most 2 arguments (3 given)
Original exception was:
Traceback (most recent call last):
File "/usr/local/bin/hg", line 36, in <module>
mercurial.util.setbinary(fp)
File "/usr/local/lib/python2.6/dist-packages/mercurial/demandimport.py", line 86, in __getattribute__
self._load()
File "/usr/local/lib/python2.6/dist-packages/mercurial/demandimport.py", line 58, in _load
mod = _origimport(head, globals, locals)
File "/usr/local/lib/python2.6/dist-packages/mercurial/util.py", line 67, in <module>
statfiles = getattr(osutil, 'statfiles', platform.statfiles)
File "/usr/local/lib/python2.6/dist-packages/mercurial/demandimport.py", line 86, in __getattribute__
self._load()
File "/usr/local/lib/python2.6/dist-packages/mercurial/demandimport.py", line 58, in _load
mod = _origimport(head, globals, locals)
ImportError: /usr/local/lib/python2.6/dist-packages/mercurial/osutil.so: wrong ELF class: ELFCLASS64
Antwort1
Nun, ich habe die Antwort gefunden. Ich habe Ordner entfernt /usr/local/lib/python2.6
und python2.7
kopiert. Ich habe den Speicherort geändert. Das /usr/lib/python2.6
hat geholfen.python2.7
/usr/local/lib/
cp -Rp /usr/lib/python2.6 /usr/local/lib/
cp -Rp /usr/lib/python2.7 /usr/local/lib/