summaryrefslogtreecommitdiff
path: root/python/vyos
diff options
context:
space:
mode:
authorDaniil Baturin <daniil@baturin.org>2024-07-17 11:45:35 +0100
committerDaniil Baturin <daniil@baturin.org>2024-07-17 11:45:35 +0100
commit33ae19a57dc12ffb38973de5666b428e11187602 (patch)
tree3dedbe75601c95f3fefccbd5450bdacd958fdfa6 /python/vyos
parente9232c7a751ffec34f18e1734cb18ac01da35cb7 (diff)
downloadvyos-1x-33ae19a57dc12ffb38973de5666b428e11187602.tar.gz
vyos-1x-33ae19a57dc12ffb38973de5666b428e11187602.zip
op-mode: T6586: add a distinct exception for unconfigured objects
as opposed to entire subsystems
Diffstat (limited to 'python/vyos')
-rw-r--r--python/vyos/opmode.py10
1 files changed, 9 insertions, 1 deletions
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