From ed983d36aea44b07f3ae891b26c7f4c9a5e6889e Mon Sep 17 00:00:00 2001 From: Markus Zolliker Date: Mon, 16 Oct 2023 11:39:19 +0200 Subject: [PATCH] [WIP] frappy(): show all servers config --- devices.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/devices.py b/devices.py index be8d1d3..0c61658 100644 --- a/devices.py +++ b/devices.py @@ -299,7 +299,7 @@ class FrappyConfig(Device): raise TypeError('got multiple values for addons') addons = ','.join(alist) elif main is None and stick is None and addons is None: # bare frappy() command - self.show_config(self.check_services()) + self.show_config(self.check_services(), True) return if confirmed and confirmed != main and main not in (None, 'restart') and not force: session.log.warning('%r is plugged to the cryostat control rack', confirmed) @@ -308,7 +308,7 @@ class FrappyConfig(Device): raise TypeError('refuse to override plugged device') self.show_config(self.start_services(main, stick, addons)) - def show_config(self, allcfg): + def show_config(self, allcfg, full=False): proposed, overview = self.to_consider(allcfg) # remove 'frappy_changed()' commands in script queue controller = session.daemon_device._controller @@ -322,6 +322,8 @@ class FrappyConfig(Device): session.log.info(info) if '?' in info: session.log.warning("but create cfg files first for items marked with '?'") + if full: + session.log.info('\n' + '\n'.join(overview)) def initial_restart_cfg(self, service): """get cfg for (re)start of the service