Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

gloss-english.ldf (line 132) Use of \__prop_put_linked:wnnN doesn't match its definition. #626

Closed
vipowueb opened this issue Feb 15, 2024 · 14 comments
Milestone

Comments

@vipowueb
Copy link

vipowueb commented Feb 15, 2024

I just updated via the "TeX Live Utility" app to the version:

revision: 69093
sizes: src: 1049k, doc: 1037k, run: 1601k
relocatable: No
cat-version: 1.66

The minimal example

\documentclass{article}

\usepackage[protrusion=true]{microtype}
\usepackage{polyglossia}
\setmainlanguage[variant=british]{English}

\begin{document}
	Hello World!
\end{document}

generates a PDF containing the lines:

variantvariantukbritish
Hello World!

My typesetter lists the following issues:

gloss-english.ldf (line 132)
Use of __prop_put_linked:wnnN doesn't match its definition. (...as@values{english}{variant}{us}{american} ...)

gloss-english.ldf (line 132)
LaTeX Error: Missing \begin{document}. (...as@values{english}{variant}{us}{american} ...)

and the log file

(/usr/local/texlive/2023/texmf-dist/tex/latex/polyglossia/gloss-latex.lde
Package: gloss-latex 2023/12/11 v1.66 polyglossia: module for default language
)
Package polyglossia Info: Default language is latex.
) (/usr/local/texlive/2023/texmf-dist/tex/latex/polyglossia/gloss-english.ldf
File: gloss-english.ldf polyglossia: module for English
Package polyglossia Info: Option: English, variant=american.

/usr/local/texlive/2023/texmf-dist/tex/latex/polyglossia/gloss-english.ldf:132: Use of __prop_put_linked:wnnN doesn't match its definition.
...alias@keyvals@english@american

l.132 ...as@values{english}{variant}{us}{american}

If you say, e.g., \def\a1{...}', then you must always put 1' after `\a', since control sequence names are
made up of letters only. The macro here has not been
followed by the required stuff, so I'm ignoring it.

/usr/local/texlive/2023/texmf-dist/tex/latex/polyglossia/gloss-english.ldf:132: LaTeX Error: Missing \begin{document}.

See the LaTeX manual or LaTeX Companion for explanation.
Type H for immediate help.
...

l.132 ...as@values{english}{variant}{us}{american}

You're in trouble here. Try typing to proceed.
If that doesn't work, type X to quit.

)
Package polyglossia Info: Option: english variant=british.
Package polyglossia Info: Option: english variant=british.
Package polyglossia Info: Default language is english.
Package polyglossia Info: Option: english variant=british.

Within a bigger document, the same line as above is generated, followed by a blank page and the actual content thereafter.

Thanks in advance.

@LPR121
Copy link

LPR121 commented Feb 16, 2024

I face the same issue since I updated TexLive yesterday from 2022 to 2023.

\documentclass{article}
\usepackage{polyglossia}
\setmainlanguage[variant=german,spelling=new,babelshorthands=true]{german}

\begin{document}
    Test
\end{document}

Results in:
[{
"resource": "/c:/texlive/2023/texmf-dist/tex/latex/polyglossia/gloss-german.ldf",
"owner": "LaTeX",
"severity": 8,
"message": "Use of \__prop_put_linked:wnnN doesn't match its definition.\n \xpg@alias@keyvals@german@1996 \n",
"source": "LaTeX",
"startLineNumber": 165,
"startColumn": 1,
"endLineNumber": 165,
"endColumn": 65536
}]

From gloss-german.ldf where the error links to:

% Register default options
\xpg@initialize@gloss@options{german}{variant=german,spelling=new,script=latin,babelshorthands=false}
% Register alias options
\xpg@set@alias@values{german}{spelling}{new}{1996}
\xpg@set@alias@values{german}{spelling}{old}{1901}
\xpg@set@alias@values{german}{script}{blackletter}{fraktur}

@jspitz
Copy link
Collaborator

jspitz commented Feb 16, 2024

Thanks, this is fixed for the next version.

@jspitz jspitz added the FIXED IN DEV This bug is fixed for the next release label Feb 16, 2024
@jspitz jspitz added this to the 2.0 milestone Feb 16, 2024
@jspitz
Copy link
Collaborator

jspitz commented Feb 16, 2024

Workaround:

\documentclass{article}

\usepackage{polyglossia}

% work around a bug in polyglossia
\makeatletter
\ExplSyntaxOn
\pretocmd\xpg@set@alias@values{%
	\prop_if_exist:cF { xpg@alias@keyvals@#1@#4 }
	{ \prop_new:c {xpg@alias@keyvals@#1@#4} }
}{}{}
\ExplSyntaxOff
\makeatother
% end of workaround

\setmainlanguage[variant=british]{english}

\begin{document}
	Hello World!
\end{document}

Witiko added a commit to Witiko/markdown that referenced this issue Feb 16, 2024
See <reutenauer/polyglossia#626 (comment)>.

Co-authored-by: Juergen Spitzmueller <spitz@lyx.org>
@vipowueb
Copy link
Author

Works, thanks!

@LPR121
Copy link

LPR121 commented Feb 16, 2024

Thanks!

@jspitz jspitz reopened this Feb 16, 2024
@jspitz
Copy link
Collaborator

jspitz commented Feb 16, 2024

Please keep open until the fix is released.

@jspitz
Copy link
Collaborator

jspitz commented Feb 17, 2024

The reason is a latex3 kernel change that seemed to have affected several packages who didn't check whether a property list is defined before attempting to write to it. See
latex3/latex3#1458

I suppose we need to make a soonish release as this hits users hard.

@davidcarlisle
Copy link

@jspitz sorry about the lack of notice. The check that prop variables are declared was always intended to be there (and all expl3 variables are documented as needing to be declared with \New.. ) but the check was missed in the code, a refactorisation caused the check to get enabled, but as we hadn't noticed the check was previously missing we didn't search contributed packages for affected use. If you could release before the texlive 2024 code freeze (2nd March) that would be really helpful, if you can't we could look at pushing out a first-aid, but if you could update that would be best

@jspitz
Copy link
Collaborator

jspitz commented Feb 17, 2024

@davidcarlisle no problem, after all, it was our own oversight. I am about to release now. The only concern I have is that we are in the midst of a major code rewrite and I would have loved to have that settled a bit more. But all checks pass, so I am rather confident.

@reutenauer
Copy link
Owner

reutenauer commented Feb 17, 2024 via email

@jspitz jspitz removed the FIXED IN DEV This bug is fixed for the next release label Feb 17, 2024
@jspitz jspitz closed this as completed Feb 17, 2024
@jspitz
Copy link
Collaborator

jspitz commented Feb 17, 2024

Version 2.0 (sic!) has been uploaded to CTAN now. This might give us the opportunity to iron out remaining glitches or regressions of the code rewrite before the TL freeze.

@reutenauer
Copy link
Owner

reutenauer commented Feb 17, 2024 via email

@Udi-Fogiel
Copy link
Collaborator

@davidcarlisle would testing against latex-dev catch such problems in advance?

@davidcarlisle
Copy link

@Udi-Fogiel well it can't hurt: we encourage package developers to test against latex-dev as much as they can to avoid surprises all round. Of course we can't catch everything, in particuar I'm not sure if this would have been caught by the previous dev release (and don't want to try to build such a system to check) As I commented above this change wasn't exactly planned (as the documented behavior didn't change, just the old code didn't have the checks documented) so it's always possible that some problems only arise when everything is really put together for a release from the main branch, but in general testing latex-dev should give some months or weeks advance warning of any planned changes.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants