From 3770650b68bb3073f543f4a08e68ac3daa3c2869 Mon Sep 17 00:00:00 2001 From: Alejandro Villar Date: Tue, 25 Jul 2023 11:01:15 +0200 Subject: [PATCH] Warn about empty ttl in validation report --- ogc/bblocks/validate.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/ogc/bblocks/validate.py b/ogc/bblocks/validate.py index d81e0f0..58c2843 100644 --- a/ogc/bblocks/validate.py +++ b/ogc/bblocks/validate.py @@ -152,7 +152,10 @@ def validate_inner(): if graph is not None and (resource_contents or filename.suffix != '.ttl'): ttl_fn = output_filename.with_suffix('.ttl') graph.serialize(ttl_fn, format='ttl') - report.add_info('Files', f'Output Turtle {ttl_fn.name} created') + if not graph: + report.add_info('Files', f'Output Turtle {ttl_fn.name} created') + else: + report.add_info('Files', f'*Empty* output Turtle {ttl_fn.name} created') if json_doc: if json_error: