librelist archives

« back to archive

getting pip installed flask to work on a debian 7 running in lxc debian hos

getting pip installed flask to work on a debian 7 running in lxc debian hos

From:
Suprotip
Date:
2014-08-25 @ 06:20
Hi to everyone,

I am trying to get a pip installed flask to work on a debian 7 running 
in lxc debian host. pip reported a set of errors that look like:
/
  WARNING: The C extension could not be compiled, speedups are not enabled.
     Plain-Python installation succeeded.

Successfully installed flask Werkzeug Jinja2 itsdangerous markupsafe
Cleaning up..


/But I  get the following error on Python3. Any help in order to get it 
right is much appreciated.
/

 >>> from flask import *
Traceback (most recent call last):
   File "<stdin>", line 1, in <module>
   File "/usr/local/lib/python3.2/dist-packages/flask/__init__.py", line 
17, in <module>
     from werkzeug.exceptions import abort
   File "/usr/local/lib/python3.2/dist-packages/werkzeug/__init__.py", 
line 154, in <module>
     __import__('werkzeug.exceptions')
   File "/usr/local/lib/python3.2/dist-packages/werkzeug/exceptions.py", 
line 111
     return u'<p>%s</p>' % escape(self.description)
                       ^
SyntaxError: invalid syntax
 >>> dir(flask)
Traceback (most recent call last):
   File "<stdin>", line 1, in <module>
NameError: name 'flask' is not defined

 >>> sys.version
'3.2.3 (default, Feb 20 2013, 14:44:27) \n[GCC 4.7.2]'

/best regards/
/

Re: [flask] getting pip installed flask to work on a debian 7 running in lxc debian hos

From:
Daniel Neuhäuser
Date:
2014-08-25 @ 06:47
You are using Python 3.2, Flask requires Python 3.3.