Closed Michahel closed 3 years ago
I believe I found your issue. That error could have been caused by USX files that contain <ref>
tags referencing books that are not part of the Bible. Especially embarrassing as the first thing the OnLineBible exporter does is remove those references.
I pushed a fix to master branch that hopefully fixes that issue. Can you please test?
If compiling is troublesome for you, you can click the green check mark icon next to the commit ID (above), choose the build you like (Java 8 vs. Java 11), then click "details", then "artifacts" (upper right corner) and it will allow you to download the version compiled on GitHub's CI infrastructure.
If it does not solve the issue, would it be possible to share the file that cannot be converted?
While processing one of the files, I received the following error message:
C:\PROGS\BibleMultiConverter>java -jar BibleMultiConverter.jar USX N:\Bibles\CAR
S\Text OnLineBible N:\Bibles\CARS\CARS.Exp
WARNING: Unsupported book abbreviation Нач., using Gen instead
WARNING: Unsupported book abbreviation Исх., using Exod instead
WARNING: Unsupported book abbreviation Лев., using Lev instead
WARNING: Unsupported book abbreviation Чис., using Num instead
WARNING: Unsupported book abbreviation Втор., using Deut instead
WARNING: Unsupported book abbreviation Иеш., using Josh instead
WARNING: Unsupported book abbreviation Суд., using Judg instead
WARNING: Unsupported book abbreviation Руфь, using Ruth instead
WARNING: Unsupported book abbreviation 1Цар., using 1Sam instead
WARNING: Unsupported book abbreviation 2Цар., using 2Sam instead
WARNING: Unsupported book abbreviation 3Цар., using 1Kgs instead
WARNING: Unsupported book abbreviation 4Цар., using 2Kgs instead
WARNING: Unsupported book abbreviation 1Лет., using 1Chr instead
WARNING: Unsupported book abbreviation Иуда, using Jude instead
WARNING: Ignoring unreferenced headlines
Exception in thread "main" java.lang.IllegalArgumentException: lastChapter is in
valid: 9
at biblemulticonverter.data.Utils.validateNumber(Utils.java:26)
at biblemulticonverter.data.FormattedText$CrossReference.<init>(Formatte
dText.java:250)
at biblemulticonverter.data.FormattedText$CrossReference.<init>(Formatte
dText.java:237)
at biblemulticonverter.data.FormattedText$AppendVisitor.visitCrossRefere
nce(FormattedText.java:703)
at biblemulticonverter.format.paratext.AbstractParatextFormat$ParatextIm
portVisitor.visitReference(AbstractParatextFormat.java:590)
at biblemulticonverter.format.paratext.ParatextCharacterContent$Referenc
e.acceptThis(ParatextCharacterContent.java:475)
at biblemulticonverter.format.paratext.ParatextBook$ParatextCharacterCon
tentContainer.accept(ParatextBook.java:555)
at biblemulticonverter.format.paratext.ParatextCharacterContent$AutoClos
ingFormatting.acceptThis(ParatextCharacterContent.java:190)
at biblemulticonverter.format.paratext.ParatextBook$ParatextCharacterCon
tentContainer.accept(ParatextBook.java:555)
at biblemulticonverter.format.paratext.AbstractParatextFormat$1.visitPar
atextCharacterContent(AbstractParatextFormat.java:227)
at biblemulticonverter.format.paratext.ParatextCharacterContent.acceptTh
is(ParatextCharacterContent.java:35)
at biblemulticonverter.format.paratext.ParatextBook.accept(ParatextBook.
java:113)
at biblemulticonverter.format.paratext.AbstractParatextFormat.importPara
textBook(AbstractParatextFormat.java:128)
at biblemulticonverter.format.paratext.AbstractParatextFormat.doImport(A
bstractParatextFormat.java:112)
at biblemulticonverter.Main.main(Main.java:66)
The reason is in the following reference, which looks like this:
<ref loc="1CH 11-9">1 Лет. 11–2 Лет. 9</ref>
Here the reference is really wrong. It should be like this:
<ref loc="1CH 11:1-2CH 9:31">1 Лет. 11–2 Лет. 9</ref>
Is it possible to handle this case so that the logs contain a message like:
Invalid Cross Reference At - File:
and then an exact indication of the file name and the place in the text where this invalid reference is located?
The error position would already have been printed if the invalid reference were detected by the USX import module. Unfortunately it was detected later. I moved the detection to the USX and USX3 import module so now you will
I have successfully compiled BibleMultiConverter from source. However, I experience problems converting from USX to OnLineBible. I am including the error messages that were displayed.