Running Google App Engine in Ubuntu 10.4 Lucid Lynx

It is not new, it always happens the same to me. After I update my computer to the latest version of Ubuntu (in this case version 10.4) I always have to spend a couple of days reconfiguring things or reinstalling packages.

The thing is that right now I am developing an application using Google App Engine (GAE for friends), and for not having problems when deploying the next version, it is recommended to use Python 2.5 when developing.

As you might have guessed in the title, Canonical have removed the Python2.5 package from the latest Ubuntu Lucid release, so I cannot run the local  Google App Engine web server.

Lucky me, after searching for a while on launchpad.net I’ve found a solution. There is a person that has created  python2.4 and python2.5 packages for Ubuntu Lucid Lynx.

The only think you should do is add the following two lines at the end of your  /etc/apt/sources.list

deb http://ppa.launchpad.net/fkrull/deadsnakes/ubuntu lucid main
deb-src http://ppa.launchpad.net/fkrull/deadsnakes/ubuntu lucid main

And finally run:

$ sudo apt-get update
$ sudo apt-get install python2.5

And that’s it, you can now run GoogleAppEngine.

Interesting links:

Trackback URL

, ,

  1. junapp
    03/05/2010 at 5:55 pm Permalink

    Thank you, was trying to create my own package without any luck. Got any pointers on getting the PIL module to work?

  2. Pau Sánchez
    04/05/2010 at 9:03 am Permalink

    @junapp I am not currently using any imaging at all, so I didn’t felt the need for trying to install it. Anyway, I noticed following message:

    Could not initialize images API; you are likely missing the Python “PIL” module. ImportError: No module named _imaging

    I haven’t found anything in a quick-search that I performed, but you can have a look at these links:

    http://code.google.com/p/googleappengine/issues/detail?id=757#c15
    http://blog.vrplumber.com/index.php?/archives/2464-Python-2.5-PIL-Gone-in-Lucid.html
    http://www.pythonware.com/products/pil/

    Good luck!

    If you find a “simple” solution for installing it, I would really appreciate it.

  3. wisski
    05/05/2010 at 10:59 pm Permalink

    A simple Solution would be using easy_install. Unfortunately python2.5-setuptools was not included in the repo above. Or am I mistaking?

    If not, maybe I should ask Felix Krull for helping us out. Don’t know about his reaction, but I’d give it a try.

  4. Pau Sánchez
    06/05/2010 at 12:25 am Permalink

    The easy_install I have installed is for python2.6, so unfortunately we cannot use it for that.

  5. wisski
    06/05/2010 at 1:45 am Permalink

    That’s what I’m talking about.
    I just wrote a message to the creator of the deadsnakes-repo. Hopefully he’ll have mercy with our poor souls 😉

    I’ll inform you about his response.

  6. Pau Sánchez
    08/05/2010 at 2:15 am Permalink

    Great! Let’s see what happens 😉

  7. Tomaž Muraus
    10/05/2010 at 3:23 am Permalink

    Alternatively you could use virtualenv and have multiple separate (–no-site-packages) environments.

    Having separate development environments is a good idea in any case 🙂

  8. noiv
    12/05/2010 at 5:38 pm Permalink

    I’ve linked the deadsnake ppa, installed python2.5
    + the python-setuptools-deadsnakes
    and run:
    wget http://effbot.org/downloads/Imaging-1.1.6.tar.gz
    sudo easy_install-2.5 Imaging-1.1.6.tar.gz

    Now I enjoy to continue developing on Lucid for Google AppEngine with PIL. Many thanks to everybody here.

  9. noiv
    13/05/2010 at 5:15 am Permalink

    libjpeg62-dev is needed to turn on JPEG support.

  10. F.Tamy
    26/05/2010 at 2:00 pm Permalink

    You did not tell about gpg error; Just add 2 lines for beginners like me:
    $ gpg –keyserver keyserver.ubuntu.com –recv 5BB92C09DB82666C
    ————
    $ gpg –export –armor 5BB92C09DB82666C | sudo apt-key add – && sudo apt-get update
    ————
    Now it works on linux 10.04 too

  11. Pau Sánchez
    10/06/2010 at 11:14 pm Permalink

    Thanks F.Tamy, you are right 😉

  12. Stephen G
    13/06/2010 at 9:52 pm Permalink

    Tried noiv’s suggestion for installing PIL, but got a gcc compiler dependency error message (Python.h: No such file or directory). This is on Ubuntu 10.04 x86_64.

    Does dev_appserver.py itself require this, or is this just for those who use PIL in their app (or those who want to eliminate the “Could not initialize images API;” startup warning)?

  13. noiv
    14/06/2010 at 1:24 pm Permalink

    Don’t know about x86_64. Seems a walkthrough starting from a fresh system is needed. Also I don’t know why from time to time a new compilation is needed.

  14. Pau Sánchez
    16/07/2010 at 1:25 am Permalink

    I followed the steps of @noiv for installing the imaging library and I get tons of compiler errors (maybe the same errors as @StephenG).

    I checked if python2.5-dev was installed, and it was not. So I ran:
    $ sudo apt-get install python2.5-dev

    And then I tried again with the:
    $ sudo easy_install-2.5 Imaging-1.1.6.tar.gz

    This time it worked like a charm!
    I hope this helps.

  15. bob
    23/08/2010 at 9:20 pm Permalink

    WARNING: The following packages cannot be authenticated!
    python2.5-minimal python2.5
    Install these packages without verification [y/N]?
    E: Some packages could not be authenticated

    anyone else run into this?

  16. bob
    24/08/2010 at 8:53 pm Permalink

    nevermind, i can’t read

  17. china jaw crushers
    18/03/2013 at 8:47 am Permalink

    i like to do all the talking myself. it saves time, and prevents arguments.