Log when closing DB.

master
voussoir 2022-11-06 22:49:06 -08:00
parent a514ed5ff3
commit e8e4a3dbc0
No known key found for this signature in database
GPG Key ID: 5F7554F8C26DACCB
2 changed files with 4 additions and 1 deletions

View File

@ -1676,6 +1676,7 @@ class PhotoDB(
return f'PhotoDB(data_directory={self.data_directory})'
def close(self) -> None:
log.debug('Closing PhotoDB.')
super().close()
if getattr(self, 'ephemeral', False):

View File

@ -68,7 +68,9 @@ def etiquette_flask_launch(
http.serve_forever()
except KeyboardInterrupt:
log.info('Goodbye')
return 0
backend.common.P.close()
return 0
def etiquette_flask_launch_argparse(args):
return etiquette_flask_launch(