exception handling
This commit is contained in:
@@ -84,9 +84,12 @@ def main(
|
||||
else:
|
||||
func = run
|
||||
|
||||
func(backup_dir, loki_url, tag)
|
||||
|
||||
snapshots.run(loki_url)
|
||||
try:
|
||||
func(backup_dir, loki_url, tag)
|
||||
except Exception:
|
||||
console.print_exception()
|
||||
else:
|
||||
snapshots.run(loki_url)
|
||||
|
||||
|
||||
if __name__ == '__main__':
|
||||
|
||||
@@ -3,8 +3,7 @@ from functools import wraps
|
||||
import docker
|
||||
from docker.models.containers import Container
|
||||
|
||||
|
||||
from restic.console import logger
|
||||
from restic.console import logger, console
|
||||
|
||||
|
||||
def manage_containers(project: str, services: list[str]):
|
||||
|
||||
Reference in New Issue
Block a user