[sword-devel] Small problem with section headers in an OSIS module

Chris Little chrislit at crosswire.org
Sat Nov 29 22:00:16 MST 2008


Tom Cornell wrote:
> I'm using BibleTime 1.6.5.1, compiled with  (I'm pretty sure) Sword
> 1.5.11. I don't think the problem can be in the front end, because the
> ESV module behaves just fine in this regard. So I'm pretty sure there
> is a wrinkle in the OSIS code that the ESV compilers got right and I
> have gotten wrong.

The description of the problem makes me initially suspect a frontend or 
filter problem. That could be the case, even if the ESV looks right.

The other (very good) possibility is a problem with the importer. DM 
just did a rather radical update to osis2mod (and by "just", I mean 
since 1.5.11). So my first question would be: are you using osis2mod 
from 1.5.11 (or another release) or are you compiling it from SVN?

Another piece of data that would help us to analyze where the bug is 
(and I'm fairly certain it's a bug in someone's code) would be a chunk 
of data from the module itself (post osis2mod). You can get at this by 
running mod2imp on your module. Then search the resulting .imp file for 
an example of the misbehaving data and post a snippet to the list. Since 
you have headings, there should definitely have been some manipulation 
of the data by osis2mod. It's just hard to guess what it might have done 
wrong (if that's the case).

In the near term, if you just want to get things working, you might try 
the other recent version of osis2mod (so, SVN if you used 1.5.11 or 
1.5.11 if you used SVN).

> My markup looks like this, basically:
> 
> ...
> </div>
> <div type="section">
> <title>The Section Title</title>
> <verse sID="..." .../>...<verse eID="..."/>
> ...
> </div>

This markup is definitely correct.



More long-term, DM and I are in agreement that we need to change the way 
we handle storage of OSIS documents within modules. We feel we need to 
get away from the pre-verse hacks that you'll notice in the output from 
mod2imp. And we feel we need to do a better job of preserving all of the 
data in a document (including the <verse> tags themselves).

When I committed a new version of osis2mod 3-4 years ago that did all of 
this (in a way that neither harmed existing nor future data) it was 
roundly rejected and reverted. I'm still convinced that preservation, 
including storing <verse>, is the only solution to certain of our 
problems. And I'm hoping that DM and I can convince the naysayers of the 
merits of that position.

--Chris



More information about the sword-devel mailing list