在ReadTheDocs上构建Sphinx文档

时间:2012-11-13 13:28:53

标签: python django google-app-engine python-sphinx django-sphinx

有一种方法可以让readthedocs.org为在谷歌应用引擎上运行的Django项目(托管在git上)构建基于sphinx的文档吗?

我继续收到此错误:

Sphinx Standard Error
The Google App Engine SDK could not be found!

我创建了以下需求文件:

django
ez_setup
google-appengine

但ReadTheDocs无法解压google-appengine

Downloading/unpacking django (from -r docs/requirements.txt (line 1))
    Running setup.py egg_info for package django

Downloading/unpacking ez-setup (from -r docs/requirements.txt (line 2))
   Downloading ez_setup-0.9.tar.gz
   Running setup.py egg_info for package ez-setup

Downloading/unpacking google-appengine (from -r docs/requirements.txt (line 3))
   Running setup.py egg_info for package google-appengine
   Traceback (most recent call last):
       File "<string>", line 16, in <module>
       File  "/home/docs/checkouts/readthedocs.org/user_builds/****/envs/latest/build/google-appengine/setup.py", line 2, in <module>
       import ez_setup
   ImportError: No module named ez_setup
   Complete output from command python setup.py egg_info:
   Traceback (most recent call last):

File "<string>", line 16, in <module>

File "/home/docs/checkouts/readthedocs.org/user_builds/***/envs/latest/build/google-appengine/setup.py", line 2, in <module>

import ez_setup
ImportError: No module named ez_setup

1 个答案:

答案 0 :(得分:0)

ez_setup不是您通常依赖的东西。这是一个ez_setup.py文件,过去在setup.py旁边捆绑,以帮助没有安装setuptools(或distribute)的人。在你的setup.py中会是这样的:

try:
    import setuptools
except Import Error:
    # run ez_setup

但是你正在使用virtualenv,你现在几乎可以指望拥有virtualenv / setuptools /发布的人。因此,您可以删除所有ez_setup引用,尤其是requirements.txt

我认为您安装的ez_setup模块正在干扰应用引擎自己setup.py中的内容。