3

I already tried several options like these, but all I am getting are errors, like this one:

python setup.py \
    build_ui \
    build_py -c -d . \
    build_mo
running build_ui
running build_py
running build_mo
HGRCPATH= python thg version
Traceback (most recent call last):
  File "thg", line 99, in <module>
    tortoisehg.hgqt.run.run()
  File "/usr/lib/python3.8/importlib/util.py", line 245, in __getattribute__
    self.__spec__.loader.exec_module(self)
  File "<frozen importlib._bootstrap_external>", line 783, in exec_module
  File "<frozen importlib._bootstrap>", line 219, in _call_with_frames_removed
  File "/home/user/thg/tortoisehg/hgqt/run.py", line 499, in <module>
    _('repository root directory or symbolic path name')),
  File "/home/user/thg/tortoisehg/util/i18n.py", line 109, in agettext
    return hglib.fromunicode(u)
  File "/usr/lib/python3.8/importlib/util.py", line 245, in __getattribute__
    self.__spec__.loader.exec_module(self)
  File "<frozen importlib._bootstrap_external>", line 783, in exec_module
  File "<frozen importlib._bootstrap>", line 219, in _call_with_frames_removed
  File "/home/user/thg/tortoisehg/util/hglib.py", line 351, in <module>
    readmergestate = mergemod.mergestate.read
  File "/usr/lib/python3.8/importlib/util.py", line 256, in __getattribute__
    return getattr(self, attr)
AttributeError: module 'mercurial.merge' has no attribute 'mergestate'
make: *** [Makefile:25: local] Error 1

Or this one after installing pyqt5:

    from PyQt5.QtCore import *
ImportError: No module named PyQt5.QtCore
make: *** [Makefile:24: local] Error 1

In case it is needed, my python version is 3.8.2

Serge Stroobandt
  • 5,268
  • 1
  • 48
  • 59

2 Answers2

1

You are missing python qt libraries.

sudo apt get install python3-pyqt5 pyqt5-dev-tools qttools5-dev-tools

After installing missing libararies, you should be able to install tortoisehg.

KK Patel
  • 19,083
1

Ok, here is what I did:

  1. I followed the instructions of this answer until #8 make local
  2. Then and skipping duplicated instructions, I have followed this until #5 sudo python3 setup.py install
Serge Stroobandt
  • 5,268
  • 1
  • 48
  • 59