Optional and resilient last_edition extension#1724
Open
parulin wants to merge 4 commits into
Open
Conversation
Prevent sphinx-autobuild from hanging indefinitely when git is slow or locked. Fall back to last_edition_datetime=None on timeout. Signed-off-by: suhr25 <suhridmarwah07@gmail.com>
…r handling - Reduce default subprocess timeout from 5s to 1s to avoid accumulating delay across ~190 pages; make it overridable via QUBES_LAST_EDITION_TIMEOUT - Extend exception handling to also catch FileNotFoundError, PermissionError, and OSError so any git invocation failure is silently ignored - Gate the extension in conf.py behind READTHEDOCS or QUBES_DOC_FULL_BUILD env vars to avoid running git on every plain local build
* add a section about building with environment variables * rewrite part of the last_edition extension section * use `QUBES_DOC_` prefix to be consistent * minor typos in how-to-edit-the-rst-documentation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Note: it's not my work but I would like to keep #1636 opened
This PR originally fixed a blocking issue in
_ext/last_edition.pywhere agit logsubprocess is executed without a timeout inside thehtml_page_contexthook.Now, the
last_editionextension is only loaded when aQUBES_DOC_FULL_BUILDenvironment variable is set.The use of environment variable is now documented (including the onion meta tag).