tobiastimm / husky-hg

:dog: Git/Mercurial hooks made easy.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Support for Python 3

cyrilletuzi opened this issue · comments

Hi! First: thanks a lot for your lib. :)

Unfortunately it's failing on my computer which uses Python 3 while the lib use Python 2. So I get errors like this:

File "/path/to/project/.hg/hooks/pretxnopen.py", line 11
    print pfx + msg
            ^
SyntaxError: Missing parentheses in call to 'print'. Did you mean print(pfx + msg)?

I tried to reinstall Mercurial with Python 2. Unfortunately, Python 2 has been deprecated and removed on some environments: in my case, I use Homebrew on a Mac, where building tools with Python 2 is not possible anymore since January 1, 2020.

Is it possible to fix this, or do you know a workable workaround? Thanks!

Hey @cyrilletuzi,

Did you ever get around this? Asking for a friend :)

@mateatslc hey, unfortunately no, I just stopped working on the project using Mercurial.

got you, thanks anyway 👍