« first day (4916 days earlier)      last day (14 days later) » 

cis
12:09 AM
@English language

You don't have a word for "Haudegen"; literally: "hit epee".

This is translated as "warhorse", which in German is referred to as "Schlachtroß" (not exactly the same).

I wanted to title @DavidCarlisle and @egreg as “zwei Haudegen”. :)
 
cis
12:29 AM
....
........
...................


PS: The meaning of the German word "Haudegen" is "a daring guy who has a certain amount of experience"...
 
12:58 AM
@cis 'daredevil'? Although that usually has much more of a risk-taking meaning. I assume Haudegen derives from the Mensur culture? It's not that surprising that we don't have an equivalent word in English, as there is no equivalent source.
@cis Yes, 'warhorse' usually has a bit of an 'old and tired' meaning.
 
cis
@AlanMunn
I would translate "Daredevil" as "Draufgänger", that is someone who is not afraid of taking risks.
And “to be dardevil” as “wagemutig”, someone who dares a lot and is courageous.

But in German, “Haudegen” also emphasizes the experience aspect.
 
@cis Yes I figured that. I can't think of any equivalent word that captures that combination of meanings.
 
1:13 AM
@AlanMunn -- Quite by chance, I just listened on the radio to a CBC program on Wilhelm von Humboldt (brother of Alexander). The last part of the documentary briefly covered his linguistic exploits -- impressive! I think you'd be interested: cbc.ca/radio/ideas/humboldt-education-system-bildung-1.7172093 It's part 1 of 2, so I'm looking forward to the continuation. (Their pronunciation of "Bildung" is atrocious.)
 
@barbarabeeton Yeah, he was an interesting guy for sure. Thanks for the link. I used to listen to Ideas a lot when in Canada.
 
@AlanMunn -- It's dependably broadcast on the Rhode Island NPR station. Always interesting, makes one think.
 
@barbarabeeton That's nice. Although now with most programs also podcast, it's probably easy for anyone to listen to.
 
@AlanMunn -- One of these days, I'll have to figure out how to deal with podcasts. (I'm irretrievably bound to ink on paper.)
 
@barbarabeeton Do you have a smart phone? If so, that's the easiest way to listen to them.
 
1:25 AM
@PauloCereda -- That's definitely a pampered capybara!
 
cis
In times past, the German translator's idea was to translate everything 100%.

You could hear it clearly in old films:
One sentence: "Yes, I am keen on reading the documents." was translated as: "Ja, ich bin *scharf darauf*, die Dokumente zu lesen."

Translated back that would be: "Yes, I am horny / cute to read the documents." ... :)
 
@AlanMunn -- I do have a smart phone, but we have an adversarial relationship. Among other things, I haven't learned how to control the volume -- it's always just on the edge of inaudible.
 
@barbarabeeton Sorry to hear that it's out to get you. :) Or maybe it's just trying to preserve your hearing.
@cis So basically they were using Google Translate? :)
 
 
7 hours later…
8:40 AM
@samcarter ooh
 
