当我尝试从终端在Google App引擎中运行helloworld.py脚本时,会出现屏幕截图中显示的错误。
#My操作系统:Ubuntu.14。#
这是我的文件 app.yaml。
application: #My project Id.
version: 1
runtime: python27
threadsafe: true
api_version: 1
handlers:
- url: /static
static_dir: static
- url: /
static_files: static/index.html
upload: static/index\.html
secure: always
- url: /_ah/spi/.*
script: helloworld_api.app
libraries:
- name: endpoints
version: 1.0
问题在于我无法在本地计算机上部署我的代码。 任何帮助都会得到感谢。谢谢:) 我检查了在线Yaml解析器,它也显示了它的有效性。
答案 0 :(得分:0)
您错过了库行,端点库实际上被解释为处理程序列表的一部分,这是不正确的。
应该是这样的:
...
- url: /_ah/spi/.*
script: helloworld_api.app
libraries:
- name: endpoints
version: 1.0