From 99da2517fd23f9ded7b990b9e38dd7b5165d236a Mon Sep 17 00:00:00 2001 From: David Vo Date: Mon, 15 Jan 2024 17:25:38 +1100 Subject: [PATCH] Fix state enum name in dynamic command name --- commands2/sysid/sysidroutine.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/commands2/sysid/sysidroutine.py b/commands2/sysid/sysidroutine.py index f81d5421..67876e8f 100644 --- a/commands2/sysid/sysidroutine.py +++ b/commands2/sysid/sysidroutine.py @@ -170,6 +170,8 @@ def end(interrupted: bool): self.mechanism.subsystem.runOnce(command) .andThen(self.mechanism.subsystem.run(execute)) .finallyDo(end) - .withName(f"sysid-{state}-{self.mechanism.name}") + .withName( + f"sysid-{SysIdRoutineLog.stateEnumToString(state)}-{self.mechanism.name}" + ) .withTimeout(self.config.timeout) )