From e83dc1341f1860290bde07d61849c4510ac5ee92 Mon Sep 17 00:00:00 2001 From: Paul Natsuo Kishimoto Date: Wed, 27 Nov 2024 12:30:59 +0100 Subject: [PATCH] Adjust workflow diagram in make_click_command() - Use left-to-right order. - Add debug code to only display the step(s) to the target key(s). --- message_ix_models/workflow.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/message_ix_models/workflow.py b/message_ix_models/workflow.py index b7743e4a4..0bd2c79ea 100644 --- a/message_ix_models/workflow.py +++ b/message_ix_models/workflow.py @@ -361,7 +361,11 @@ def _func(context, go, truncate_step, target_step, **kwargs): if not go: path = context.get_local_path(f"{slug}-workflow.svg") - wf.visualize(str(path)) + wf.visualize( + str(path), + # key=target_step, # DEBUG Uncomment to show only a subset of steps + rankdir="LR", + ) log.info(f"Workflow diagram written to {path}") return