[sword-devel] PATCH Genbook osisRef does not conform to OSIS in libsword

Troy A. Griffitts scribe at crosswire.org
Mon Jun 22 02:38:57 MST 2015

Hi Tuomas,

Thank you for the patch.  Unfortunately, it is not this easy.  Your
patch would invalidate all current genbook modules.  I believe we've
discussed this here on sword-devel in the past.  I can't remember the
discussion, but I believe it was to either allow '/' in the OSIS spec or
violate the OSIS spec for now.

The problem right now is a few fold:

1) We supported GenBooks before OSIS and in other formats and decided on
'/' separation of levels then.  Our key syntax.  We need to discuss what
this mean for our other markup formats.  Karl Kleinpaste would be idea
to speak with as he develops GenBook modules in other than OSIS markups.

2) We do no yet support an escape control sequence to allow the literal
division character to be included in the path.  There are far fewer
literal '/' characters in book sections then there are '.' characters.
We can change the few for now to something else.  The ultimate solution
is to support an escape sequence, which we've also discussed on
sword-devel quite a bit.

3) We have MANY genbook modules out in the wild, being used by the user
base of our many different application and can't invalidate all of their
genbooks.  We need an upgrade path for all current modules now or better
a backward compatible patch until current genbook modules have an
upgrade path.

Hope this makes sense.  Thank you for spending time talking about the
issue and being willing to get involved.  If you'd like to look into the
items above, we can work our way toward a solution.

Is there a hindrance you're trying to solve with module development or
something else we might help you with in the meantime?  I believe DM
Smith keeps a patch OSIS Schema around with all of our suggested updates
to the Schema, which likely allows '/' for genbooks.  He probably can
post that if your issue is validating Schema validating a genbook.

Welcome!  It's nice to have you,


On 06/22/2015 09:23 AM, Tuomas Airaksinen wrote:
> Hi all,
> Currently in libsword apps, referenses to genbook nodes need to be
> written in form osisRef="BookId:rootnode/branchnode/leafnode". This is
> wrong, because OSIS xml scheme does not allow '/' character in
> osisRefs. Instead, osisRef should be in form,
> osisRef="BookId:rootnode.branchnode.leafnode". Also http://www.crosswire.org/wiki/OSIS_Genbooks
> suggest the latter form.
> See also discussion on https://github.com/crosswire/jsword/pull/98 
> Attached is the patch to fix this issue. I tested this with Xiphos and
> it seems to work fine. 
> Thanks,
> Best regards, Tuomas
> ps. 
> just a little humble suggestion, *please* move to github. It would be a
> lot more convenient and easier to get involved to development via
> pullrequests than this way. 
> _______________________________________________
> sword-devel mailing list: sword-devel at crosswire.org
> http://www.crosswire.org/mailman/listinfo/sword-devel
> Instructions to unsubscribe/change your settings at above page

More information about the sword-devel mailing list