From 33ae19a57dc12ffb38973de5666b428e11187602 Mon Sep 17 00:00:00 2001 From: Daniil Baturin Date: Wed, 17 Jul 2024 11:45:35 +0100 Subject: op-mode: T6586: add a distinct exception for unconfigured objects as opposed to entire subsystems --- python/vyos/opmode.py | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) (limited to 'python/vyos') diff --git a/python/vyos/opmode.py b/python/vyos/opmode.py index 8dab9a4ca..a9819dc4b 100644 --- a/python/vyos/opmode.py +++ b/python/vyos/opmode.py @@ -31,7 +31,15 @@ class Error(Exception): class UnconfiguredSubsystem(Error): """ Requested operation is valid, but cannot be completed - because corresponding subsystem is not configured and running. + because corresponding subsystem is not configured + and thus is not running. + """ + pass + +class UnconfiguredObject(UnconfiguredSubsystem): + """ Requested operation is valid but cannot be completed + because its parameter refers to an object that does not exist + in the system configuration. """ pass -- cgit v1.2.3