Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/python/289.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Python 静态文件处理程序Google应用程序引擎_Python_Google App Engine_Http - Fatal编程技术网

Python 静态文件处理程序Google应用程序引擎

Python 静态文件处理程序Google应用程序引擎,python,google-app-engine,http,Python,Google App Engine,Http,新的应用程序引擎。我需要验证我的网站与谷歌网站管理员 下面是我添加到app.yaml的内容 handlers: - url: /img static_dir: static/img - url: /google6432717e3cdee901.html static_files: /google6432717e3cdee901.html upload: /google6432717e3cdee901.html 然而,访问site.com/google6432717e3cdee9

新的应用程序引擎。我需要验证我的网站与谷歌网站管理员

下面是我添加到app.yaml的内容

handlers:

- url: /img
  static_dir: static/img

- url: /google6432717e3cdee901.html
  static_files: /google6432717e3cdee901.html
  upload: /google6432717e3cdee901.html
然而,访问
site.com/google6432717e3cdee901.html
会给我一个404错误

如何修复我的处理程序,以便访问文件并进行验证


谢谢你的帮助

不要在
静态_文件
上传
指令中包含前导的
/
(除非文件确实位于文件系统的根目录,这可能是个坏主意)。

不要在
静态_文件
上传
指令中包含前导的
/
(除非文件确实位于文件系统的根目录,否则这可能是个坏主意).

如果可能,请提供整个app.yaml文件数据。更新应用程序时是否出现任何错误?我想说的是,您需要从静态_文件中删除前导斜杠并上载。如果可能,请提供整个app.yaml文件数据。如果更新应用程序时出现任何错误,请提供完整的app.yaml文件数据。我想说,您需要从静态_文件中删除前导斜杠静态文件和上传。