[sword-devel] Reliability with wrong input?

Chris Little sword-devel@crosswire.org
Wed, 05 Jun 2002 12:20:13 -0700



Victor Porton wrote:
> What is the policy on dealing with wrong data in external files (modules):
> 
> - Should the program be written such the way to not crash if a module is wrong 
> or modules should be considered as a part of program and so be relied upon 
> that these are correct?
> 
> - What to do if the information in a module is inconsistent? Should the error 
> be reported, ignored or what?

Modules can be assumed to be correct because if errors are found, they 
should be reported so that they can be corrected so that updates can be 
released.

Dealing with errors in a frontend seems like a good idea from the 
standpoint of robustness, but I would much prefer if it were not done 
because it hinders bug reporting.  An example would be the JFB module. 
It's bad XML, which should be corrected in the module.  If it is 
corrected in the frontend, it will be more difficult to discover such 
errors because they don't appear as tiny text.

(NB to those waiting for the new JFB, it is completed and ready for 
import, but there are some bugs in Sword relating to heading handling 
that are presently preventing me from doing so.... It should be ready 
soon though.)

--Chris