From 46173f284cd971c4201969fa9fd35121c7cf7a3a Mon Sep 17 00:00:00 2001 From: Daniil Baturin Date: Thu, 4 Aug 2022 12:51:27 -0400 Subject: T2719: add an exception hierarchy for op mode errors --- src/op_mode/container.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/op_mode/container.py') diff --git a/src/op_mode/container.py b/src/op_mode/container.py index 78d42f800..ce466ffc1 100755 --- a/src/op_mode/container.py +++ b/src/op_mode/container.py @@ -80,6 +80,6 @@ if __name__ == '__main__': res = vyos.opmode.run(sys.modules[__name__]) if res: print(res) - except ValueError as e: + except (ValueError, vyos.opmode.Error) as e: print(e) sys.exit(1) -- cgit v1.2.3