Mercurial > hg > decoupage
comparison decoupage/web.py @ 114:5099d45c7730 default tip
output ini_path on error
author | Jeff Hammel <k0scist@gmail.com> |
---|---|
date | Mon, 03 Jun 2024 09:29:38 -0700 |
parents | fb4bdbfbce83 |
children |
comparison
equal
deleted
inserted
replaced
113:cc54fa8065c5 | 114:5099d45c7730 |
---|---|
351 conf = OrderedDict() | 351 conf = OrderedDict() |
352 | 352 |
353 # local configuration | 353 # local configuration |
354 ini_path = os.path.join(directory, 'index.ini') | 354 ini_path = os.path.join(directory, 'index.ini') |
355 if os.path.exists(ini_path): | 355 if os.path.exists(ini_path): |
356 _conf = ConfigMunger(ini_path).dict() | 356 try: |
357 _conf = ConfigMunger(ini_path).dict() | |
358 except Exception as e: | |
359 print(f"Error reading INI {ini_path}: {e}") | |
360 raise | |
357 if len(_conf) == 1: | 361 if len(_conf) == 1: |
358 conf = _conf[list(_conf.keys())[0]].copy() | 362 conf = _conf[list(_conf.keys())[0]].copy() |
359 | 363 |
360 # global configuration | 364 # global configuration |
361 if not conf and self.configuration and os.path.exists(self.configuration): | 365 if not conf and self.configuration and os.path.exists(self.configuration): |