You are not logged in.

#1 2014-04-28 13:45:24

gvenkat1994
Member
Registered: 2014-04-13
Posts: 34

Error installing python library using pip

I tried to install a python library pattern using pip, but I am getting an error during install. I get the same error when trying to install any python library.

[venkat@hal9000 Downloads]$ sudo pip install pattern
Downloading/unpacking pattern
  Downloading pattern-2.6.zip (24.6MB): 24.6MB downloaded
  Running setup.py (path:/tmp/pip_build_root/pattern/setup.py) egg_info for package pattern
    Traceback (most recent call last):
      File "<string>", line 17, in <module>
      File "/tmp/pip_build_root/pattern/setup.py", line 40
        print n
              ^
    SyntaxError: invalid syntax
    Complete output from command python setup.py egg_info:
    Traceback (most recent call last):

  File "<string>", line 17, in <module>

  File "/tmp/pip_build_root/pattern/setup.py", line 40

    print n

          ^

SyntaxError: invalid syntax

----------------------------------------
Cleaning up...
Command python setup.py egg_info failed with error code 1 in /tmp/pip_build_root/pattern
Storing debug log for failure in /root/.pip/pip.log

I just updated python to python 3.4.

Last edited by gvenkat1994 (2014-04-28 13:45:41)

Offline

#2 2014-04-28 14:05:32

tomk
Forum Fellow
From: Ireland
Registered: 2004-07-21
Posts: 9,839

Re: Error installing python library using pip

And that is the problem - you need python2, pattern does not work with python 3.¹

[1] http://www.clips.ua.ac.be/pattern

python2-pattern is available in the AUR btw.

Last edited by tomk (2014-04-28 14:06:17)

Offline

Board footer

Powered by FluxBB