Bug#922261: python-sunlight: FTBFS (Could not import extension sphinx.ext.pngmath)

2019-02-23 Thread Carsten Schoenert
Hi,

On Wed, Feb 13, 2019 at 08:16:36PM +, Santiago Vila wrote:
...
> make[2]: Entering directory '/<>/docs'
> sphinx-build -b html -d build/doctrees   source build/html
> Running Sphinx v1.8.3
> 
> Extension error:
> Could not import extension sphinx.ext.pngmath (exception: No module named 
> pngmath)
> make[2]: *** [Makefile:40: html] Error 2
> make[2]: Leaving directory '/<>/docs'
> make[1]: *** [debian/rules:21: override_dh_auto_build] Error 2
> make[1]: Leaving directory '/<>'
> make: *** [debian/rules:13: build-indep] Error 2
> dpkg-buildpackage: error: debian/rules build-indep subprocess returned exit 
> status 2
> 

the fix is rather trivial. The file docs/source/conf.py neededs to be
modified as sphinx.ext.pngmath is now been dropped in favour of
sphinx.ext.imgmath.

Please see attached patch for applying on top the packagig branch.

Regards
Carsten
>From 376ce69f5f4748fd077b13e84243078f86a172b4 Mon Sep 17 00:00:00 2001
From: Carsten Schoenert 
Date: Sat, 23 Feb 2019 20:08:41 +0100
Subject: [PATCH] adding a patch queue to fix FTBFS

added patch:
0001-Fix-FTBFS-with-sphinx-1.8.patch
---
 .../0001-Fix-FTBFS-with-sphinx-1.8.patch  | 23 +++
 debian/patches/series |  1 +
 2 files changed, 24 insertions(+)
 create mode 100644 debian/patches/0001-Fix-FTBFS-with-sphinx-1.8.patch
 create mode 100644 debian/patches/series

diff --git a/debian/patches/0001-Fix-FTBFS-with-sphinx-1.8.patch b/debian/patches/0001-Fix-FTBFS-with-sphinx-1.8.patch
new file mode 100644
index 000..4c3787e
--- /dev/null
+++ b/debian/patches/0001-Fix-FTBFS-with-sphinx-1.8.patch
@@ -0,0 +1,23 @@
+From: Carsten Schoenert 
+Date: Sat, 23 Feb 2019 19:50:52 +0100
+Subject: Fix-FTBFS-with-sphinx-1.8
+
+sphinx.ext.pngmath has been removed in favor of sphinx.ext.imgmath.
+replace the former with the latter in docs/source/conf.py.
+---
+ docs/source/conf.py | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/docs/source/conf.py b/docs/source/conf.py
+index 8ec8ee0..c0c7dd5 100644
+--- a/docs/source/conf.py
 b/docs/source/conf.py
+@@ -17,7 +17,7 @@ version = sunlight.__version__
+ # Add any Sphinx extension module names here, as strings. They can be extensions
+ # coming with Sphinx (named 'sphinx.ext.*') or your custom ones.
+ extensions = ['sphinx.ext.autodoc', 'sphinx.ext.intersphinx',
+-'sphinx.ext.todo', 'sphinx.ext.coverage', 'sphinx.ext.pngmath',
++'sphinx.ext.todo', 'sphinx.ext.coverage', 'sphinx.ext.imgmath',
+ 'sphinx.ext.ifconfig', 'sphinx.ext.viewcode']
+ 
+ # Add any paths that contain templates here, relative to this directory.
diff --git a/debian/patches/series b/debian/patches/series
new file mode 100644
index 000..4ef579c
--- /dev/null
+++ b/debian/patches/series
@@ -0,0 +1 @@
+0001-Fix-FTBFS-with-sphinx-1.8.patch
-- 
2.20.1



Bug#922261: python-sunlight: FTBFS (Could not import extension sphinx.ext.pngmath)

2019-02-13 Thread Santiago Vila
Package: src:python-sunlight
Version: 1.1.5-1
Severity: serious
Tags: ftbfs

Dear maintainer:

I tried to build this package in buster but it failed:


[...]
 debian/rules build-indep
dh build-indep --with python2,python3,sphinxdoc
dh: Compatibility levels before 9 are deprecated (level 8 in use)
   dh_update_autotools_config -i
   dh_auto_configure -i
dh_auto_configure: Compatibility levels before 9 are deprecated (level 8 in use)
dh_auto_configure: Please use the third-party "pybuild" build system instead of 
python-distutils
dh_auto_configure: This feature will be removed in compat 12.
   debian/rules override_dh_auto_build
make[1]: Entering directory '/<>'
set -xe; \
for py in python2.7 python3.7; do \
$py setup.py build; \
done
+ python2.7 setup.py build
running build
running build_py
creating build
creating build/lib.linux-x86_64-2.7
creating build/lib.linux-x86_64-2.7/sunlight
copying sunlight/config.py -> build/lib.linux-x86_64-2.7/sunlight
copying sunlight/__init__.py -> build/lib.linux-x86_64-2.7/sunlight
copying sunlight/errors.py -> build/lib.linux-x86_64-2.7/sunlight
copying sunlight/service.py -> build/lib.linux-x86_64-2.7/sunlight
creating build/lib.linux-x86_64-2.7/sunlight/services
copying sunlight/services/capitolwords.py -> 
build/lib.linux-x86_64-2.7/sunlight/services
copying sunlight/services/__init__.py -> 
build/lib.linux-x86_64-2.7/sunlight/services
copying sunlight/services/influenceexplorer.py -> 
build/lib.linux-x86_64-2.7/sunlight/services
copying sunlight/services/openstates.py -> 
build/lib.linux-x86_64-2.7/sunlight/services
copying sunlight/services/congress.py -> 
build/lib.linux-x86_64-2.7/sunlight/services
+ python3.7 setup.py build
running build
running build_py
creating build/lib
creating build/lib/sunlight
copying sunlight/config.py -> build/lib/sunlight
copying sunlight/__init__.py -> build/lib/sunlight
copying sunlight/errors.py -> build/lib/sunlight
copying sunlight/service.py -> build/lib/sunlight
creating build/lib/sunlight/services
copying sunlight/services/capitolwords.py -> build/lib/sunlight/services
copying sunlight/services/__init__.py -> build/lib/sunlight/services
copying sunlight/services/influenceexplorer.py -> build/lib/sunlight/services
copying sunlight/services/openstates.py -> build/lib/sunlight/services
copying sunlight/services/congress.py -> build/lib/sunlight/services
make -C docs html
make[2]: Entering directory '/<>/docs'
sphinx-build -b html -d build/doctrees   source build/html
Running Sphinx v1.8.3

Extension error:
Could not import extension sphinx.ext.pngmath (exception: No module named 
pngmath)
make[2]: *** [Makefile:40: html] Error 2
make[2]: Leaving directory '/<>/docs'
make[1]: *** [debian/rules:21: override_dh_auto_build] Error 2
make[1]: Leaving directory '/<>'
make: *** [debian/rules:13: build-indep] Error 2
dpkg-buildpackage: error: debian/rules build-indep subprocess returned exit 
status 2


(The above is just how the build ends and not necessarily the most relevant 
part)

The build was made in my autobuilder with "dpkg-buildpackage -A"
and it also fails here:

https://tests.reproducible-builds.org/debian/rb-pkg/unstable/amd64/python-sunlight.html

where you can get a full build log if you need it.

If this is really a bug in one of the build-depends, please use reassign and 
affects,
so that this is still visible in the BTS web page for this package.

Thanks.