I'm having problems with the project building on Read the Docs

生来就可爱ヽ(ⅴ<●) 提交于 2021-02-05 06:30:50

问题


Created sphinx project with sphinx-quickstart. Ran "make html" and no errors produced. Pushed all the code to GitHub. I tried to import and build project on Read the Docs, but get the following errors. I haven't problems when using a Mac- it builds and renders the code on Read the Docs. This time I'm using Windows 10.

Traceback (most recent call last):
  File "/home/docs/checkouts/readthedocs.org/user_builds/thirddocs/envs/latest/lib/python3.7/site-packages/sphinx/cmd/build.py", line 304, in build_main
    app.build(args.force_all, filenames)
  File "/home/docs/checkouts/readthedocs.org/user_builds/thirddocs/envs/latest/lib/python3.7/site-packages/sphinx/application.py", line 341, in build
    self.builder.build_update()
  File "/home/docs/checkouts/readthedocs.org/user_builds/thirddocs/envs/latest/lib/python3.7/site-packages/sphinx/builders/__init__.py", line 347, in build_update
    len(to_build))
  File "/home/docs/checkouts/readthedocs.org/user_builds/thirddocs/envs/latest/lib/python3.7/site-packages/sphinx/builders/__init__.py", line 360, in build
    updated_docnames = set(self.read())
  File "/home/docs/checkouts/readthedocs.org/user_builds/thirddocs/envs/latest/lib/python3.7/site-packages/sphinx/builders/__init__.py", line 472, in read
    self.env.doc2path(self.config.master_doc))
sphinx.errors.SphinxError: master file /home/docs/checkouts/readthedocs.org/user_builds/thirddocs/checkouts/latest/contents.rst not found

Sphinx error:
master file /home/docs/checkouts/readthedocs.org/user_builds/thirddocs/checkouts/latest/contents.rst not found

回答1:


It worked by just adding master_doc = 'index' to the conf.py file.



来源:https://stackoverflow.com/questions/55911648/im-having-problems-with-the-project-building-on-read-the-docs

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!