-
-
Couldn't load subscription status.
- Fork 680
Description
Follow-up from #15791, #29033, #30053, the latter of which disabled use of system Python 3.6.
With Python 3.6, there is a failure building the documentation on ubuntu-bionic-standard (using /usr/bin/python3.6, https://github.com/mkoeppe/sage/runs/1106251169):
[dochtml] UnicodeDecodeError: 'ascii' codec can't decode byte 0xe2 in position 2661: ordinal not in range(128)
[dochtml] Full log file: logs/dochtml.log
Makefile:1876: recipe for target 'doc-html' failed
This is coming from #30002 "force C locale in docbuild and remove some obsolete stuff", which added this:
build/bin/sage-site: export LANG=C # to ensure it is possible to scrape out non-EN locale warnings
In the present ticket, we rework the fix in #30002 so that it works with Python 3.6 too (in which setting the "C" locale sabotages UTF-8 operation.)
Supporting Python 3.6 allows Sage to use the system Python on some older Linux distributions that are still in widespread use in scientific computing, including centos-8 and fedora-{26,27,28} (although Python 3.7.x packages are also available for these). See #29033 for more details.
For the unrelated failures in the Sphinx package installation that #29033 tried to work around, see #30008.
(#30008 is a dependency of this ticket merely for the convenience of testing.)
References:
- https://www.python.org/dev/peps/pep-0538/ "Coercing the legacy C locale to a UTF-8 based locale"
- https://www.python.org/dev/peps/pep-0540/ "Add a new UTF-8 mode"
- https://bugzilla.redhat.com/attachment.cgi?id=1233034&action=diff
Depends on #30008
CC: @antonio-rojas @dimpase @slel @orlitzky @kiwifb @embray @fchapoton
Component: build
Author: Matthias Koeppe
Branch/Commit: 945c8c5
Reviewer: Sébastien Labbé
Issue created by migration from https://trac.sagemath.org/ticket/30576