9:11 AM
@cis you could as well translate "scharf drauf" as "eager" or "keen". It doesn't have to have the sexual connotation as "horny" in German, that is very context dependent.
@AlanMunn I'd argue it's a good translation for relatively modern German (depending on the time one could as well translate "keen" as "begierig", but "begierig" is not as frequently used in colloquial spoken German, I'd argue). My football (the real one, not handegg) coach often said "scharf drauf zu gewinnen" and I doubt he was "horny to win".
 
9:54 AM
@cis clearly the translation is context sensitive. For @egreg, translate it as "old man" and for me, translate as "experienced master practitioner"
4
 
10:11 AM
@cis to add a bit to above's statement: "scharf drauf" usually means "eager/keen", while only "scharf" can mean "horny" or "hot/cute" or "hot/spicy". All very context sensitive: "Ich bin scharf drauf, zu spielen" == "I'm eager to play". "Die Blonde ist scharf" == "The blonde is hot/cute" (but mostly in the "hot" not "cute" range). "Ich bin scharf" == "I'm horny/hot" (depending on overall context and intonation). "Das Essen ist scharf" == "The food is hot/spicy".
Not sure why you get the general impression that "scharf drauf" means "horny"...
 
Small bug in newtxmath:
\ifntx@amsthm % set via package option
\RequirePackage{amsthm}
\typeout{amsthm loaded}
\else
\typeout{amsthm NOT loaded}
\fi
perhaps it should also check if amsthm is already loaded before writing to the log that amsthm is not loaded.
 
cis
10:37 AM
@Skillmon I heard the word "Haudegen" last time in the German translation of Picard - Season 3, when Captain Shaw titled Riker and Picard as "zwei Haudegen", I wonder which was the original word...
 
@daleif Oh, no, Børsen. :(
 
11:04 AM
Fun talk at Mainz
@egreg You going to answer tex.stackexchange.com/questions/715688/…?
 
@mickep I know, really bad.
 
@mickep oh, fire:(
 
@DavidCarlisle kinda like the church in Paris, this one is filled with priceless art.
and is 400 years old
while the top started to burn civilians where moving paintings out of the building
 
11:34 AM
shouldn't the showfarme package have a manual? Or at least something relevant that shows up under textdoc.
 
@daleif Seems to be lacking any
 
@daleif it's not that old (2020) so you may still find the author willing to add one
 
@JosephWright I did. You answered when I was on the bus. ;-)
 
@egreg :)
@egreg Back from the tram, still at Frank's for a couple of hours
 
12:01 PM
@JosephWright did you guys have an in person team meeting?
 
@Skillmon Frank, @UlrichDiez and I met up yesterday/today - I was invited to Mainz to talk (about LaTeX but for chemists)
 
@JosephWright ahh. I hope you guys have/had a great time :)
 
