[Python-modules-team] Bug#885326: flask-peewee: please make the build reproducible

Chris Lamb lamby at debian.org
Tue Dec 26 09:19:53 UTC 2017


Source: flask-peewee
Version: 0.6.7-1
Severity: wishlist
Tags: patch
User: reproducible-builds at lists.alioth.debian.org
Usertags: buildpath
X-Debbugs-Cc: reproducible-bugs at lists.alioth.debian.org

Hi,

Whilst working on the Reproducible Builds effort [0], we noticed
that flask-peewee could not be built reproducibly.

This is because it generates Python "doctree" files. These are pickled
caches of the source *.rst documents which are not needed to display
the docs correctly (we only need the contents of the html/ folder or
the manpages themselves) and they contain absolute build paths which
are not reproducible.

Patch attached that does not install the .doctree files, additionally
speeding up the build (!) by actually using them as a cache between the
HTML and manpage generation :)

 [0] https://reproducible-builds.org/


Regards,

-- 
      ,''`.
     : :'  :     Chris Lamb
     `. `'`      lamby at debian.org / chris-lamb.co.uk
       `-
-------------- next part --------------
--- a/debian/rules	2017-12-26 08:41:29.306724894 +0000
--- b/debian/rules	2017-12-26 09:15:50.208246261 +0000
@@ -6,12 +6,15 @@
 
 override_dh_auto_build:
 	dh_auto_build
-	PYTHONPATH=. sphinx-build -N -bhtml docs/ docs/build/html # HTML generator
-	PYTHONPATH=. sphinx-build -N -bman docs/ docs/build/man # Manpage generator
+	PYTHONPATH=. sphinx-build -N -bhtml docs/ -d debian/doctrees docs/build/html # HTML generator
+	PYTHONPATH=. sphinx-build -N -bman docs/ -d debian/doctrees docs/build/man # Manpage generator
 
 override_dh_auto_test:
 	# The tarball doesn't contain runtest.py.
 
+override_dh_auto_clean: 
+	rm -rf debian/doctrees
+
 override_dh_auto_install: 
 	dh_auto_install
 	# We don't install examples in dist-packages


More information about the Python-modules-team mailing list