views:

36

answers:

1

I want to use jinja2.PackageLoader on Google App engine, but that appears to depend on pkg_resources, which wasn't added until Python 2.6. Am I Out of luck?

+2  A: 

You should be able to include pkg_resources.py in your application directory (or elsewhere in sys.path if you're modifying it in your scripts); according to Guido it should work since App Engine 1.2.1.

Wooble
I was thinking this might be possible, but the thought of actually validating this in general seemed a bit scary. +1
TokenMacGuy
There are some patched versions of pkg_resource.py floating around that are supposed to help with this stuff, but after spending around 3 hours trying to figure out what is actually happening and trying to get it to work, I've run out of steam. templates will simply have to be loaded by their path.
TokenMacGuy