Menu

#414 import of "latex2e" writer fails with Py3k (<3.7.3) and locale-encoding "ascii".

None
closed-fixed
nobody
None
2021-04-23
2021-04-04
xypron
No

In the header of docutils/writers/latex2e/docutils.sty version 0.17 there is a comment line containing Unicode characters:

%%   Copyright © 2020 Günter Milde

This lead to a build error when building the documentation for the U-Boot project:
https://source.denx.de/u-boot/u-boot/-/jobs/247572

Please, replace the Unicode characters by ASCII

%%   Copyright (c) 2020 Guenter Milde

Discussion

  • xypron

    xypron - 2021-04-04

    There are quite a lot of style sheets to fix:

    docutils/docutils/writers/latex2e/docutils.sty:3:%%   Copyright © 2020 Günter Milde
    sandbox/rst2context/context/docutils-05-compat.sty:8:% :Author:    Guenter Milde
    sandbox/rst2context/context/docutils-05-compat.sty:12:% :Copyright: © 2009 Günter Milde,
    sandbox/gitpull/setuptools/docutils/writers/latex2e/docutils-05-compat.sty:8:% :Author:    Guenter Milde
    sandbox/gitpull/setuptools/docutils/writers/latex2e/docutils-05-compat.sty:12:% :Copyright: © 2009 Günter Milde,
    sandbox/gitpull/docs-homepage-refactor/docutils/writers/latex2e/docutils-05-compat.sty:8:% :Author:    Guenter Milde
    sandbox/gitpull/docs-homepage-refactor/docutils/writers/latex2e/docutils-05-compat.sty:12:% :Copyright: © 2009 Günter Milde,
    sandbox/gitpull/docs-restructure/docutils/writers/latex2e/docutils-05-compat.sty:8:% :Author:    Guenter Milde
    sandbox/gitpull/docs-restructure/docutils/writers/latex2e/docutils-05-compat.sty:12:% :Copyright: © 2009 Günter Milde,
    sandbox/gitpull/web_stylesheet_and_menu/docutils/writers/latex2e/docutils-05-compat.sty:8:% :Author:    Guenter Milde
    sandbox/gitpull/web_stylesheet_and_menu/docutils/writers/latex2e/docutils-05-compat.sty:12:% :Copyright: © 2009 Günter Milde,
    sandbox/stylesheets/times-helvetica-courier.sty:6:% :Author:    Günter Milde <milde@users.berlios.de>
    sandbox/stylesheets/listings-python-options.sty:4:% :Author:    Günter Milde
    sandbox/stylesheets/transition-stars.sty:6:% :Author:    Günter Milde
    sandbox/stylesheets/transition-stars.sty:9:% :Copyright: © 2009 Günter Milde.
    sandbox/stylesheets/palatino-helvetica-courier.sty:6:% :Author:    Günter Milde <milde@users.berlios.de>
    sandbox/stylesheets/listings-tex-options.sty:6:% :Author:    Günter Milde
    sandbox/stylesheets/pygments-long.sty:3:% :Author:    Günter Milde
    
     
  • engelbert gruber

    only one .
    sandbox directories are peoples playground.
    interestingly this is in since at least 2009

     
  • engelbert gruber

    • status: open --> closed-fixed
     
  • Günter Milde

    Günter Milde - 2021-04-05
    • status: closed-fixed --> pending-remind
     
  • Günter Milde

    Günter Milde - 2021-04-05

    A LaTeX stylesheet is rather unlikely the source for a problem with "make: htmldocs".
    Please provide more info (link to the complete log/backtrack, settings (why not using utf8 or an 8-bit encoding?), ...

     

    Last edit: Günter Milde 2021-04-07
  • Varun Sharma

    Varun Sharma - 2021-04-07

    This issue was also raised in the Sphinx Github. I experienced this problem using Sphinx inside Docker. @grubert mentioned on Github that this may be due to setting LC_ALL=C, which apparently is set inside containers, that defaults the line-by-line reading of files to use ASCII. One fix that I tested was enforcing the open() commands to use the UTF-8 encoding (with encoding flag) rather than leaving it empty and implicit. Not sure if you'd want to do that though.

     

    Last edit: Varun Sharma 2021-04-07
  • Günter Milde

    Günter Milde - 2021-04-07
    • status: pending-remind --> open-fixed
     
  • Günter Milde

    Günter Milde - 2021-04-07

    Fixed in r8674. Thanks for the additional info.

    The problem could be reproduced by running the test suite with LC_ALL=C.
    Specifying the encoding when opening the LaTeX style file "docutils.sty" solved it.

    It remains a riddle, why Sphinx imports the LaTeX writer when building HTML, though.

     
  • Günter Milde

    Günter Milde - 2021-04-08
    • summary: non-ASCII characters in docutils/writers/latex2e/docutils.sty --> import of "latex2e" writer fails with Py3k (<3.5.7) and locale-encoding "ascii".
     
  • Günter Milde

    Günter Milde - 2021-04-08
    • summary: import of "latex2e" writer fails with Py3k (<3.5.7) and locale-encoding "ascii". --> import of "latex2e" writer fails with Py3k (<3.7.3) and locale-encoding "ascii".
     
  • Günter Milde

    Günter Milde - 2021-04-23
    • status: open-fixed --> closed-fixed
     
  • Günter Milde

    Günter Milde - 2021-04-23

    Fixed in 0.17.1. Thank you for the report.

     

Log in to post a comment.