tectonic-typesetting / tectonic-texlive-bundles

Generate Tectonic bundles from the TeXLive source tree
MIT License
5 stars 3 forks source link

Problems with polyglossia #6

Closed malbarbo closed 2 years ago

malbarbo commented 3 years ago

Using tectonic with the 2020 bundle and the following file

\documentclass[a4paper,12pt]{article}
\usepackage{polyglossia}
\setmainlanguage[variant=brazilian]{portuguese}

\begin{document}
Test
\end{document

generates the following error

(teste.tex
LaTeX2e <2020-02-02> patch level 5
(article.cls
Document Class: article 2019/12/20 v1.4l Standard LaTeX document class
(size12.clo)) (polyglossia.sty (etoolbox.sty) (makecmds.sty) (xkeyval.sty
(xkeyval (xkvutils (keyval)))) (fontspec.sty (xparse.sty (expl3.sty
(expl3-code.tex (l3deprecation.def)) (l3backend-xdvipdfmx.def)))
(fontspec-xetex.sty (fontenc.sty) (fontspec.cfg))) (ifluatex.sty (iftex.sty))
(ifxetex.sty) (l3keys2e.sty) (filehook.sty) (gloss-latex.ldf))
(gloss-portuguese.ldf)

Package polyglossia Warning: No hyphenation patterns were loaded for "Portugues
e (Brazil)"
(polyglossia)                I will use the standard patterns for Portuguese in
stead on input line 3.

! Undefined control sequence.
\adddialect ...####1####2####3####4{}\fi }\bbl@cs 
                                                  {languages}\endgroup 
l.3 ...mainlanguage[variant=brazilian]{portuguese}

According to https://github.com/reutenauer/polyglossia/issues/404, this was fixed in polyglossia 1.49.

malbarbo commented 3 years ago

@pkgw, can you help-me with this issue?

pkgw commented 3 years ago

@malbarbo Sorry, I must have missed the notification when you initially filed this issue. Thanks for pinging, and I'll take a look.

malbarbo commented 3 years ago

@pkgw Thank you.

pkgw commented 3 years ago

Hi @malbarbo — sorry for taking another while to actually get to looking at this.

For the time being, I would recommend the workaround mentioned in the bug report that you linked: adding

\makeatletter
\def\bbl@cs#1{\csname bbl@#1\endcsname}
\makeatother

to your preamble.

The next update to TeXLive should presumably include a newer, fixed version of polyglossia, but there hasn't been any release since TeXLive 2020.0 and I am pretty reluctant to update the bundle to something that isn't an official, tagged release. Especially because the workaround is pretty straightforward in this case.

I would love to be able to update things more aggressively, but with the way that LaTeX/CTAN packaging and the Tectonic bundle system work, it's hard to do so. I'm hoping that my work on a more Cargo-like UX will lay the groundwork for a better system, but it's going to take a while.

Neved4 commented 3 years ago

Hey, @malbarbo hope things are going well ✌🏻 TeX Live 2021 doesn't have this issue anymore and since the update is coming soon (https://github.com/tectonic-typesetting/tectonic-staging/pull/17) your file should compile without having to use workarounds. Please tell us any other problems you find 🚀

@pkgw Can you close this with the new release?

pkgw commented 3 years ago

@mnrvwl I don't always do a good job of reviewing the different issue trackers (as you may have noticed), but I will aim to do so! The update to TeXLive 2021 may take a little while, though, since it is always a somewhat tedious process to port the changes in the TeXLive source into Tectonic — it has to be done manually.

Neved4 commented 3 years ago

Hey @pkgw no worries! Tectonic is an amazing tool and I wanted to return the favor. I'm happy just to have reviewed a few things here and there and that that helped out in closing a bunch of lingering issues ✌🏻

Things pile up sometimes, and sitting down reassessing dozens of things doesn't sound like much fun, but I had some tea with me and it was relaxing.

I'm not using tectonic as a daily driver for everything. When I'm about something complex, latexmk with LuaLaTeX safely takes anything I throw at it so it's my go to. For projects where things are smaller size, where I allow myself to spend extra time testing to make things work with tectonic, oh god it's so fantastic. To have a document that I can bring to any computer, just install tectonic and it compiles correctly? Just rad 🚀

At first there were a few things that many people wanted, like Biblatex/Biber, shell-escape, minted... things that weren't just there. Nowadays there may be gotchas here and there, but many of them have workable solutions, get fixed diligently or are solved once the bundles catch up with latest TeX Live releases.

All that progress makes me both hopeful and hyped. Also excited about the update, but I'll happily take it whenever it comes ⚡️

Neved4 commented 2 years ago

@pkgw I have this working with Tectonic 0.11.0 without issues so importing polyglossia should no longer be a problem.

Neved4 commented 2 years ago

ping @malbarbo

malbarbo commented 2 years ago

It is fixed. Thanks @mnrvwl.

pkgw commented 2 years ago

Great! Thanks @mnrvwl and @malbarbo for confirming.