Sleep() function actually suspends the processing of the thread in which it 
is called by the operating system, allowing other threads and processes to 
execute while it sleeps. With multiple threads and processes, sleep() 
<http://net-informations.com/python/pro/sleep.htm> suspends your thread - 
it uses next to zero processing power.

On Wednesday, February 5, 2014 at 12:56:21 PM UTC+5:30, Vinny P wrote:
>
> On Wed, Jan 29, 2014 at 8:07 PM, max kraun <krau...@gmail.com 
> <javascript:>> wrote:
>>
>> When I run it on localhost it works, but when I run it on appspot.com it 
>> looks like if some pages are not counted. Sometimes it works, sometimes it 
>> does not. Sometimes it returns some errors ("Deadline exceeded while 
>> waiting for HTTP response from URL" or similar), too.
>>
>
>
> Hi Max,
>
> It's difficult to say exactly what the problem is without a more detailed 
> look at the logs, but you can try a few things:
>
> 1. Try adding a time.sleep call between each page retrieval. See 
> http://docs.python.org/2/library/time.html for usage. Sometimes App 
> Engine doesn't like it when repeated URL Fetch calls are made.
>
> 2. Try making sure the authentication token you're using is still valid. 
> For instance, you could make sure that the page you retrieved shows text 
> consistent with a logged-in user - for example, only "sign out" links and 
> not "sign in" links.
>
> 3. The deadline exceeded error comes because the other server took too 
> long to send back the response. You can increase this time by setting the 
> default fetch timeout: urlfetch.set_default_fetch_deadline(60) 
>  
> -----------------
> -Vinny P
> Technology & Media Advisor
> Chicago, IL
>
> App Engine Code Samples: http://www.learntogoogleit.com
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"Google App Engine" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-appengine+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/1bea4374-bcb9-44c0-ab38-d421d2381365%40googlegroups.com.

Reply via email to