0 votes

I am working with some Bible Modules to abridge some OT stories. I can create PDFs with regular Bible text, but trying to print out a Bible Module produced a list of errors instead of a PDF.PTXprint-module
Any help troubleshooting these?

PTXprint by (231 points)

11 Answers

0 votes

Hi Brent, thanks for posting this issue. Could you please do a couple of things that might help us resolve it:
a) ensure you’re using the latest (ver 1.5.5) version - as we fixed a major bug just yesterday
b) If that doesn’t change what happens, then please send the Bible Module file to us at ptxprint[underscore][Email Removed] That might help us uncover what is going on.

by (2.6k points)
0 votes

I’m getting a very similar error with a Bible module:
PTXprint Version 1.5.6

Traceback (most recent call last):
File “ptxprint\gtkview.py”, line 651, in onOK
File “ptxprint”, line 137, in doit
File “ptxprint\runjob.py”, line 195, in doit
File “ptxprint\runjob.py”, line 195, in
File “ptxprint\runjob.py”, line 309, in dojob
File “ptxprint\texmodel.py”, line 683, in convertBook
File “ptxprint\texmodel.py”, line 636, in flattenModule
File “ptxprint\usfmutils.py”, line 445, in parse
TypeError: ‘NoneType’ object is not iterable

<class ‘TypeError’>: ‘NoneType’ object is not iterable

by (118 points)
0 votes

Hi Mark,
I’m still having this issue and am wondering if you ever found a fix for it. Thanks!

by (118 points)
0 votes

Hi Dan, Sorry that you are still struggling with this one. I had assumed that no news was good news, but now I know better. Please try this once more with the latest (version 1.5.14.1) and if it is still broken, then use the Create Archive button on the Advanced tab to make a ZIP file which you can send to us at ptxprint[underscore][Email Removed]. This is the easiest way for us to replicate the issue and then solve it for you.

by (2.6k points)

Well, the latest version (1.5.14.3) still not working for me. Here’s the error message:

PTXprint Version 1.5.14.3

Traceback (most recent call last):
File “ptxprint\gtkview.py”, line 703, in onOK
File “ptxprint”, line 145, in doit
File “ptxprint\runjob.py”, line 188, in doit
File “ptxprint\runjob.py”, line 188, in
File “ptxprint\runjob.py”, line 307, in dojob
File “ptxprint\texmodel.py”, line 702, in convertBook
File “ptxprint\texmodel.py”, line 655, in flattenModule
File “ptxprint\usfmutils.py”, line 446, in parse
File “ptxprint\usfmutils.py”, line 511, in parse_element
File “ptxprint\usfmutils.py”, line 466, in parse_element
TypeError: expected string or bytes-like object

<class ‘TypeError’>: expected string or bytes-like object

This is the unchanged Bible module that I emailed to ptxprint_support last month.

0 votes

Thanks for your patience, Brent. I now believe that this has been fixed (in ver 1.5.14.4) so you should be able to produce PDF output from Modules again now. Please let us know how it goes…

by (2.6k points)
0 votes

Still having a problem. Every module I try gets this error:
Canonicalise Text Error! Failed to flatten module text (due to a Syntax Error?): Check for USFM errors and/or problems with a module.

by (231 points)

Strange indeed. Is that just a warning message, or a show-stopper? Does it produce a PDF or nothing at all?
Does it do anything different when you turn OFF the option called “Auto-Correct USFM” (in the “Other” section of the Advanced Tab)?

0 votes

It’s a show stopper. Doesn’t make a PDF.
Tried turning off “Auto-Correct USFM” and same thing happened.

by (231 points)

In the latest version 1.5.15 we have tried to make the error message more helpful. Let us know how it goes…

Could you please also ensure that the Paratext basic checks pass (without errors) for any scripture book(s) that the module is extracting verses from - otherwise PTXprint is going to choke and give you errors. For example, ensure that there’s a \p after the \c chapter and \s section headings, before the first \v verse starts.

0 votes

Still having issues, but the error message is more specific now. Instead of “check for USFM errors”, it reads:
C:…01GENKon.SFM: line 1381,6: missing space after verse number ‘3M’

Ran basic checks for the portion that the module pulls from. It does come up with a lot of errors because I haven’t set up several of the parameters (punctuation followed by lower case, markers followed by lowercase, characters inventory, quotation rules, & repeated words come up as recommendations for completion). Which basic checks are most important for the purposes of this? I didn’t come up with any USFM errors except for not following /q2 with a capital letter.

by (231 points)
0 votes

I would say that the bare minimum would be:
image
And the Markers need to be valid for the whole book (not just the portions of text that you’re extracting from). The reason for this is that the whole book gets processed first and then the needed verses are extracted from that. So it doesn’t matter too much if there are chapters/verses missing, but whatever is there needs to be in good shape in order for us to process it for the module.

by (2.6k points)

Came up with a handful of these in the book the module was from. In one place, there wasn’t a space between the verse number and the first word of the verse. That may have been the issue.
Also about 10 chapters didn’t have section headings and started without a \p marker and a few footnotes didn’t have closing \ft markers. Although I corrected these, I don’t suspect they were the issue.
I did have some empty verses, which I did not correct and did not prevent PTXprint from creating a PDF.

0 votes

I don’t know if paratext basic checks detect this, but if you’ve got anything like one of the first two lines:

\v 1\somemarker shoudn't be part of the verse number
\v 2Nor should words
\v 3-4a Ranges are fine though, as long as you put a space after. 

With no space after the verse number, then although some programs don’t care at all, that is a guaranteed problem for PTXplus / XeTeX.
The second line above won’t crash XeTeX (I’m not sure about the Python front-end), but XeTeX will consider the verse number to be “2Nor” which probably isn’t what you want.

The fix is just put a space in there.

All the USFM documentation I’ve seen assumes there’ll be a space after the number, and the latest version explicitly states it should be there. Chapters and Verses — Unified Standard Format Markers 3.0.0 documentation

by (294 points)
reshown

Related questions

0 votes
1 answer
0 votes
1 answer
Paratext Dec 5, 2022 asked by [Moderator]
james_post
(2.0k points)
0 votes
5 answers
Paratext Oct 26, 2022 asked by anon180868 (188 points)
0 votes
2 answers
Paratext Feb 1, 2022 asked by Shegnada (1.3k points)
0 votes
2 answers
Welcome to Support Bible, where you can ask questions and receive answers from other members of the community.
But if we walk in the light, as he is in the light, we have fellowship with one another, and the blood of Jesus, his Son, purifies us from all sin.
1 John 1:7
2,628 questions
5,369 answers
5,045 comments
1,420 users