Skip to content

Commit

Permalink
Allow sphinx-autobuild time to shutdown http server in tox
Browse files Browse the repository at this point in the history
- Tox is apparently a bit aggressive in shutting down processes when it
  receives a CTRL+C; this can ultimately result in tox exiting and
  leaving the HTTP server still running requiring manual process kills.
- I think this results from ``sphinx-autobuild`` receiving the SIGINT
  and starting its shutdown...but tox then sends it _another_ SIGINT
  that seems to abort the shutdown procedure for ``sphinx-autobuild``.
- So, this gives ``sphinx-autobuild`` a window of time to shutdown
  before tox starts trying to help.
  • Loading branch information
rmartin16 committed Jun 13, 2024
1 parent 29a0adb commit 4ea3c24
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 0 deletions.
1 change: 1 addition & 0 deletions changes/2647.misc.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
The "live docs" tox environments were updated to allow a grace period for ``sphinx-autobuild`` to shutdown the HTTP server. Without waiting, the HTTP server may have been left running when tox exited.
2 changes: 2 additions & 0 deletions tox.ini
Original file line number Diff line number Diff line change
Expand Up @@ -93,6 +93,8 @@ sphinx_args = -T -W --keep-going --jobs auto

[testenv:docs{,-lint,-all,-live,-live-src}]
skip_install = True
# give sphinx-autobuild time to shutdown http server
suicide_timeout = 1
deps =
# editable install so docstrings can be updated for 'all' and 'live'
-e {tox_root}{/}core[docs]
Expand Down

0 comments on commit 4ea3c24

Please sign in to comment.