[mod_python] plotting modpython

Sean Davis sdavis2 at mail.nih.gov
Thu Oct 16 08:56:27 EDT 2008


2008/10/16 Handrix <handrix at gmail.com>:
> Hello,
>
> I'm working with modpython and I need to draw some statistic, so my choise
> was about matplotlib.
> so when execute this example :
>
> #########################
> from pylab import *
> import matplotlib
> matplotlib.use('Agg')
>
> plot([1,2,3,4])
> savefig('test')
> #########################
>
> I got a Runtime error :
> RuntimeError: Could not open file test.png

Is this a permissions problem?  If you try saving to somewhere (like
/tmp) where everyone has write privileges, does that eliminate the
problem?

Sean


More information about the Mod_python mailing list