0

环境:ubuntu-x32bit/python2.7/gae 1.8.1

运行dev_appserver.py抛出以下错误:

$ python dev_appserver.py
Traceback (most recent call last):
  File "dev_appserver.py", line 182, in <module>
    _run_file(__file__, globals())
  File "dev_appserver.py", line 178, in _run_file
    execfile(script_path, globals_)
  File "/home/adminuser/dev/apps/gae/google_appengine/google/appengine/tools/devappserver2/devappserver2.py", line 30, in <module>
    from google.appengine.datastore import datastore_stub_util
  File "/home/adminuser/dev/apps/gae/google_appengine/google/appengine/datastore/datastore_stub_util.py", line 193
    datastore_types.SCATTER_SPECIAL_PROPERTY:.get(prefix, (0, et_bdatastore#!/usr/bihOPERTY:.get(preob.Pth the actual:
                                             ^
SyntaxError: invalid syntax

我试过这些:

apt-get build-dep python

python dev_appserver.py --clear_datastore=yes ../path/to_app

echo $PATH

/usr/lib/lightdm/lightdm:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/home/adminuser/dev/apps/gae/google_appengine/:/home/adminuser/dev/apps/gae/google_appengine/

4

1 回答 1

1

看起来您的 SDK 分发已损坏。

datastore_stub_util.py 的第 193 行看起来像

datastore_types.SCATTER_SPECIAL_PROPERTY: (False, True, _GetScatterProperty)

我会重新下载它。

问候

蒂姆

于 2013-10-11T08:22:28.503 回答