Debian Bug report logs - #998059
sphinx: LANGUAGE environment variable inconsistently affects output of objects.inv

version graph

Package: sphinx; Maintainer for sphinx is Debian Python Team <team+python@tracker.debian.org>;

Reported by: "Chris Lamb" <lamby@debian.org>

Date: Fri, 29 Oct 2021 09:00:05 UTC

Severity: normal

Found in version 4.2.0-5

Reply or subscribe to this bug.

Toggle useless messages

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to debian-bugs-dist@lists.debian.org, reproducible-bugs@lists.alioth.debian.org, Debian Python Team <team+python@tracker.debian.org>:
Bug#998059; Package sphinx. (Fri, 29 Oct 2021 09:00:07 GMT) (full text, mbox, link).


Acknowledgement sent to "Chris Lamb" <lamby@debian.org>:
New Bug report received and forwarded. Copy sent to reproducible-bugs@lists.alioth.debian.org, Debian Python Team <team+python@tracker.debian.org>. (Fri, 29 Oct 2021 09:00:07 GMT) (full text, mbox, link).


Message #5 received at submit@bugs.debian.org (full text, mbox, reply):

From: "Chris Lamb" <lamby@debian.org>
To: submit@bugs.debian.org
Subject: sphinx: LANGUAGE environement variable inconsistently affects output of objects.inv
Date: Fri, 29 Oct 2021 09:57:41 +0100
Package: sphinx
Version: 4.2.0-5
Severity: normal
User: reproducible-builds@lists.alioth.debian.org
Usertags: toolchain
X-Debbugs-Cc: reproducible-bugs@lists.alioth.debian.org

Hi,

An update has rendered a lot of packages that use Sphinx
unreproducible — as in, generating different output regardless of
the surrounding environment.

I'm not entirely sure where the bug is here, but it seems like there is
something up with language handling and generating the objects.inv
file.

In particular, if we compare a 'first' build with LANGUAGE="en_GB:en"
and the 'second' with LANGUAGE="et_EE:et" environment variable, what
happens is that all of the documentation is identical *except* a
single entry in the objects.inv file which appears to be translated.

Decoding the zlib-encoded objects.inv file, I can see that the
difference is a translation one:

  # Sphinx inventory version 2
  # Project: OpenDrop
  # Version: 
  # The remainder of this file is compressed using zlib.

  developers/index std:doc -1 developers/index.html Developer notes
  -genindex std:label -1 genindex.html Index
  +genindex std:label -1 genindex.html Indeks
  getting_started/index std:doc -1 getting_started/index.html Getting Started
  index std:doc -1 index.html Overview
  modindex std:label -1 py-modindex.html Module Index
  py-modindex std:label -1 py-modindex.html Python Module Index

This is despite the output including the following logging message in
both builds:

  dumping search index in English (code: en)... done
  dumping object inventory... done

(Note the "code: en" here in both builds)

The curious thing is why 'Indeks' was translated and not, for
instance, 'Module Index'. Indeed, I've dumped some more info upstream
here, but filing a Debian bug as, as mentioned, it's causing a lot of
reproducibility issues.

  https://github.com/sphinx-doc/sphinx/issues/9778


Regards,

-- 
      ,''`.
     : :'  :     Chris Lamb
     `. `'`      lamby@debian.org / chris-lamb.co.uk
       `-




Changed Bug title to 'sphinx: LANGUAGE environment variable inconsistently affects output of objects.inv' from 'sphinx: LANGUAGE environement variable inconsistently affects output of objects.inv'. Request was from "Chris Lamb" <lamby@debian.org> to control@bugs.debian.org. (Sun, 31 Oct 2021 11:45:02 GMT) (full text, mbox, link).


Information forwarded to debian-bugs-dist@lists.debian.org, Debian Python Team <team+python@tracker.debian.org>:
Bug#998059; Package sphinx. (Wed, 02 Feb 2022 19:33:05 GMT) (full text, mbox, link).


Acknowledgement sent to "Rebecca N. Palmer" <rebecca_palmer@zoho.com>:
Extra info received and forwarded to list. Copy sent to Debian Python Team <team+python@tracker.debian.org>. (Wed, 02 Feb 2022 19:33:05 GMT) (full text, mbox, link).


Message #12 received at 998059@bugs.debian.org (full text, mbox, reply):

From: "Rebecca N. Palmer" <rebecca_palmer@zoho.com>
To: 998059@bugs.debian.org
Subject: reproducibility workaround for sphinx objects.inv
Date: Wed, 2 Feb 2022 19:30:04 +0000
For anyone else trying to work around this: LC_ALL=C.UTF-8 isn't enough 
but LC_ALL=C.UTF-8 LANGUAGE=C.UTF-8 is.

https://salsa.debian.org/med-team/snakemake/-/commit/8bf4db496feed2fa84f23018acba0033e321ef69
https://salsa.debian.org/med-team/snakemake/-/pipelines




Information forwarded to debian-bugs-dist@lists.debian.org, Debian Python Team <team+python@tracker.debian.org>:
Bug#998059; Package sphinx. (Thu, 26 May 2022 22:39:03 GMT) (full text, mbox, link).


Acknowledgement sent to Nicolas Boulenguez <nicolas@debian.org>:
Extra info received and forwarded to list. Copy sent to Debian Python Team <team+python@tracker.debian.org>. (Thu, 26 May 2022 22:39:03 GMT) (full text, mbox, link).


Message #17 received at 998059@bugs.debian.org (full text, mbox, reply):

From: Nicolas Boulenguez <nicolas@debian.org>
To: 998059@bugs.debian.org
Subject: reproducibility workaround for sphinx objects.inv
Date: Fri, 27 May 2022 00:38:27 +0200
A subclass of such issues affects punctuation.
For example, a straight apostrophe ' sometimes becomes an apostrophe ’
in the libxmlada package.
There are several links in the smartquotes section of
https://www.sphinx-doc.org/en/master/usage/configuration.html

Easy work-around:
  smartquotes=False in conf.py

Proper fix, when possible:
  use the right character in the .md sources in the first place.



Send a report that this bug log contains spam.


Debian bug tracking system administrator <owner@bugs.debian.org>. Last modified: Mon Sep 19 23:56:31 2022; Machine Name: buxtehude

Debian Bug tracking system

Debbugs is free software and licensed under the terms of the GNU Public License version 2. The current version can be obtained from https://bugs.debian.org/debbugs-source/.

Copyright © 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson, 2005-2017 Don Armstrong, and many other contributors.