Skip to content

Commit 69a21ea

Browse files
committed
fix: delete old module data on duplicate uuid of dead module
1 parent 354a2b3 commit 69a21ea

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

handlers/control.py

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -63,11 +63,12 @@ def create_module(self, msg):
6363
# module is running, will error out with a duplicate UUID
6464
raise messages.DuplicateUUID(data, obj_type='module')
6565
else:
66-
module.status = State.ALIVE
67-
except messages.UUIDNotFound:
66+
module.delete()
67+
except messages.UUIDNotFound:
6868
# ok, will create a new one
69-
module = self._object_from_dict(Module, data)
70-
69+
pass
70+
71+
module = self._object_from_dict(Module, data)
7172
module.parent = self.__get_runtime_or_schedule(msg, module)
7273

7374
try:

0 commit comments

Comments
 (0)