#1066016 python-rdflib-doc: please make the build reproducible.

Package:
python-rdflib-doc
Source:
python-rdflib-doc
Submitter:
James Addison
Date:
2026-07-02 17:37:15 UTC
Severity:
normal
Tags:
#1066016#5
Date:
2024-03-10 23:38:27 UTC
From:
To:
Dear Maintainer,

I'm an occasional volunteer contributor with the Reproducible Builds[1]
project, and noticed recently that the python-rdflib-doc package failed[2] an
automated reproducibility test on Debian.

From investigation, it seems that most if not all of the cause of
non-reproducibility during the test was due to the Sphinx autodoc extension
evaluating some of the default Python method values (like
rdflib.extras.infixowl.Individual.factoryGraph[3]) at build-time and including
theevaluated value, which varied, in the documentation.

As a workaround, we can enable the 'autodoc_preserve_defaults'[4] configuration
setting, meaning that Sphinx will render the method signature defaults using the
original source code as-written, instead of evaluating the corresponding
values.

I'll offer a merge request on Salsa to make that change, and will link that to
this bugreport.

Thanks,
James

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

[2] - https://tests.reproducible-builds.org/debian/rb-pkg/trixie/amd64/diffoscope-results/rdflib.html

[3] - https://sources.debian.org/src/rdflib/6.1.1-3/docs/conf.py/#L41
https://sources.debian.org/src/rdflib/6.1.1-3/rdflib/extras/infixowl.py/#L371

[4] - https://www.sphinx-doc.org/en/master/usage/extensions/autodoc.html#confval-autodoc_preserve_defaults

#1066016#10
Date:
2024-03-11 00:16:12 UTC
From:
To:

#1066016#17
Date:
2024-03-14 12:36:41 UTC
From:
To:
We believe that the bug you reported is fixed in the latest version of
rdflib, which is due to be installed in the Debian FTP archive.

A summary of the changes between this version and the previous one is
attached.

Thank you for reporting the bug, which will now be closed.  If you
have further comments please address them to 1066016@bugs.debian.org,
and the maintainer will reopen the bug report if appropriate.

Debian distribution maintenance software
pp.
Michael R. Crusoe <crusoe@debian.org> (supplier of updated rdflib package)

(This message was generated automatically at their request; if you
believe that there is a problem with it please contact the archive
administrators by mailing ftpmaster@ftp-master.debian.org)
Format: 1.8
Date: Thu, 14 Mar 2024 13:21:35 +0100
Source: rdflib
Architecture: source
Version: 6.1.1-4
Distribution: unstable
Urgency: medium
Maintainer: Debian Python Team <team+python@tracker.debian.org>
Changed-By: Michael R. Crusoe <crusoe@debian.org>
Closes: 1063984 1066016 1066741
Changes:
 rdflib (6.1.1-4) unstable; urgency=medium
 .
   * Team upload.
 .
   [ James Addison ]
   * python-rdflib-doc: enable Sphinx autodoc preservation of method-
     argument defaults. Closes: #1066016
 .
   [ Michael R. Crusoe ]
   * d/patches/pytest8: support Pytest version 8.x. Closes: #1063984, #1066741
Checksums-Sha1:
 c4bc29a65e6c9c17fc112a60e6b52cfa3a2c9aa9 2720 rdflib_6.1.1-4.dsc
 11e4ff9a6ed4576eab4a5d88f77331f15b836352 30088 rdflib_6.1.1-4.debian.tar.xz
 4c45ff4135356fc7a48c97f4ebb33a8698d432f1 9506 rdflib_6.1.1-4_source.buildinfo
Checksums-Sha256:
 776eb35ce241321ae5fe15b58b8c80b1c72eecf4577245829b540e7f9a687457 2720 rdflib_6.1.1-4.dsc
 8f62f15b3990549c732da188f7c8767b4d9a8633f90626ad9a164143871aa967 30088 rdflib_6.1.1-4.debian.tar.xz
 9fdc45eb8e2f0894c786b86b58a2811386856da644a06588f583f806e38a1e8c 9506 rdflib_6.1.1-4_source.buildinfo
