views:

303

answers:

3

Specifically, are there any libraries that do not use sockets? I will be running this code in Google App Engine, which does not allow the use of sockets.

Google app engine does allow the use of urllib2 to make web requests.

I've been trying to get mechanize to work, since that what I've used before, but if there's something easier, I'd rather do that.

thanks, Mark

A: 

How would you download pages without using sockets? That's like eating without mouth. Maybe GAE have some kind of I.V. API, tho.

alamar
Eating without months? GAE does allow the use of urllib2, and also has it's own url fetch API (which uses urllib2 I think).
MStodd
.. and urllib2 uses httplib, which uses sockets. you need sockets to do http, and therefore anything "web" needs sockets
Corey Goldberg
yes, and google app engine doesn't expose them to developers, but does expose their implementation of urllib2
MStodd
A: 

To answer your question, twill and webunit are some other Python programmatic web browsing libraries. However, I'd be surprised if any of them worked off the bat with Google App Engine given the restricted stdlib.

Hao Lian
+1  A: 

urlfetch seems to do the same thing that you are looking for.

Niranjan Tulpule