Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Werkzeug doesn't include wsgi module

I'm trying to run the 6.1 branch of OpenERP in my development environment that is currently running the 5.0 branch successfully. I'm running on Ubuntu 10.04 Lucid Lynx.

I've gotten past a few hurdles, but I'm currently stuck on an error caused by import werkzeug.wsgi in the http module. I added the python-werkzeug package, but it doesn't include the wsgi module. I looked on the package's web page, and I see that my version of Ubuntu gets werkzeug 0.5.1, when the newer ones all have at least 0.6.2. When I compare the source for werkzeug 0.5 and werkzeug 0.6, I can see that the wsgi module was added between those versions.

How can I get at least version 0.6 of werkzeug running on Ubuntu 10.04? This says I've already got the latest:

sudo apt-get install python-werkzeug
like image 773
Don Kirkby Avatar asked Mar 15 '26 14:03

Don Kirkby


1 Answers

Aptitude is often woefully out of date for Python packages, as it seems to be here. You are much better off using pip, Python's package management tool. Pip tells me that werkzeug is currently at version 0.8.1!

First install pip (if you don't have it already)

sudo easy_install pip

Then install werkzeug

sudo pip install werkzeug

Easy install is no longer the recommended way to do Python package - you should certainly be using pip.

These commands install the packages into your machine's global Python environment. You would do well to investigate virtualenv, which creates separate Python interpreters that can have their own packages installed.

Good luck!

like image 138
adamnfish Avatar answered Mar 17 '26 02:03

adamnfish



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!