diff --git a/aries_cloudagent/__main__.py b/aries_cloudagent/__main__.py index 469dd073c7..2677b8cc8e 100644 --- a/aries_cloudagent/__main__.py +++ b/aries_cloudagent/__main__.py @@ -26,7 +26,7 @@ def init_debug(args): import debugpy debugpy.listen((PTVSD_HOST, PTVSD_PORT)) - print("=== Waiting for debugger to attach ===") + print(f"=== Waiting for debugger to attach to {PTVSD_HOST}:{PTVSD_PORT} ===") debugpy.wait_for_client() except ImportError: print("debugpy library was not found") diff --git a/aries_cloudagent/config/argparse.py b/aries_cloudagent/config/argparse.py index 34427e9431..b24873d868 100644 --- a/aries_cloudagent/config/argparse.py +++ b/aries_cloudagent/config/argparse.py @@ -213,12 +213,11 @@ def get_settings(self, args: Namespace): ) return settings +@group(CAT_PROVISION, CAT_START, CAT_UPGRADE) +class DebuggerGroup(ArgumentGroup): + """Debugger settings.""" -@group(CAT_START) -class DebugGroup(ArgumentGroup): - """Debug settings.""" - - GROUP_NAME = "Debug" + GROUP_NAME = "Debugger" def add_arguments(self, parser: ArgumentParser): """Add debug command line arguments to the parser.""" @@ -232,6 +231,23 @@ def add_arguments(self, parser: ArgumentParser): "for the debugger to connect at start-up. Default: false." ), ) + + def get_settings(self, args: Namespace) -> dict: + """Extract debug settings.""" + settings = {} + if args.debug: + settings["debug.enabled"] = True + return settings + + +@group(CAT_START) +class DebugGroup(ArgumentGroup): + """Debug settings.""" + + GROUP_NAME = "Debug" + + def add_arguments(self, parser: ArgumentParser): + """Add debug command line arguments to the parser.""" parser.add_argument( "--debug-seed", dest="debug_seed", @@ -415,8 +431,6 @@ def add_arguments(self, parser: ArgumentParser): def get_settings(self, args: Namespace) -> dict: """Extract debug settings.""" settings = {} - if args.debug: - settings["debug.enabled"] = True if args.debug_connections: settings["debug.connections"] = True if args.debug_credentials: