1

For background see: this TEX StackExchange question

When using version 3 of the acro package in its version 2 mode (a practical necessity since compilation with native version 3 takes much much longer) the following error is given, although the output is not affected in my case.

! LaTeX Error: Variable \l__acro_foreign_format_prop undefined. 

I know version 2 is loaded because there are no errors related to the options setup using v2 syntax, and because the following also appears in compilation output

==> First Aid for acro.sty no longer applied! Expected: 2022/04/01 v3.8 typeset acronyms and other abbreviations (CN) but found: 2020/03/07 v2.11d Typeset Acronyms so I'm assuming it got fixed. ) (./acronyms.tex) 

What can be done about this? Is it a bug?

Incidentally, I've compared the acro.sty from TeXLive 2020 with the acro2.sty included with the acro package from TeXLive 2024, and they are not the same.

6
  • 2
    Can you give an MWE which reproduces the error? Does it also error with TL 2020? Commented Aug 13, 2024 at 21:56
  • @dai-bowen The MWE is given in the TEX StackExchange post linked at the beginning of the question. With acro from TL 2020, I did not notice the error described in this question because there were no acro package errors that blocked successfull compilation. Commented Aug 13, 2024 at 22:27
  • IIRC, before TeX Live 2024, prop variables used to work sometimes even if the prop variable was not previously declared using \prop_new:N. Of course, in expl3, it has always been documented that variables must be declared before they are used. This issue has been discussed here: github.com/lvjr/tabularray/issues/474 Commented Aug 14, 2024 at 2:33
  • @User23456234 indeed, though I think the issue is a bit different in acro. judging by the list David gave there, the problem there looks systematic, whereas acro clearly intends to declare variables before use. it is just that once you have enough variables, it is easy to miss one if you're not getting warnings/errors in testing. (and acro has a great many variables declared. including property lists.) I assume this is why a variable got lost between v2 and v3, for example. Commented Aug 14, 2024 at 3:47
  • 2
    @cfr firstaid doesn't compare dates but only the string, and if it is different it assumes a newer version. Commented Aug 14, 2024 at 7:54

1 Answer 1

2

It seems to work to just declare the missing property list. This is part of what the first aid does for version 3, but in version 3 it is a different property list which isn't declared properly. (In fact, the property list missing in version 3 is properly declared in version 2, so that bug appears to have been a casualty of the upgrade process.)

Note that I simplified your example a bit, though I did not minimise it properly.

The following compiles without error with both pdfTeX and luaTeX.

\documentclass{article} \usepackage{acro}[=v2] \acsetup{display-foreign = false} \acsetup{foreign-format = {\scshape} } \ExplSyntaxOn \prop_new:N \l__acro_foreign_format_prop \ExplSyntaxOff \DeclareAcronym{RDBMS} { short = RDBMS, short-plural = es, long = Relational Data Base Management System, pdfstring = RDBMS } \DeclareAcronym{SASL} { short = SASL, long = Simple Authentication and Security Layer } \DeclareAcronym{IMAP} { short = IMAP, long = Internet Message Access Protocol } \DeclareAcronym{NIST} { short = NIST, long = National Institute of Standards and Technology, } \begin{document} \pagestyle{empty} \ac{RDBMS} \ac{SASL} \ac{IMAP} \ac{NIST} \printacronyms \end{document} 

acronyms (but the result is not really material here and this image could, in truth, be omitted since the erroneous code produces the same PDF, albeit it such a document is not reliable)

1
  • Thank you for the answer. I will keep in mind, for future posts, your suggestion about making it easier for those viewing a question by providing a single file MWE in the question. Commented Aug 14, 2024 at 3:35

You must log in to answer this question.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.