Skip to content

Commit

Permalink
catching Sphinx errors
Browse files Browse the repository at this point in the history
  • Loading branch information
jonrkarr committed Sep 17, 2018
1 parent 724a7f0 commit 9d3f786
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions karr_lab_build_utils/core.py
Original file line number Diff line number Diff line change
Expand Up @@ -1029,7 +1029,7 @@ def _run_tests_local(self, dirname='.', test_path='tests',
if with_xunit:
argv.append('--junitxml=' + abs_xml_latest_filename)

# collect tests
# collect tests
test_cases = self._get_test_cases(test_path=test_path,
n_workers=n_workers, i_worker=i_worker)
# run tests
Expand Down Expand Up @@ -2020,11 +2020,12 @@ def handle_exception(app, args, exception, stderr=sys.stderr):
raise

with patch('sphinx.cmdline.handle_exception', handle_exception):
sphinx_main([self.proj_docs_dir, self.proj_docs_build_html_dir])
self.run_method_and_capture_stderr(sphinx_main,
[self.proj_docs_dir, self.proj_docs_build_html_dir])

# run spell check
if spell_check:
sphinx_main([
self.run_method_and_capture_stderr(sphinx_main, [
'-b', 'spelling',
'-d', self.proj_docs_build_doctrees_dir,
self.proj_docs_dir,
Expand Down

0 comments on commit 9d3f786

Please sign in to comment.