First of all currently it is not possible to use straight sphinx-build command to build documentation out of source tree
+ /usr/bin/sphinx-build -n -T -b man docs build/sphinx/man
Running Sphinx v4.5.0
Traceback (most recent call last):
File "/usr/lib/python3.8/site-packages/sphinx/config.py", line 332, in eval_config_file
exec(code, namespace)
File "/home/tkloczko/rpmbuild/BUILD/mpmath-1.2.1/docs/conf.py", line 12, in <module>
import mpmath
ModuleNotFoundError: No module named 'mpmath'
The above exception was the direct cause of the following exception:
Traceback (most recent call last):
File "/usr/lib/python3.8/site-packages/sphinx/cmd/build.py", line 272, in build_main
app = Sphinx(args.sourcedir, args.confdir, args.outputdir,
File "/usr/lib/python3.8/site-packages/sphinx/application.py", line 202, in __init__
self.config = Config.read(self.confdir, confoverrides or {}, self.tags)
File "/usr/lib/python3.8/site-packages/sphinx/config.py", line 165, in read
namespace = eval_config_file(filename, tags)
File "/usr/lib/python3.8/site-packages/sphinx/config.py", line 345, in eval_config_file
raise ConfigError(msg % traceback.format_exc()) from exc
sphinx.errors.ConfigError: There is a programmable error in your configuration file:
Traceback (most recent call last):
File "/usr/lib/python3.8/site-packages/sphinx/config.py", line 332, in eval_config_file
exec(code, namespace)
File "/home/tkloczko/rpmbuild/BUILD/mpmath-1.2.1/docs/conf.py", line 12, in <module>
import mpmath
ModuleNotFoundError: No module named 'mpmath'
Configuration error:
There is a programmable error in your configuration file:
Traceback (most recent call last):
File "/usr/lib/python3.8/site-packages/sphinx/config.py", line 332, in eval_config_file
exec(code, namespace)
File "/home/tkloczko/rpmbuild/BUILD/mpmath-1.2.1/docs/conf.py", line 12, in <module>
import mpmath
ModuleNotFoundError: No module named 'mpmath'
This can be fixed by patch like below:
--- a/docs/conf.py~ 2022-05-19 10:39:35.000000000 +0000
+++ b/docs/conf.py 2022-05-19 10:41:04.481013587 +0000
@@ -1,3 +1,7 @@
+import sys
+import os
+sys.path.insert(0, os.path.abspath('..'))
+
"""
Mpmath documentation build configuration file.
This patch fixes what is in the comment and that can of fix is suggested in sphinx example copy.py https://www.sphinx-doc.org/en/master/usage/configuration.html#example-of-configuration-file
Than .. on building my packages I'm using sphinx-build command with -n switch which shows warmings about missing references. These are not critical issues.
Here is the output with warnings:
+ /usr/bin/sphinx-build -n -T -b man docs build/sphinx/man
Running Sphinx v4.5.0
making output directory... done
building [mo]: targets for 0 po files that are out of date
building [man]: all manpages
updating environment: [new config] 33 added, 0 changed, 0 removed
reading sources... [100%] technical
looking for now-outdated files... none found
pickling environment... done
checking consistency... done
writing... mpmath.1 { setup basics contexts general plotting functions/index functions/constants functions/powers functions/trigonometric functions/hyperbolic functions/gamma functions/expintegrals functions/bessel functions/orthogonal functions/hypergeometric functions/elliptic functions/zeta functions/numtheory functions/qfunctions calculus/index calculus/polynomials calculus/optimization calculus/sums_limits calculus/differentiation calculus/integration calculus/odes calculus/approximation calculus/inverselaplace matrices identification technical references } /home/tkloczko/rpmbuild/BUILD/mpmath-1.2.1/docs/setup.rst:147: WARNING: py:func reference target not found: call
/home/tkloczko/rpmbuild/BUILD/mpmath-1.2.1/docs/contexts.rst:84: WARNING: py:func reference target not found: repr
/home/tkloczko/rpmbuild/BUILD/mpmath-1.2.1/docs/general.rst:10: WARNING: py:func reference target not found: convert
/home/tkloczko/rpmbuild/BUILD/mpmath-1.2.1/mpmath/ctx_mp.py:docstring of mpmath.ctx_mp.MPContext.nstr:13: WARNING: py:func reference target not found: mpmath.libmp.to_str
/home/tkloczko/rpmbuild/BUILD/mpmath-1.2.1/mpmath/ctx_mp_python.py:docstring of mpmath.ctx_mp_python.PythonMPContext.fsum:1: WARNING: py:func reference target not found: sum
/home/tkloczko/rpmbuild/BUILD/mpmath-1.2.1/mpmath/functions/functions.py:docstring of mpmath.functions.functions.fabs:1: WARNING: py:func reference target not found: abs
/home/tkloczko/rpmbuild/BUILD/mpmath-1.2.1/mpmath/ctx_base.py:docstring of mpmath.ctx_base.StandardBaseContext.arange:1: WARNING: py:func reference target not found: mpmath.range
/home/tkloczko/rpmbuild/BUILD/mpmath-1.2.1/mpmath/ctx_base.py:docstring of mpmath.ctx_base.StandardBaseContext.arange:1: WARNING: py:func reference target not found: mpmath.range
/home/tkloczko/rpmbuild/BUILD/mpmath-1.2.1/mpmath/ctx_base.py:docstring of mpmath.ctx_base.StandardBaseContext.arange:15: WARNING: py:func reference target not found: mpmath.range
/home/tkloczko/rpmbuild/BUILD/mpmath-1.2.1/docs/functions/constants.rst:29: WARNING: py:data reference target not found: j
/home/tkloczko/rpmbuild/BUILD/mpmath-1.2.1/docs/functions/constants.rst:29: WARNING: py:data reference target not found: inf
/home/tkloczko/rpmbuild/BUILD/mpmath-1.2.1/docs/functions/constants.rst:29: WARNING: py:data reference target not found: nan
/home/tkloczko/rpmbuild/BUILD/mpmath-1.2.1/docs/functions/constants.rst:29: WARNING: py:class reference target not found: mpc
/home/tkloczko/rpmbuild/BUILD/mpmath-1.2.1/docs/functions/constants.rst:29: WARNING: py:class reference target not found: mpf
/home/tkloczko/rpmbuild/BUILD/mpmath-1.2.1/mpmath/ctx_mp_python.py:docstring of mpmath.ctx_mp_python.PythonMPContext._wrap_libmp_function.<locals>.f:34: WARNING: py:func reference target not found: mpmath.iv.sqrt
/home/tkloczko/rpmbuild/BUILD/mpmath-1.2.1/mpmath/functions/functions.py:docstring of mpmath.functions.functions.root:30: WARNING: py:func reference target not found: mpmath.nthroot
/home/tkloczko/rpmbuild/BUILD/mpmath-1.2.1/mpmath/functions/functions.py:docstring of mpmath.functions.functions.root:37: WARNING: py:func reference target not found: mpmath.nthroot
/home/tkloczko/rpmbuild/BUILD/mpmath-1.2.1/mpmath/ctx_mp_python.py:docstring of mpmath.ctx_mp_python.PythonMPContext._wrap_libmp_function.<locals>.f:37: WARNING: py:func reference target not found: mpmath.iv.exp
/home/tkloczko/rpmbuild/BUILD/mpmath-1.2.1/mpmath/ctx_mp_python.py:docstring of mpmath.ctx_mp_python.PythonMPContext._wrap_libmp_function.<locals>.f:16: WARNING: py:func reference target not found: mpmath.iv.cos
/home/tkloczko/rpmbuild/BUILD/mpmath-1.2.1/mpmath/ctx_mp_python.py:docstring of mpmath.ctx_mp_python.PythonMPContext._wrap_libmp_function.<locals>.f:16: WARNING: py:func reference target not found: mpmath.iv.sin
/home/tkloczko/rpmbuild/BUILD/mpmath-1.2.1/mpmath/ctx_mp_python.py:docstring of mpmath.ctx_mp_python.PythonMPContext._wrap_libmp_function.<locals>.f:19: WARNING: py:func reference target not found: mpmath.iv.tan
/home/tkloczko/rpmbuild/BUILD/mpmath-1.2.1/mpmath/ctx_mp_python.py:docstring of mpmath.ctx_mp_python.PythonMPContext._wrap_specfun.<locals>.f_wrapped:19: WARNING: py:func reference target not found: mpmath.iv.sec
/home/tkloczko/rpmbuild/BUILD/mpmath-1.2.1/mpmath/ctx_mp_python.py:docstring of mpmath.ctx_mp_python.PythonMPContext._wrap_specfun.<locals>.f_wrapped:18: WARNING: py:func reference target not found: mpmath.iv.csc
/home/tkloczko/rpmbuild/BUILD/mpmath-1.2.1/mpmath/ctx_mp_python.py:docstring of mpmath.ctx_mp_python.PythonMPContext._wrap_specfun.<locals>.f_wrapped:19: WARNING: py:func reference target not found: mpmath.iv.cot
/home/tkloczko/rpmbuild/BUILD/mpmath-1.2.1/docs/functions/gamma.rst:24: WARNING: py:func reference target not found: fac
/home/tkloczko/rpmbuild/BUILD/mpmath-1.2.1/mpmath/ctx_mp_python.py:docstring of mpmath.ctx_mp_python.PythonMPContext._wrap_libmp_function.<locals>.f:34: WARNING: py:func reference target not found: mpmath.fac
/home/tkloczko/rpmbuild/BUILD/mpmath-1.2.1/mpmath/ctx_mp_python.py:docstring of mpmath.ctx_mp_python.PythonMPContext._wrap_specfun.<locals>.f_wrapped:1: WARNING: py:func reference target not found: mpmath.expint(n,z)
/home/tkloczko/rpmbuild/BUILD/mpmath-1.2.1/docs/functions/hypergeometric.rst:23: WARNING: py:func reference target not found: hypercomb
/home/tkloczko/rpmbuild/BUILD/mpmath-1.2.1/docs/functions/hypergeometric.rst:23: WARNING: py:func reference target not found: hyper
/home/tkloczko/rpmbuild/BUILD/mpmath-1.2.1/docs/functions/hypergeometric.rst:71: WARNING: py:func reference target not found: hyper
/home/tkloczko/rpmbuild/BUILD/mpmath-1.2.1/docs/functions/hypergeometric.rst:75: WARNING: py:func reference target not found: hypercomb
/home/tkloczko/rpmbuild/BUILD/mpmath-1.2.1/mpmath/functions/elliptic.py:docstring of mpmath.functions.elliptic.ellipfun:15: WARNING: py:func reference target not found: mpmath.nome
/home/tkloczko/rpmbuild/BUILD/mpmath-1.2.1/docs/functions/numtheory.rst:11: WARNING: py:func reference target not found: fib
/home/tkloczko/rpmbuild/BUILD/mpmath-1.2.1/mpmath/ctx_mp_python.py:docstring of mpmath.ctx_mp_python.PythonMPContext._wrap_libmp_function.<locals>.f:15: WARNING: py:func reference target not found: mpmath.fib
/home/tkloczko/rpmbuild/BUILD/mpmath-1.2.1/mpmath/calculus/quadrature.py:docstring of mpmath.calculus.quadrature.QuadratureMethods.quad:55: WARNING: py:func reference target not found: mpmath.quadts
/home/tkloczko/rpmbuild/BUILD/mpmath-1.2.1/mpmath/calculus/quadrature.py:docstring of mpmath.calculus.quadrature.QuadratureMethods.quad:55: WARNING: py:func reference target not found: mpmath.quadgl
/home/tkloczko/rpmbuild/BUILD/mpmath-1.2.1/mpmath/calculus/quadrature.py:docstring of mpmath.calculus.quadrature.QuadratureMethods.quad:83: WARNING: py:class reference target not found: TanhSinh
/home/tkloczko/rpmbuild/BUILD/mpmath-1.2.1/mpmath/calculus/quadrature.py:docstring of mpmath.calculus.quadrature.QuadratureMethods.quad:83: WARNING: py:class reference target not found: GaussLegendre
/home/tkloczko/rpmbuild/BUILD/mpmath-1.2.1/mpmath/calculus/quadrature.py:docstring of mpmath.calculus.quadrature.QuadratureRule:10: WARNING: py:func reference target not found: mpmath.__new__
/home/tkloczko/rpmbuild/BUILD/mpmath-1.2.1/mpmath/calculus/quadrature.py:docstring of mpmath.calculus.quadrature.QuadratureRule.calc_nodes:1: WARNING: py:func reference target not found: mpmath.get_nodes
/home/tkloczko/rpmbuild/BUILD/mpmath-1.2.1/mpmath/calculus/quadrature.py:docstring of mpmath.calculus.quadrature.QuadratureRule.get_nodes:1: WARNING: py:func reference target not found: mpmath.calc_nodes
/home/tkloczko/rpmbuild/BUILD/mpmath-1.2.1/mpmath/calculus/quadrature.py:docstring of mpmath.calculus.quadrature.QuadratureRule.get_nodes:6: WARNING: py:func reference target not found: mpmath.calc_nodes
/home/tkloczko/rpmbuild/BUILD/mpmath-1.2.1/mpmath/calculus/quadrature.py:docstring of mpmath.calculus.quadrature.QuadratureRule.guess_degree:11: WARNING: py:func reference target not found: mpmath.guess_degree
/home/tkloczko/rpmbuild/BUILD/mpmath-1.2.1/mpmath/calculus/quadrature.py:docstring of mpmath.calculus.quadrature.QuadratureRule.sum_next:4: WARNING: py:func reference target not found: mpmath.summation
/home/tkloczko/rpmbuild/BUILD/mpmath-1.2.1/mpmath/calculus/quadrature.py:docstring of mpmath.calculus.quadrature.QuadratureRule.sum_next:4: WARNING: py:func reference target not found: mpmath.sum_next
/home/tkloczko/rpmbuild/BUILD/mpmath-1.2.1/mpmath/calculus/quadrature.py:docstring of mpmath.calculus.quadrature.QuadratureRule.summation:1: WARNING: py:func reference target not found: mpmath.estimate_error
/home/tkloczko/rpmbuild/BUILD/mpmath-1.2.1/mpmath/calculus/quadrature.py:docstring of mpmath.calculus.quadrature.QuadratureRule.summation:6: WARNING: py:func reference target not found: mpmath.summation
/home/tkloczko/rpmbuild/BUILD/mpmath-1.2.1/mpmath/calculus/quadrature.py:docstring of mpmath.calculus.quadrature.QuadratureRule.summation:6: WARNING: py:func reference target not found: mpmath.sum_next
/home/tkloczko/rpmbuild/BUILD/mpmath-1.2.1/mpmath/calculus/inverselaplace.py:docstring of mpmath.calculus.inverselaplace.LaplaceTransformInversionMethods.invertlaplace:97: WARNING: py:func reference target not found: mpmath.invlaptalbot
/home/tkloczko/rpmbuild/BUILD/mpmath-1.2.1/mpmath/calculus/inverselaplace.py:docstring of mpmath.calculus.inverselaplace.LaplaceTransformInversionMethods.invertlaplace:97: WARNING: py:func reference target not found: mpmath.invlapstehfest
/home/tkloczko/rpmbuild/BUILD/mpmath-1.2.1/mpmath/calculus/inverselaplace.py:docstring of mpmath.calculus.inverselaplace.LaplaceTransformInversionMethods.invertlaplace:97: WARNING: py:func reference target not found: mpmath.invlapdehoog
/home/tkloczko/rpmbuild/BUILD/mpmath-1.2.1/mpmath/identification.py:docstring of mpmath.identification.identify:154: WARNING: py:func reference target not found: mpmath.eval
/home/tkloczko/rpmbuild/BUILD/mpmath-1.2.1/mpmath/identification.py:docstring of mpmath.identification.identify:163: WARNING: py:func reference target not found: mpmath.sympify
/home/tkloczko/rpmbuild/BUILD/mpmath-1.2.1/mpmath/identification.py:docstring of mpmath.identification.identify:187: WARNING: py:func reference target not found: mpmath.nsimplify
/home/tkloczko/rpmbuild/BUILD/mpmath-1.2.1/docs/technical.rst:98: WARNING: py:func reference target not found: str
/home/tkloczko/rpmbuild/BUILD/mpmath-1.2.1/docs/technical.rst:98: WARNING: py:func reference target not found: repr
done
build succeeded, 56 warnings.
You can peak on fixes that kind of issues in other projects
latchset/jwcrypto#289
click-contrib/sphinx-click@abc31069
First of all currently it is not possible to use straight
sphinx-buildcommand to build documentation out of source treeThis can be fixed by patch like below:
This patch fixes what is in the comment and that can of fix is suggested in sphinx example copy.py https://www.sphinx-doc.org/en/master/usage/configuration.html#example-of-configuration-file
Than .. on building my packages I'm using
sphinx-buildcommand with-nswitch which shows warmings about missing references. These are not critical issues.Here is the output with warnings:
You can peak on fixes that kind of issues in other projects
latchset/jwcrypto#289
click-contrib/sphinx-click@abc31069