LanguageMachines / libfolia

FoLiA library for C++
https://proycon.github.io/folia
GNU General Public License v3.0
15 stars 7 forks source link

How to handle missing version information #26

Closed kosloot closed 4 years ago

kosloot commented 5 years ago

Sometimes FoLiA files don't carry version information. In fact I think this should be an error, but they have been created, and we have to handle them. At the moment libfolia accepts those files, and assigns the CURRENT FoLiA version to them. (This is probably so since a few months) But that is proven wrong. Files may have been created with pré 1.5 version and contain incompatible text elements. (text not matching the deeper text), and the parser bails out. This can be circumvented by setting the environment variable FOLIA_TEXT_CHECK to NO. Which will create a document with a version (like 1.5.1) which still contains the error. This is highly undesirable.

Maybe it is better to set the version to some pre 1.5 like 1.4.10? That will keep the files 'valid' for ever.

@proycon opinions on this? And should we forbid 'version less FoLiA' in the future? I'm in favor.

proycon commented 5 years ago

Agreed, versionless FoLiA should be forbidden in future version. Setting the default to a pre-1.5 sounds like a safe default for backward compatibility yes.

kosloot commented 5 years ago

Ok, I decide to assign 1.4.987 then. Easy to detect when ever necessary. I assume the obligatory version is added to the folia2.0 specs?

kosloot commented 4 years ago

assume this is settled in the folia specs? By making a version number obligatory.