Re: eval(WsgiApplication)

2009-05-02 Thread Graham Dumpleton
On May 2, 10:15 pm, Дамјан Георгиевски wrote: > >> > How do I do this in python3? > > >> What's wrong with importing it? > > > The problem is that my wsgi files have a wsgi extention for mod_wsgi > > use > .. > > mod_wsgi has a .wsgi handler because it is recommended to rename the > > wsgi file wi

Re: eval(WsgiApplication)

2009-05-02 Thread gert
On May 2, 2:15 pm, Дамјан Георгиевски wrote: > >> > How do I do this in python3? > > >> What's wrong with importing it? > > > The problem is that my wsgi files have a wsgi extention for mod_wsgi > > use > .. > > mod_wsgi has a .wsgi handler because it is recommended to rename the > > wsgi file wit

Re: eval(WsgiApplication)

2009-05-02 Thread Дамјан Георгиевски
>> > How do I do this in python3? >> >> What's wrong with importing it? > > The problem is that my wsgi files have a wsgi extention for mod_wsgi > use .. > mod_wsgi has a .wsgi handler because it is recommended to rename the > wsgi file with wsgi extensions to avoid double imports > cherrypy serve

Re: eval(WsgiApplication)

2009-05-02 Thread gert
On May 2, 10:25 am, Arnaud Delobelle wrote: > gert writes: > > I would like to read the following from a text file > > > from json import loads > > from gert.db import Db > > def application(environ, response): > >     v = loads(environ['wsgi.input'].read(int(environ > > ['CONTENT_LENGTH'])).deco

Re: eval(WsgiApplication)

2009-05-02 Thread paul
gert schrieb: I would like to read the following from a text file Hi gert, I'm puzzled, what is wrong with using wsgi as advertised? Just import your code and insert it in the wsgi chain no? cheers Paul from json import loads from gert.db import Db def application(environ, response):

Re: eval(WsgiApplication)

2009-05-02 Thread Arnaud Delobelle
gert writes: > I would like to read the following from a text file > > from json import loads > from gert.db import Db > def application(environ, response): > v = loads(environ['wsgi.input'].read(int(environ > ['CONTENT_LENGTH'])).decode('utf-8')) > db = Db() > db.execute('UPDATE vote