使用Google App Engine管理命令的Django会抛出DatabaseError

时间:2012-10-18 15:23:18

标签: django google-app-engine

当我运行管理命令时,它会打开一个浏览器窗口。 我验证了创建oauth文件~/.googlesql_oauth2.dat的应用程序。

但之后它会抛出一个DatabaseError。

End user Google Account not authorized.enter

任何想法如何解决这个问题?

堆栈跟踪:

Unhandled exception in thread started by <bound method Command.inner_run of <django.core.management.commands.runserver.Command object at 0x100646f50>>
Traceback (most recent call last):
  File "/usr/local/google_appengine/lib/django_1_3/django/core/management/commands/runserver.py", line 88, in inner_run
    self.validate(display_num_errors=True)
  File "/usr/local/google_appengine/lib/django_1_3/django/core/management/base.py", line 249, in validate
    num_errors = get_validation_errors(s, app)
  File "/usr/local/google_appengine/lib/django_1_3/django/core/management/validation.py", line 102, in get_validation_errors
    connection.validation.validate_field(e, opts, f)
  File "/usr/local/google_appengine/lib/django_1_3/django/db/backends/mysql/validation.py", line 14, in validate_field
    db_version = self.connection.get_server_version()
  File "/usr/local/google_appengine/lib/django_1_3/django/db/backends/mysql/base.py", line 338, in get_server_version
    self.cursor()
  File "/usr/local/google_appengine/lib/django_1_3/django/db/backends/__init__.py", line 250, in cursor
    cursor = self.make_debug_cursor(self._cursor())
  File "/usr/local/google_appengine/google/storage/speckle/python/django/backend/base.py", line 223, in _cursor
    self.connection = Connect(**kwargs)
  File "/usr/local/google_appengine/google/storage/speckle/python/django/backend/base.py", line 195, in Connect
    return driver.connect(**kwargs)
  File "/usr/local/google_appengine/google/storage/speckle/python/api/rdbms_googleapi.py", line 183, in __init__
    super(GoogleApiConnection, self).__init__(*args, **kwargs)
  File "/Applications/GoogleAppEngineLauncher.app/Contents/Resources/GoogleAppEngine-default.bundle/Contents/Resources/google_appengine/google/storage/speckle/python/api/rdbms.py", line 583, in __init__
    self.OpenConnection()
  File "/Applications/GoogleAppEngineLauncher.app/Contents/Resources/GoogleAppEngine-default.bundle/Contents/Resources/google_appengine/google/storage/speckle/python/api/rdbms.py", line 606, in OpenConnection
    response = self.MakeRequest('OpenConnection', request)
  File "/Applications/GoogleAppEngineLauncher.app/Contents/Resources/GoogleAppEngine-default.bundle/Contents/Resources/google_appengine/google/storage/speckle/python/api/rdbms.py", line 718, in MakeRequest
    response.sql_exception.message))
google.storage.speckle.python.api.rdbms.DatabaseError: 0: End user Google Account not authorized.enter

1 个答案:

答案 0 :(得分:0)

好的,我在授权-.-

时以其他用户身份登录