Skip to content

Commit

Permalink
Add clear warning when translation file does not contain a valid tran…
Browse files Browse the repository at this point in the history
…slation class
  • Loading branch information
roelderickx committed May 16, 2021
1 parent bed6f25 commit 3fcb5f5
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion ogr2osm/ogr2osm.py
Original file line number Diff line number Diff line change
Expand Up @@ -234,7 +234,11 @@ def load_translation_object(translation_module):
break

if not translation_object:
logging.info('Using default translations')
if translation_module:
logging.warning('WARNING: translation file does not contain a valid translation class')
logging.warning('Falling back to DEFAULT translations')
else:
logging.info('Using default translations')
translation_object = TranslationBase()

return translation_object
Expand Down

0 comments on commit 3fcb5f5

Please sign in to comment.