@daleif Very sad to see the pictures! The other week at the Dante meeting, we had a tour of some of the behind the scenes facilities (e.g. their workshop for digitising books) of en.wikipedia.org/wiki/Duchess_Anna_Amalia_Library . They also lost so many irreplaceable artefacts to fire :(
 
@Skillmon Been productive I think
 
cis
@DavidCarlisle I don't understand this.
This works neither with "% old latex --- 1" nor wth "% old latex --- 2":
\documentclass[landscape]{article}
\usepackage[margin=5mm]{geometry}

\ExplSyntaxOn
 \cs_generate_variant:Nn  \cs_set:Npn {Npe} % old latex --- 1
%\cs_generate_variant:Nn  \clist_set:Nn {Ne} % old latex ---  2

\cs_new:Npn \cis_comma_tmp:n #1 {#1,}
\cs_new:Npn \cis_comma_tmpb:n #1 {\seq_item:Nn \l_tmpa_seq {#1} , }


\NewDocumentCommand\createlist{mmm}{
  \clist_set:Ne \l_tmpa_clist {
    \int_step_function:nN {#2} \cis_comma_tmp:n
  }

  \seq_set_from_clist:NN \l_tmpa_seq \l_tmpa_clist
  \seq_shuffle:N \l_tmpa_seq
 
12:15 PM
@cis use \cs_set:Npx on old LaTeX installations.
 
@DavidCarlisle oh no, alltt...
 
cis
I tested the following 5 versions "% old latex --- 1,2,3,4,5"
at mine and at 'overleaf' but this gives:

`! Undefined control sequence.
\createlist code #1#2#3->\clist_set: ..... `
\documentclass[landscape]{article}
\usepackage[margin=5mm]{geometry}

\ExplSyntaxOn
 \cs_generate_variant:Nn  \cs_set:Npn {Npe} % old latex --- 1
%\cs_generate_variant:Nn  \clist_set:Nn {Ne} % old latex ---  2
%\cs_generate_variant:Nn \cs_set:Npx  % old latex ---  3
%\cs_generate_variant:Nn  \cs_set:Npx {Ne} % old latex ---  4
%\cs_generate_variant:Nn  \clist_set:Npx {Ne} % old latex ---  5

\cs_new:Npn \cis_comma_tmp:n #1 {#1,}
\cs_new:Npn \cis_comma_tmpb:n #1 {\seq_item:Nn \l_tmpa_seq {#1} , }
 
12:50 PM
@cis you can't use \cs_generate_variant:Nn on a function containing a p argument. Also your error message isn't complete. What I meant was, for old LaTeX versions don't use \cs_set:Npe but instead \cs_set:Npx. So just change the \cs_set:Npe in your \createlist to a \cs_set:Npx.
 
cis
Ok, I changed

\cs_set:Npx#1 { % changed \cs_set:Npe to \cs_set:Npx <------- !

But I get:


Namenlos-1.tex
27
Undefined control sequence.
\createlist code #1#2#3->\clist_set:Ne
\l_tmpa_clist {\int_step_function:nN ...
l.27 \createlist\aaa{52}{12}



And the error is not complete, but the file Namenlos-1.log is empty.... :(
\documentclass[landscape]{article}
\usepackage[margin=5mm]{geometry}

\ExplSyntaxOn
\cs_generate_variant:Nn  \cs_set:Npn {Npe} % old latex

\cs_new:Npn \cis_comma_tmp:n #1 {#1,}
\cs_new:Npn \cis_comma_tmpb:n #1 {\seq_item:Nn \l_tmpa_seq {#1} , }


\NewDocumentCommand\createlist{mmm}{
  \clist_set:Ne \l_tmpa_clist {
    \int_step_function:nN {#2} \cis_comma_tmp:n
  }

  \seq_set_from_clist:NN \l_tmpa_seq \l_tmpa_clist
  \seq_shuffle:N \l_tmpa_seq
  \cs_set:Npx#1 { % changed  \cs_set:Npe     to   \cs_set:Npx <------- !
 
@cis use \clist_set:Nx... Also, is there any reason why you use \int_step_function:nN {#3-1} \cis_comma_tmpb:n \seq_item:Nn \l_tmpa_seq {#3} instead of \seq_use:Nn \l_tmpa_seq { , }?
 
cis
1:06 PM
@Skillmon

1st) With that change (`\clist_set:Nx`) it seems to work - very good!

2nd) To the other `critics` I can't say anything, because it is the code from
@DavidCarlisle ---> https://tex.stackexchange.com/a/715638/46023
 
@DavidCarlisle I'm disappointed from an experienced master practitioner :)
Actually, it does make a bit of sense, since you're pulling only a subset from your sequence (#3 is <= #2, which is the length of the sequence). One could change this to popping the sequence a few times, but I'm not entirely sure which is the faster alternative, tbh.
 
@cis If you add the extra generate line as suggested it works, I tested on overleaf back as far as texlive 2021, I added that line to the answer tex.stackexchange.com/a/715638/1090
@Skillmon it was getting late and initially I thought I might do more than just add commas:-)
@cis it will work with Ne as suggested or Nx (I put an Ne declaration in the answer
@Skillmon by "make a bit of sense" you mesn "David's code works and my suggestion wouldn't" ?
 
@DavidCarlisle Oh, I didn't know that one can \cs_generate_variant:Nn with p args.
@DavidCarlisle well, David's code is in a sense weird, I would've wrote it differently. But I didn't really look at the question, only at the code in this chat.
 
@Skillmon yes I got as far as make initial list and shiffle, then needed to pull out the leading m items with comma separation and no trailing comma, and I sort of brute forced that as i don't think there is a really good pre-packaged function for that and it was too late to consider alternatives so posted it once it worked:-)
 
cis
@DavidCarlisle I am sorry, this "expl3" is to high for me, but with your latest edit at https://tex.stackexchange.com/a/715638/46023 it seems to work.


By the way:
Is it possible to put in 'spaces' after the commas, like 37, 1, 42, 14, ...
---> without getting ruined if I make an array from a list, say `\def\myarray{{\mylist}}`

Because some longer list, like \createlist{mylist}{60}{60}, gives me "overfull hboxes".
 
1:20 PM
@cis I added exactly the line I suggested in the comment earlier;-) yes just use ,~ whever it currently uses ,
@cis in expl3 code a ~ is a normal space, not a no-break space like it is in documents
 
@JosephWright I wish you and Frank a great time. To prevent misunderstandings: I never met anyone of you in person. I am not involved at all into this Mainz-thingie. ;-)
 
@UlrichDiez now I'm confused. Who should I believe? :P
 
cis
1:44 PM
@DavidCarlisle OK, I added '~' to the following and it seems to work, also by putting a list into an array.
\cs_new:Npn \cis_comma_tmp:n #1 {#1,~}
\cs_new:Npn \cis_comma_tmpb:n #1 {\seq_item:Nn \l_tmpa_seq {#1} ,~ }
 
@Skillmon clearly all Germans starting Ulri look alike
 
@Skillmon Right before JosephWright mentioned this, I myself asked a question and deleted it as right after clicking the "send" button I saw the answer. [My question was about whether \include/\includeonly writing checkpoints with counter-values to \@mainaux instead of \@partaux would make a difference. (I guess it would not as all .aux-files are read in any case.) ] So, maybe, me deleting my question caused things to be mixed up.
 
@UlrichDiez so it is as always the correct approach to just blame @UlrikeFischer
 
@UlrichDiez I don't think it can ork to write them to mainaux
 
@Skillmon Blaming people whose names have a trailing "Ulri" is never a good approach. Unless in situations where they deserve it. ;-)
 
1:59 PM
@DavidCarlisle I guess it could, but would require quite some processing overhead and additional data in each written label...
 
@Skillmon What do I overlook? The \cp@...-macros are defined from the written checkpoints at the begin of the LaTeX-run when all .aux-files are read. As all .aux-files are read, it should probably not matter whether data for checkpoints comes from the main aux file or from an \include's .aux-file. Cross-referencing-data and the like, however, needs to go to the include-file's .aux-file as that won't be written to .aux-files anew when the include-file is not in the \includeonly-list.
 
@DavidCarlisle how can that be? I have nice ducks on my avatar!
 
@UlrichDiez I misread your question, it seems, and thought you wanted to get rid of all include-files' .aux-files.
 
2:18 PM
@Skillmon No. ;-) I think about writing a thingie myself, where checkpoints for saving/restoring counter-values need to be written to aux-file. Something along \include-/\includeonly but for code-snippets within the main .tex-file. And when looking at the code for \include/\includeonly I wondered why with \include/\includeonly checkpoints are written to \@partaux instead \@mainaux. Maybe I miss some detail, but it looks to me as if that wouldn't make a difference. That's all. ;-)
 
@Skillmon well anything can be made to work somehow, but if you re-run and don't inlcude that section the main aux will get re-written so the information will be lost unless you save it
@UlrichDiez \@mainaux will be re-written each time including times when a part is not included, so having the checkpoints in partaux is an easy way to preserve that information
 
2:30 PM
@DavidCarlisle I think I got the point now: The command for writing the checkpoint is issued by \@include in any case. So the result would be the same no matter if writing to \@mainaux or \@partaux. However, in case the include-file is not in the \includeonly-list, the include-file's aux-file is not open for writing at the moment when the command for writing the checkpoint is issued by \@include. So this way the computer can be saved from a bit of writing-work.
 
 
1 hour later…
3:52 PM
@DavidCarlisle Oh, tagged math. :)
 