Files:
 e005e34bc6ab83f7e5a71b5a29da41d2 2720 python optional rdflib_6.1.1-4.dsc
 6b0242d2860841db65febe31b8aa7559 30088 python optional rdflib_6.1.1-4.debian.tar.xz
 be00a769cf402f01d402d7200668623a 9506 python optional rdflib_6.1.1-4_source.buildinfo
-----BEGIN PGP SIGNATURE-----

iQIzBAEBCgAdFiEEck1gkzcRPHEFUNdHPCZ2P2xn5uIFAmXy6+8ACgkQPCZ2P2xn
5uK2AhAAubwR9lzIc4DFSji2thWW/WdyD8UqEeGCybbM9s+C6xyC4aVhNg+rkiKI
3eJXGBjIx2UtIpU9DVGrKVyQucvJrH5FN6FaSo/hhTLPswiuP2joDz1ZojN6Xn9u
c79679YVs3ztt9oiydr6jK8U3cgY0gVdU4NRKijsz+QPtvl8Lxczu9IfBqQYhkEG
eyhgRzF9EUNy5pIExdoNiBuDATmAvax8Y3bzHYGW1YXTIdXjv6M5n12hdmAE2P7Y
aqvCKlw/fLiRu7ISO2NnKKgL9pirOPNf8LfNccp1YOILhqImUubf+Vko1rIsFlaz
y3dXypZG2epUBhcJcGtqEc9vHTvvgD9RyOQtmPwAK/c3Q1QgToYl1EmKIQ7loaBi
C3caww/lFnmWI1/RxQNpFVvjEdBsc4u8K05dTvdZ2udV8pKINhGlZIukeIKu5FAH
U+dUkteI8wunPU91ALwF48Bnlpu62kdIwSN1Bn3YpB/TO+PqsMdNWaXZ/hJNrzUy
Pm178XH5wBOrzR/7wPq6IZFRQSYiDLFBKaWKzDB2XkFfkt9G7HGxl/2nccickXXh
x1Km+mOBCXWfM0ub346DTcttDtEyXlXR3LgD9Tes5kf7e/jPHiuhu0OPOs/8Xt8b
JYy1xwvW7wojNsyHYaP0K0duqa7gWnBEo1BQYSR8T39IN9E59wI=
=gKmJ
-----END PGP SIGNATURE-----

#1066016#22
Date:
2024-03-14 13:04:29 UTC
From:
To:
Hi Michael,

Thank you for merging and uploading this change.  Unfortunately it seems that
my suggestion didn't solve the problem (based on inspecting the results of a
recent reprotest[1] on Salsa - there's still a '<Graph identifier=....>' with
randomness in the built documentation).

That's my mistake for not testing the patch thoroughly enough.  Please let me
know how to proceed (for example, whether you'd prefer that I revert the
change).

This also means that the autodoc config setting may be more limited in
solving these kind of problems that I realized; I'll have to check some merge
requests that I have open for other packages.

Thank you,
James

[1] - https://salsa.debian.org/python-team/packages/rdflib/-/jobs/5445372

#1066016#27
Date:
2024-03-14 13:27:43 UTC
From:
To:
control: repopen -1

On Thu, 14 Mar 2024 13:04:29 +0000 James Addison <jay@jp-hosting.net> wrote:
 > Hi Michael,
 >
 > Thank you for merging and uploading this change. Unfortunately it
seems that
 > my suggestion didn't solve the problem (based on inspecting the
results of a
 > recent reprotest[1] on Salsa - there's still a '<Graph
identifier=....>' with
 > randomness in the built documentation).
 >
 > That's my mistake for not testing the patch thoroughly enough. Please
let me
 > know how to proceed (for example, whether you'd prefer that I revert the
 > change).

Well, the build failed, so the CI on Salsa wasn't able to test your MR.
No worries, it isn't your fault!

I think the patch still helped, we can keep it while you continue your
investigations. I really appreciate it!