Introductry Outlines Creating Error

Hi Folks,
When I check the following, PTXprint is creating following error (below screenshots):
PT Project has following markers with text:

In PTXprint check option:

image

PTXprint [2.3.30] - Error!
Failed to create: SKR_skr-5x7-2Col_MAT_ptxp.pdf
! .
\gettop@param #1->\edef \p@ramcheck
{#1}\ifx \p@ramcheck \empty \else \trace…
\getp@ram …ramfalse \fi \else \gettop@param {#1}
\fi \global \let \p@@r@m =…
\endlastp@rstyle …aceafter}{\m@rker }{\styst@k }
\global \let \spaceafterp@…
@p@rstyle #1->\endlastp@rstyle {#1}
\ifn@npublishable \else \mcpushunderms {…
@@p@rstyle …e }\else \let \n@xt @p@rstyle \fi
\fi \fi \x@ \n@xt \x@ {\ne…
\t@mp ->متّی\mt1
متّی

l.7 \mt2 د
ی راہِیں اِنجِیل

This might be related to a USFM marker error (using an unsupported marker).
Try running ‘Basic Checks’ in Paratext to validate markers.

PTXprint Version 2.3.30

Sadly, that snippet from the log (the bit with all the \ifx...\fi and so on in it) is too short to be very useful. (I think the python code just counts a certain number of lines, which in this case isn’t enough.) Nor can I recreate the bug with a test project here. Could you go to the ‘Help’ tab, create an archive, and submit it to ptxprint_support@sil.org please?

Thanks, I have sent an email with the archive.

OK, I’ve had a look at the archive. The error comes into the class of “Something very odd is happening”
The error was because TeX was trying to turn the text متّی\mt1 متّی into part of the running header line (\h).
\h is a special line which, because of how it is used in PTXprint, must occur on a line on its own, with no other USFM markers following it. The final USFM has a line:

\h متّی\mt1 متّی
Which is the cause.

Your input SFM file does not seem to contain this line, but it’s there’s one by the time the file gets to TeX. So I guessed that it is the changes file, and sure enough, turning off the changes file fixes the problem.

Digging deeper, I find this line, in changes.txt

"(\\toc3 (.+?)\s+)" > "\1\\h \2"

That line puts \h on the same line with whatever follows it.
The following is a version which will not cause crashes:

"(\\toc3 (.+?)\s+)" > "\1\\h \2\n"

The \n at the end, adding a new line.

Thanks David. It is working now.