Debugging Schematron

There are some issues when debugging Schematron files. Since the first steps are simply to create an XSLT file, as long as the input XML is well formed it is not likely that many errors will be found. It is when the generated XSLT file is run against the input file that the XSLT engine will find the errors. The stylesheet causing the errors is generated, so the line numbers will not be relevant. You need to trace back from that stylesheet to the patterns that generated the XSLT to see where the real problem lies. Not really a problem, just be aware of it.
When using includes or abstract patterns, the errors could well be in the included files, and the errors won't relate to those files. Again, just use a little logic to trace the error back to source