Skip to content

Minimize logic in our standard conf.py #1534

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
ericholscher opened this issue Aug 3, 2015 · 4 comments
Closed

Minimize logic in our standard conf.py #1534

ericholscher opened this issue Aug 3, 2015 · 4 comments
Labels
Improvement Minor improvement to code Needed: design decision A core team decision is required

Comments

@ericholscher
Copy link
Member

We currently have 2 conf.py files we generated:

  • One we append to every build
  • One we generate for users without a conf.py in their repo

I think we should remove a lot of the magic in our general conf.py, and keep it in the auto-generated one. The idea is that users can throw a repo with rst & md files, and we will generate docs for them without any configuration. But once they start using their own conf.py and building locally, we should keep the production settings as close to the local as possible.

Most of the Sphinx version requirements that we have are in our appended conf.py as well -- so if we remove some of the stuff that requires version checking (itself a specific version requirements, ironically), it should make RTD work with past releases again.

Refs #1531

@ericholscher ericholscher added the Improvement Minor improvement to code label Aug 3, 2015
@gregmuellegger
Copy link
Contributor

👍

Related: #885

@gregmuellegger
Copy link
Contributor

Hm, when using Sphinx for the documentation, aren't people going to build it locally first anyways before pushing it to readthedocs? Do you know of actual cases where people do not have a conf.py in their repository?

@stsewd
Copy link
Member

stsewd commented Feb 27, 2018

Is this issue still relevant? I'm not sure of what lines we could remove since it just:

  • Pass the source prefix to the context
  • Set the rtd theme when there isn't one or when the default is given
  • Add the rtd static path

If I understand correctly the html_context is used by the themes.
https://github.com/rtfd/readthedocs.org/blob/master/readthedocs/doc_builder/templates/doc_builder/conf.py.tmpl

@RichardLitt RichardLitt added the Needed: more information A reply from issue author is required label Mar 2, 2018
@agjohnson agjohnson added Needed: design decision A core team decision is required and removed Needed: more information A reply from issue author is required labels Jun 8, 2018
@stsewd
Copy link
Member

stsewd commented Mar 1, 2019

We don't have much logic now I believe, most of the stuff is metadata from the build/rtd to feed the theme and the extension.

Closing now, feel free to reopen if you consider.

@stsewd stsewd closed this as completed Mar 1, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Improvement Minor improvement to code Needed: design decision A core team decision is required
Projects
None yet
Development

No branches or pull requests

5 participants