@mickep where is that from?
 
@DavidCarlisle Screenshot from ngpdf.
 
@mickep yes I guessed that. I meant where was the pdf from
ngpdf understands mathml or tex Associated files on /Formula (you can toggle mathjax support for tex AF in the menu)
 
@DavidCarlisle From ConTeXt. The math is converted into text.
(There is also a mathml blob)
 
@mickep latex is so much better:-)
 
4:04 PM
@DavidCarlisle Ohhh
 
@mickep there are some open issues about how you can have multiple fallbacks and whether using ActualText or Alt Text plain text on the formula should or should not suppress the use of the mathml AF (we went through some itterations before getting something that worked in ngpdf and foxit/nvda reader)
 
(Reading the iso docs makes me a worse person...)
 
is the plain text added via actualtext ?
 
@DavidCarlisle Something like that. But also adding the mathml blob.
 
@mickep yes but actualtext wins if you add that everything else is ignored. It's a feature.
 
4:11 PM
@DavidCarlisle After iso doc reading and trial and error, it seems the ua2 is not so far away from ua1. But their structure seem to differ a bit from the one Hans has. Probably do as little as possible to have something useful...
@DavidCarlisle I think adding the mathml blob is now optional, but do you suggest not to add it?
 
@mickep it would be nice to be able able to add mathml, tex and plain text in the pdf, and then let the pdf receiving software use whichever it can use, but (despite multiple requests for clarification that doesn't seem possible currently) you get better readings (possibly) if you add mathml but then you need to add the plain text via Alt or another AF not via actualtext. If you use ActualText there isn't much point adding anything else as that masks everything.
@mickep Unless I got that wrong andd @UlrikeFischer corrects me.
@mickep for reading then given a good enough plain text string you can obviously get a good reading, but as you show it makes for a horrible html derivation.
 
On DANTE meeting, I learned that \cite{Grüße} works for pdflatex. I communicated, but users said: Well, works. But what about \cite{任政2018} ? That causes an error: ! Undefined control sequence. -- Source: github.com/JabRef/jabref/issues/9605#issuecomment-2059444520
 
@DavidCarlisle I think the aim here is to add formulas in text, since the readers do not really seem to handle mathml well (and how should they know the meaning?)
@DavidCarlisle What is horrible? :)
 
