DeadlineExceededError in the recent version of AppEngine lives only in one place so there is no need to try import it from both runtime (deployed) and runtime.apiproxy_errors (dev server) modules anymore.
authorPawel Solyga <Pawel.Solyga@gmail.com>
Thu, 16 Oct 2008 16:05:08 +0000
changeset 359 4308324241bc
parent 358 843d83b87282
child 360 5ad9cabb5892
DeadlineExceededError in the recent version of AppEngine lives only in one place so there is no need to try import it from both runtime (deployed) and runtime.apiproxy_errors (dev server) modules anymore. Patch by: Pawel Solyga Review by: to-be-reviewed
app/soc/views/helper/responses.py
--- a/app/soc/views/helper/responses.py	Thu Oct 16 15:22:41 2008 +0000
+++ b/app/soc/views/helper/responses.py	Thu Oct 16 16:05:08 2008 +0000
@@ -26,6 +26,7 @@
 import logging
 
 from google.appengine.api import users
+from google.appengine.runtime import DeadlineExceededError
 
 from django import http
 from django.template import loader
@@ -41,15 +42,6 @@
 import soc.views.helper.requests
 
 
-# DeadlineExceededError can live in two different places
-try:
-  # When deployed
-  from google.appengine.runtime import DeadlineExceededError
-except ImportError:
-  # In the development server
-  from google.appengine.runtime.apiproxy_errors import DeadlineExceededError
-
-
 def respond(request, template, context=None, response_args=None):
   """Helper to render a response, passing standard stuff to the response.