[jsword-devel] Bug creating index with Bibledesktop 1.05

DM Smith dmsmith555 at yahoo.com
Fri Jan 5 10:10:27 MST 2007


Zhaojun Li(李召军) wrote:
> Can you share the details?
Sure.

AccuracyType.java is the tokenizing engine for a verse reference, 
potentially a partial reference.

Its basic mehanism is to find transitional boundaries between letters, 
numbers, and other (e.g. punctuation marks and spaces). Everything 
between boundaries are taken to be a token.

The tokens "ff" and "$" are special in that they signify "to the end". 
These are always expected to follow a "-" (i.e. a range specifier), but 
tokenize does not care about parsing rules.

When given "Offenbarung" tokenize sees "O", "ff", "enbarung". Code that 
uses this token stream fails to understand it. (In order to see the 
problem you might need to set your locale to "de").

The problem is that when an "f" is seen, it checks to see if the next 
character is also an "f" but did not check to see if the character 
before it was not a letter, nor did it look further ahead. So the 
solution is to see if "ff" is surrounded by non-letters.

The other bug is still a mystery to me, but when I try to go to any 
verse in German Darby Unrevidierte Elberfelder (1905), I get a 
ClassCastException from within xalan or crimson that is bundled with 
Java 1.4.2.

>
> On 1/4/07, *DM Smith* <dmsmith555 at yahoo.com 
> <mailto:dmsmith555 at yahoo.com>> wrote:
>
>     Martin,
>     The problem with Offenbarung 1.1 was a bug. The ff was taken to be a
>     number as in Matt 1:3-ff or Joh 7-ff, where ff means to the end of the
>     chapter or book. I have fixed it but have uncovered another problem
>     which I also need to fix. I'll keep you posted.
>     DM
>
>     DM Smith wrote:
>     > Martin,
>     > It is fine to discuss module problems here. In this case this is not
>     > a problem with the module but with BibleDesktop. We are in the
>     > process of translating the program into German (which I am sure you
>     > noticed). This may be a problem with the program being incomplete.
>     > I'll take a look at this and lpost here what I find. It may take
>     me a
>     > few days before I can get to it though.
>     >
>     > The problem with the "warnings" on "unknown thml" elements indicates
>     > a problem with the module. JSword (the Sword engine that
>     BibleDesktop
>     > uses) reports everything it encounters that it does not understand.
>     > I'll report these problems so they can be fixed.
>     >
>     > In His Service,
>     > DM
>     >
>     > On Dec 28, 2006, at 8:35 AM, Martin Jacobs wrote:
>     >
>     >
>     >> Hello,
>     >>
>     >> I'm new to this project and not sure if this is the right
>     >> forum to discuss bugs specific to bible books. Anyway I tried
>     >> Bibledestop 1.0.5 on my Linux box with jre (1.5) and j2re
>     >> (1.4). Both produced the same result.
>     >>
>     >> Trying to create an index on the downloaded german book
>     >>
>     >> German Darby Unrevidierte Elberfelder (1905) (Sword)
>     >>
>     >> I get this break during index creation:
>     >>
>     >> INFO: Key can't be a passage: Offenbarung 1:1
>     >> Exception in thread "Thread-2" java.lang.NullPointerException
>     >> at org.crosswire.jsword.book.OSISUtil.getVerseText
>     >> (OSISUtil.java:551)
>     >> at org.crosswire.jsword.book.BookData.getVerseText
>     >> (BookData.java:77)
>     >> at
>     >>
>     org.crosswire.jsword.index.lucene.LuceneIndex.generateSearchIndexImpl(
>     >> LuceneIndex.java:354)
>     >> at org.crosswire.jsword.index.lucene.LuceneIndex.<init>
>     >> (LuceneIndex.java :130)
>     >> at org.crosswire.jsword.index.lucene.LuceneIndexManager
>     >> $1.run(LuceneIndexManager.java:109)
>     >> at java.lang.Thread.run(Unknown Source)
>     >>
>     >>
>     >>
>     >> Same problem during index creation on book
>     >>
>     >> German Luther Bible (1912) (Sword)
>     >>
>     >> INFO: Key can't be a passage: Offenbarung 1:1
>     >> Exception in thread "Thread-2" java.lang.NullPointerException
>     >> at org.crosswire.jsword.book.OSISUtil.getVerseText
>     >> (OSISUtil.java:551)
>     >> at org.crosswire.jsword.book.BookData.getVerseText
>     >> (BookData.java :77)
>     >> at
>     >>
>     org.crosswire.jsword.index.lucene.LuceneIndex.generateSearchIndexImpl(
>     >> LuceneIndex.java:354)
>     >> at org.crosswire.jsword.index.lucene.LuceneIndex.<init>
>     >> (LuceneIndex.java:130)
>     >> at org.crosswire.jsword.index.lucene.LuceneIndexManager
>     >> $1.run(LuceneIndexManager.java:109)
>     >> at java.lang.Thread.run(Unknown Source)
>     >>
>     >>
>     >> Same problem during index creation on book
>     >>
>     >> German Elberfelder (1871) (Sword)
>     >>
>     >> INFO: Key can't be a passage: Offenbarung 1:1
>     >> Exception in thread "Thread-3" java.lang.NullPointerException
>     >> at org.crosswire.jsword.book.OSISUtil.getVerseText
>     >> (OSISUtil.java:551)
>     >> at org.crosswire.jsword.book.BookData.getVerseText
>     >> (BookData.java :77)
>     >> at
>     >>
>     org.crosswire.jsword.index.lucene.LuceneIndex.generateSearchIndexImpl(
>     >> LuceneIndex.java:354)
>     >> at org.crosswire.jsword.index.lucene.LuceneIndex.<init>
>     >> (LuceneIndex.java:130)
>     >> at org.crosswire.jsword.index.lucene.LuceneIndexManager
>     >> $1.run(LuceneIndexManager.java:109)
>     >> at java.lang.Thread.run(Unknown Source)
>     >>
>     >> In addition, this process creates lots of messages:
>     >>
>     >> 28.12.2006 12:07:06
>     >> org.crosswire.jsword.book.filter.thml.CustomHandler getTag
>     >> INFO: In GerElb1871(3. Mose 5:19) unknown thml element:
>     qname=WTH5-20
>     >> 28.12.2006 12:07:06
>     >> org.crosswire.jsword.book.filter.thml.CustomHandler getTag
>     >> INFO: In GerElb1871(3. Mose 5:19) unknown thml element:
>     qname=WTH5-21
>     >> 28.12.2006 12:07:06
>     >> org.crosswire.jsword.book.filter.thml.CustomHandler getTag
>     >> INFO: In GerElb1871(3. Mose 5:19) unknown thml element:
>     qname=WTH5-22
>     >> 28.12.2006 12:07:06
>     >> org.crosswire.jsword.book.filter.thml.CustomHandler getTag
>     >> INFO: In GerElb1871(3. Mose 5:19) unknown thml element:
>     qname=WTH5-23
>     >> 28.12.2006 12:07:06
>     >> org.crosswire.jsword.book.filter.thml.CustomHandler getTag
>     >> INFO: In GerElb1871(3. Mose 5:19) unknown thml element:
>     qname=WTH5-24
>     >> 28.12.2006 12:07:06
>     >> org.crosswire.jsword.book.filter.thml.CustomHandler getTag
>     >> INFO: In GerElb1871(3. Mose 5:19) unknown thml element:
>     qname=WTH5-25
>     >> 28.12.2006 12:07:06
>     >> org.crosswire.jsword.book.filter.thml.CustomHandler getTag
>     >> INFO: In GerElb1871(3. Mose 5:19) unknown thml element:
>     qname=WTH5-26
>     >> 28.12.2006 12:07:06
>     >> org.crosswire.jsword.book.filter.thml.CustomHandler getTag
>     >> INFO: In GerElb1871(3. Mose 5:19) unknown thml element:
>     qname=WTH5-20
>     >> 28.12.2006 12:07:06
>     >> org.crosswire.jsword.book.filter.thml.CustomHandler getTag
>     >> INFO: In GerElb1871(3. Mose 5:19) unknown thml element:
>     qname=WTH5-21
>     >> 28.12.2006 12:07:06
>     >> org.crosswire.jsword.book.filter.thml.CustomHandler getTag
>     >> INFO: In GerElb1871(3. Mose 5:19) unknown thml element:
>     qname=WTH5-22
>     >> 28.12.2006 12:07:06
>     >> org.crosswire.jsword.book.filter.thml.CustomHandler getTag
>     >> INFO: In GerElb1871(3. Mose 5:19) unknown thml element:
>     qname=WTH5-23
>     >> 28.12.2006 12:07:06
>     >> org.crosswire.jsword.book.filter.thml.CustomHandler getTag
>     >> INFO: In GerElb1871(3. Mose 5:19) unknown thml element:
>     qname=WTH5-24
>     >> 28.12.2006 12:07:06
>     >> org.crosswire.jsword.book.filter.thml.CustomHandler getTag
>     >> INFO: In GerElb1871(3. Mose 5:19) unknown thml element:
>     qname=WTH5-25
>     >> 28.12.2006 12:07:06
>     >> org.crosswire.jsword.book.filter.thml.CustomHandler getTag
>     >> INFO: In GerElb1871(3. Mose 5:19) unknown thml element:
>     qname=WTH5-26
>     >> 28.12.2006 12:07:16
>     >> org.crosswire.jsword.book.filter.thml.CustomHandler getTag
>     >> INFO: In GerElb1871(4. Mose 30:16) unknown thml element:
>     >> qname=WTH30-17
>     >> 28.12.2006 12:07:16
>     >> org.crosswire.jsword.book.filter.thml.CustomHandler getTag
>     >> INFO: In GerElb1871(4. Mose 30:16) unknown thml element:
>     >> qname=WTH30-17
>     >> 28.12.2006 12:07:21
>     >> org.crosswire.jsword.book.filter.thml.CustomHandler getTag
>     >> INFO: In GerElb1871(5. Mose 28:68) unknown thml element:
>     >> qname=WTH28-69
>     >> 28.12.2006 12:07:21
>     >> org.crosswire.jsword.book.filter.thml.CustomHandler getTag
>     >> INFO: In GerElb1871(5. Mose 28:68) unknown thml element:
>     >> qname=WTH28-69
>     >> 28.12.2006 12:07:33
>     >> org.crosswire.jsword.book.filter.thml.CustomHandler getTag
>     >> INFO: In GerElb1871(1. Samuel 20:42) unknown thml element:
>     >> qname=WTH20-43
>     >> 28.12.2006 12:07:33
>     >> org.crosswire.jsword.book.filter.thml.CustomHandler getTag
>     >> INFO: In GerElb1871(1. Samuel 20:42) unknown thml element:
>     >> qname=WTH20-43
>     >> 28.12.2006 12:07:34
>     >> org.crosswire.jsword.book.filter.thml.CustomHandler getTag
>     >> INFO: In GerElb1871(1. Samuel 24:22) unknown thml element:
>     >> qname=WTH24-23
>     >> 28.12.2006 12:07:34
>     >> org.crosswire.jsword.book.filter.thml.CustomHandler getTag
>     >> INFO: In GerElb1871(1. Samuel 24:22) unknown thml element:
>     >> qname=WTH24-23
>     >> 28.12.2006 12:07:43
>     >> org.crosswire.jsword.book.filter.thml.CustomHandler getTag
>     >> INFO: In GerElb1871(1. Könige 22:53) unknown thml element:
>     >> qname=WTH22-54
>     >> 28.12.2006 12:07:43
>     >> org.crosswire.jsword.book.filter.thml.CustomHandler getTag
>     >> INFO: In GerElb1871(1. Könige 22:53) unknown thml element:
>     >> qname=WTH22-54
>     >> 28.12.2006 12:07:46
>     >> org.crosswire.jsword.book.filter.thml.CustomHandler getTag
>     >> INFO: In GerElb1871(2. Könige 15:38) unknown thml element:
>     >> qname=WTH15-39
>     >> [...]
>     >> and much more.
>     >>
>     >> Thanks in advance
>     >>
>     >> Martin Jacobs
>     >>
>     >>
>     >>
>     >>
>     >>
>     >>
>     >>
>     >>
>     >> _______________________________________________
>     >> jsword-devel mailing list
>     >> jsword-devel at crosswire.org <mailto:jsword-devel at crosswire.org>
>     >> http://www.crosswire.org/mailman/listinfo/jsword-devel
>     <http://www.crosswire.org/mailman/listinfo/jsword-devel>
>     >>
>     >
>     >
>     > _______________________________________________
>     > jsword-devel mailing list
>     > jsword-devel at crosswire.org <mailto:jsword-devel at crosswire.org>
>     > http://www.crosswire.org/mailman/listinfo/jsword-devel
>     >
>     >
>
>
>     _______________________________________________
>     jsword-devel mailing list
>     jsword-devel at crosswire.org <mailto:jsword-devel at crosswire.org>
>     http://www.crosswire.org/mailman/listinfo/jsword-devel
>
>
> ------------------------------------------------------------------------
>
> _______________________________________________
> jsword-devel mailing list
> jsword-devel at crosswire.org
> http://www.crosswire.org/mailman/listinfo/jsword-devel
>   




More information about the jsword-devel mailing list