@koppor non ascii labels aren't really supported but they do work sometimes.
@koppor works for me:
\documentclass{article}

\DeclareUnicodeCharacter{4EFB}{CJK Ideograph 4efb}
\DeclareUnicodeCharacter{653F}{CJK Ideograph 653f}

\begin{document}

\cite{任政2018}

\begin{thebibliography}{99}
\bibitem{任政2018} xxxx
\end{thebibliography}
\end{document}
@mickep currently the only reader that understands mathml is foxit+nvda+mathcat but mathcat is being added to nvda and jaws as far as I understand so things will get better. But common sense dictates you should be able to add both and let the receiving software choose but that isn't the way it's specifed
 
4:29 PM
@DavidCarlisle OK, foxit is not for linux, right? In any case, I agree with you that one should be able to add both.
 
@DavidCarlisle /ActualText "hides" by design, so it should imho not be used for real math. /Alt currently hides the mathml too and so we are leaving it out if we add mathml, but if that is correct is imho still open. @mickep
 
@koppor actually that just removes the error but the cite does not resolve This works fully, maybe we should adjust something....
\documentclass{article}

\DeclareUnicodeCharacter{4EFB}{CJK Ideograph 4efb}
\DeclareUnicodeCharacter{653F}{CJK Ideograph 653f}

\begin{document}

\cite{\noexpand任政2018}

\begin{thebibliography}{99}
\bibitem{任政2018} xxxx
\end{thebibliography}
\end{document}
@JosephWright ^
@mickep well even for windows the one that works needs an unadvertised development download build plus an unadvertised development build of nvda, so it's not exactly mainstream (and one reason mathml AF have quite a high profile in our examples, so people can complain they don't work with their current readers)
 
@DavidCarlisle does cite expand its key?
 
@koppor actually you don't need the definitions
\documentclass{article}

\begin{document}

\cite{\noexpand任政2018}

\begin{thebibliography}{99}
\bibitem{任政2018} xxxx
\end{thebibliography}
\end{document}
@UlrikeFischer just the first token of it I didn't trace, but \expandafter or \romannumeral somewhere, it's only a problem if the CJK character is at the start
 
In case anyone is looking for an advanced git course - tomorrow afternoon: indico.cern.ch/event/1334738/contributions/5814285
2
 
4:38 PM
@DavidCarlisle yes just saw it. I should have tested with Ärger or Übel instead of grüße ;-)
 
5:20 PM
@UlrikeFischer Oh, indeed. What is intended use is not really easy to get from the iso docs.
@DavidCarlisle Ah, but good that they get some testing. And that you get something to test on.
 
