Skip to content

Commit e008e16

Browse files
authored
Revert "Fix detection for out of date files (#9360)" (#10908)
This reverts commit b1390c4. The change is reverted because some builders don't have fine-grained support for outdated docs: #10903 (comment)
1 parent cef1a03 commit e008e16

File tree

6 files changed

+6
-6
lines changed

6 files changed

+6
-6
lines changed

CHANGES

-2
Original file line numberDiff line numberDiff line change
@@ -20,8 +20,6 @@ Features added
2020
``:option:`--module[=foobar]``` or ``:option:`--module foobar```.
2121
Patch by Martin Liska.
2222
* #10881: autosectionlabel: Record the generated section label to the debug log.
23-
* #9360: Fix caching for now-outdated files for some builders (e.g. manpage)
24-
when there is no change in source files. Patch by Martin Liska.
2523

2624
Bugs fixed
2725
----------

sphinx/builders/__init__.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -347,7 +347,7 @@ def build(
347347
with progress_message(__('checking consistency')):
348348
self.env.check_consistency()
349349
else:
350-
if method == 'update' and (not docnames or docnames == ['__all__']):
350+
if method == 'update' and not docnames:
351351
logger.info(bold(__('no targets are out of date.')))
352352
return
353353

tests/test_build_html.py

+2
Original file line numberDiff line numberDiff line change
@@ -633,6 +633,7 @@ def test_tocdepth(app, cached_etree_parse, fname, expect):
633633
],
634634
}))
635635
@pytest.mark.sphinx('singlehtml', testroot='tocdepth')
636+
@pytest.mark.test_params(shared_result='test_build_html_tocdepth')
636637
def test_tocdepth_singlehtml(app, cached_etree_parse, fname, expect):
637638
app.build()
638639
check_xpath(cached_etree_parse(app.outdir / fname), fname, *expect)
@@ -1137,6 +1138,7 @@ def test_numfig_with_secnum_depth(app, cached_etree_parse, fname, expect):
11371138
],
11381139
}))
11391140
@pytest.mark.sphinx('singlehtml', testroot='numfig', confoverrides={'numfig': True})
1141+
@pytest.mark.test_params(shared_result='test_build_html_numfig_on')
11401142
def test_numfig_with_singlehtml(app, cached_etree_parse, fname, expect):
11411143
app.build()
11421144
check_xpath(cached_etree_parse(app.outdir / fname), fname, *expect)

tests/test_build_latex.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -1634,7 +1634,7 @@ def test_latex_container(app, status, warning):
16341634

16351635
@pytest.mark.sphinx('latex', testroot='reST-code-role')
16361636
def test_latex_code_role(app):
1637-
app.build(force_all=True)
1637+
app.build()
16381638
content = (app.outdir / 'python.tex').read_text()
16391639

16401640
common_content = (

tests/test_build_manpage.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ def test_man_pages_empty_description(app, status, warning):
4242
@pytest.mark.sphinx('man', testroot='basic',
4343
confoverrides={'man_make_section_directory': True})
4444
def test_man_make_section_directory(app, status, warning):
45-
app.build(force_all=True)
45+
app.build()
4646
assert (app.outdir / 'man1' / 'python.1').exists()
4747

4848

tests/test_build_texinfo.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ def test_texinfo(app, status, warning):
6060

6161
@pytest.mark.sphinx('texinfo', testroot='markup-rubric')
6262
def test_texinfo_rubric(app, status, warning):
63-
app.build(force_all=True)
63+
app.build()
6464

6565
output = (app.outdir / 'python.texi').read_text(encoding='utf8')
6666
assert '@heading This is a rubric' in output

0 commit comments

Comments
 (0)