Django 应用引擎获取操作错误:无法连接
我在google appengine上有一个python/django应用程序,后台是cloud sql,我得到了这些Django 应用引擎获取操作错误:无法连接,django,google-app-engine,python-2.7,Django,Google App Engine,Python 2.7,我在google appengine上有一个python/django应用程序,后台是cloud sql,我得到了这些操作错误:无法连接:ApplicationError:1暂时错误,请重试。偶尔出现异常。我想知道是什么原因导致这些错误,以及解决此问题的快速解决方案。 我得到的堆栈跟踪是 Following are the exception stacktrace details: Traceback (most recent call last): File "/base/data/h
操作错误:无法连接:ApplicationError:1暂时错误,请重试。
偶尔出现异常。我想知道是什么原因导致这些错误,以及解决此问题的快速解决方案。
我得到的堆栈跟踪是
Following are the exception stacktrace details:
Traceback (most recent call last):
File "/base/data/home/apps/myapp/2.382853299895889191/django/core/handlers/base.py",
line 111, in get_response
response = callback(request, *callback_args, **callback_kwargs)
File "/base/data/home/apps/myapp/2.382853299895889191/django/views/generic/base.py",
line 48, in view
return self.dispatch(request, *args, **kwargs)
File
"/base/data/home/apps/myapp/2.382853299895889191/django/views/generic/base.py",
line 69, in dispatch
return handler(request, *args, **kwargs)
File "/base/data/home/apps/myapp/2.382853299895889191/murthy_views.py",
line 370, in get
cartd = cart.Add(cartd, catalogid, item.quantity,item.redeem)
File "/base/data/home/apps/myapp/2.382853299895889191/classes.py",
line 2488, in Add
cart_item = CartItem(catalog_id)
File "/base/data/home/apps/myapp/2.382853299895889191/classes.py",
line 3789, in __init__
self.FillItem(item_id)
File "/base/data/home/apps/myapp/2.382853299895889191/classes.py",
line 3810, in FillItem
if not
product_list:
File "/base/data/home/apps/myapp/2.382853299895889191/django/db/models/query.py",
line 130, in __nonzero__
iter(self).next()
File "/base/data/home/apps/myapp/2.382853299895889191/django/db/models/query.py",
line 118, in _result_iter
self._fill_cache()
File "/base/data/home/apps/myapp/2.382853299895889191/django/db/models/query.py",
line 892, in _fill_cache
self._result_cache.append(self._iter.next())
File "/base/data/home/apps/myapp/2.382853299895889191/django/db/models/query.py",
line 291, in iterator
for row in compiler.results_iter():
File "/base/data/home/apps/myapp/2.382853299895889191/django/db/models/sql/compiler.py",
line 763, in results_iter
for rows in self.execute_sql(MULTI):
File "/base/data/home/apps/myapp/2.382853299895889191/django/db/models/sql/compiler.py",
line 823, in execute_sql
cursor = self.connection.cursor()
File "/base/data/home/apps/myapp/2.382853299895889191/django/db/backends/__init__.py",
line 319, in cursor
cursor = util.CursorWrapper(self._cursor(), self)
File "/base/data/home/runtimes/python27/python27_lib/versions/1/google/storage/speckle/python/django/backend/base.py",
line 276, in _cursor
self.connection = Connect(**kwargs)
File "/base/data/home/runtimes/python27/python27_lib/versions/1/google/storage/speckle/python/django/backend/base.py",
line 201, in Connect
return driver.connect(**kwargs)
File "/base/data/home/runtimes/python27/python27_lib/versions/1/google/storage/speckle/python/api/rdbms.py",
line 813, in __init__
self.OpenConnection()
File "/base/data/home/runtimes/python27/python27_lib/versions/1/google/storage/speckle/python/api/rdbms.py",
line 836, in OpenConnection
response = self.MakeRequest('OpenConnection', request)
File "/base/data/home/runtimes/python27/python27_lib/versions/1/google/storage/speckle/python/api/rdbms.py",
line 943, in MakeRequest
response = self.MakeRequestImpl(stub_method, request)
File "/base/data/home/runtimes/python27/python27_lib/versions/1/google/storage/speckle/python/api/rdbms_apiproxy.py",
line 69, in MakeRequestImpl
raise OperationalError('could not
connect: ' + str(e))
OperationalError: could not connect: ApplicationError: 1 Transient error,
please try again.