5:34 PM
@UlrikeFischer vv
\long\def\@for#1:=#2\do#3{%
  \expandafter\def\expandafter\@fortmp\expandafter{#2}%
 
@DavidCarlisle ?
 
@UlrikeFischer \@for expands the list once so you can do \@for \xxx:=\mylist but in \@cite it is passed the argument directly so it expands the first token
@UlrikeFischer that's better than it used to be, it used to edef the whole argument
% \changes{v1.0d}{1995/04/24}
%      {Don't expand second argument with \cs{edef}: /1317 (DPC)}
 
@DavidCarlisle ah the cite question ;-)
 
@UlrikeFischer yes, sorry
 
@DavidCarlisle do we dare to add a \noexpand to cite?
 
5:50 PM
@UlrikeFischer possibly, we can always blame you and reference chat.stackexchange.com/transcript/message/65511859#65511859
 
@DavidCarlisle natbib looks ok, it does \@for\@citeb:=\NAT@cite@list\do.
 
@UlrikeFischer would be enough to add a space I think
 
@DavidCarlisle the question is if anyone relies on the expansion.
 
6:24 PM
@UlrikeFischer \cite{\blub} it could be fancier and just not expand an inputenc character
 
6:35 PM
@DavidCarlisle but in view that it wouldn't work with natbib ... in other news: you saw that all examples should be corrected as they changed the uri of the declaration?
 
@UlrikeFischer :(
@DavidCarlisle Would be preferable now ...
 
@JosephWright well yes true actually (if you don't worry about latin1 input)
@UlrikeFischer no when?
 
@DavidCarlisle OK, \protected@edef
 
@UlrikeFischer oh just seen
 
@samcarter tex.stackexchange.com/questions/129439/latex3-sensitive-editors/… that was the reason why I had expl3-code before and after \ExplSyntaxOn in my example :)
 
6:51 PM
@UlrikeFischer you update pdfresources then I regenerate them all?
 
@Skillmon I was wondering about this: l3 syntax highlighting without \ExplSyntaxOn might be useful for packages. Are there any other places where one would meet l3 "in the wild"?
 
@samcarter no, in packages and the like there is \ProvidesExpl(Package|Class|File) which also switches it on. The reasoning was more that it will (at least attempt to) show when you're using L3 outside of scope.
 
@DavidCarlisle I already updated in develop, just checking the testfiles
 
@UlrikeFischer ah OK let me pull....
 
@Skillmon Oh, knowing when one is outside is probably also helpful!
 
6:56 PM
@samcarter Taking a look now
 
@UlrikeFischer looking at the page at pdfa, as we have checked pdf/ua-2 with verapdf shouldn't we use pdfa.org/declarations#pdfua2-validated ?
 
How can I check whether a command is used as argument of another? It would be sufficient to test whether the argument starts with this command (ignoring spaces).
I thought, that it should work with setting one tl to \tl_head:n {#1} and the other to the macro I am checking for, then comparing both meanings (like \ifx), but somehow this does not work
 
@JasperHabicht use \tracingmacros=1 and search the log for it in a parameter (#\d<-\\<csname> should find it)
 
7:13 PM
@Skillmon I got it now, I can use my approach and just compare with tl_if_eq_NN I think ...
 
@JasperHabicht oh, you mean from within TeX... \tl_if_head_eq_meaning:nNTF should do. If you also need the macro name to match then \tl_head:n should indeed do: \tl_if_eq:enTF { \tl_head:n {#1} } { \mymacro }
 
@Skillmon Well would also allow { \mymacro } - depends how defensive you need to be
 
@JosephWright if that's an issue \tl_if_eq:enTF { \tl_if_head_is_N_type:nT {#1} { \tl_head:w #1 \q_stop } } { \mymacro } (assumes \q_stop is never part of #1 -- else use \tl_head:n {#1} instead of \tl_head:w #1 \q_stop)
 
@Skillmon Yup
@Skillmon I'm sure you realise why I say this - I tend to have to worry about weird edge cases
 
@UlrikeFischer done and I checked a couple: URL changed as expected, upload full set?
 
7:18 PM
@JosephWright no, you're absolutely right. Should've thought of this limitation of \tl_head:n.
 
@Skillmon en ... makes sense. Let me mentally process the other things you said =D
 
@JasperHabicht discard the \tl_head:w usage in the other comment. Stick to \tl_head:n or else bad things will happen if the first item of #1 isn't expansion-safe.
 
@samcarter Good slides
 
@Skillmon But why do I need to do the \tl_if_head_is_N_type test exactly?
 
@DavidCarlisle sounds good. We could naturally add the validated declaration, but i don't think that we can do that automatically.
 
7:21 PM
@JasperHabicht To deal with the case where the argument contains { \mymacro } or [space] \mymacro rather than just \mymacro
 
@UlrikeFischer true you'd need to have a key at top level and we'd add it to the fiels, although it's just more bytes making every pdf bigger:-)
 
@JasperHabicht because \tl_head:n expands to the first item, meaning it might strip braces, which you don't want if you want to know whether it starts with your explicit token.
 
@JasperHabicht \tl_head:n is fast-but-simple minded, so takes the first balanaced text
 
@JosephWright correction: After I touched it, \tl_head:n is fast but simple minded, previously it was ingenious but not necessarily fast.
 
@JosephWright I see
 
7:23 PM
@Skillmon I was thinking of compared to an approach which also tests for N-type, etc.
 
@JosephWright I know :P Just wanted to brag
 
@Skillmon :)
 
@JosephWright The only downside of the slides is that there is a ppt version, too :P
2
 
@samcarter I'd seen that too
@samcarter The funny thing is, I read it and thought 'well yes, this is all core Git - where's the advanced stuff ;)'
@samcarter Also, uses master not main ...
 
@JosephWright I do the same...
 
7:37 PM
@Skillmon Yeah, but if you make a new repo with up-to-date Git you get main as standard
 
@JosephWright my git is up-to-date, I make a new repo, I get master.
 
@JosephWright It seems to be a mixture. main is used on some slides, too.
 
@Skillmon I think for my use case it is okay not to take into account to many edge cases. In the end, I only want to output an error that is meant to help the user understand what is going wrong. So, the thing will break anyways ...
 
@JasperHabicht well, error detection should be fast (run on every call/item, so bad), but error cleanup not so much (should happen only once in a lifetime of a document). So depending on in which branch this is, the overhead would hurt or not.
 
@Skillmon Right. I will think about this again ... after having fully understood things =)
I do understand that \tl_head:n only grabs the first item (which might be a group and then the test would not work), but the N_type test would not prevent this, would it?
It tests, whether the first token is not a space and not a begin group.
 
7:45 PM
@JasperHabicht it would, in case of the N-type test your comparison would be empty to some macro, so false.
It really depends what you try to detect.
 
@Skillmon Ah! Okay ... yeah ... Well, I want to throw an error if the macro is used as argument
 
@JasperHabicht anywhere in the argument? I'd suggest stringifying and searching for its string representation. Not fool proof either, but apart from edge cases should detect things at any spot and be fast.
 
I think I understand now better. I'll work through this ... Yes, I also thought about stringification ...
I just have to think it over again.
 
@JasperHabicht \str_if_in:nnTF {#1} { \mymacro }
 
7:52 PM
(you could also run a slower test if that's true to make sure, in the worst case something like \regex_match:nnTF { \c{mymacro} } {#1}.
 
@Skillmon Right ... No, I'll stick to this solution now =) Thanks!
 
8:03 PM
@JasperHabicht my proudest error message is for undefined sets in expkv, it works via the way an internal macro for the sets is built, printing a meaningful error message to the terminal because it'll be implicitly set to \relax and then used in another \csname, making it at 0 cost overhead:
! Missing \endcsname inserted.
<to be read again>
                   \! expkv Error: Set `myset' undefined.
(though it'll not be cleaned up, so more errors are guaranteed to follow if one continues)
 
@Skillmon Nice!
The trickiest part is to think of errors users could make =D
 
@JasperHabicht never trust the user! :D
 
@Skillmon I am also not sure what would happen if you throw arbitraty code into jsonparse, but somewhere it will complain because things are not a string and not a number I guess ... =D
Unknown fp word ... ... Hm. So, I should probably rework this test as well ...
 
@JasperHabicht well, kv parsing is simpler. You might get weird errors if you define something gobbling more arguments than I like, but there's no helping that.
 
I simply used \fp_compare:nNnTF { <value> } ? { 0 } to check for nan, but it is probably not very bullet-proof
@Skillmon No. My take is, it's job is to parse JSON. So, don't expect much for other input.
 
8:14 PM
@JasperHabicht but do you verify only the JSON structure or also user provided commands in your getter-functions?
 
For a simple foo at least, you get a reasonable error message =D
@Skillmon Hm, no. Currently TeX commands are rudimentarily supported, but you can't put JSON in these. So, you could put a string containing a simple command such as "foo \\emph{bar}". I don't test the input, the parser just tests whether it is an object, an array, a string (a key), true, false, null or a number in this sequence. If everything fails, the error shows
I think it is probably too complicated to verify proper JSON just via TeX. I am also unsure whether this is actually reasonable ... My aim was initially (knowing that there is already a Lua JSON parser) to have a workaround solution that works without Lua for small JSON files. And this, I got now
 

« first day (4916 days earlier)      last day (14 days later) »