From 8e61019451510b7b988850c6598787c10184b744 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C3=85ke=20Forslund?= Date: Sun, 15 Mar 2020 19:11:01 +0100 Subject: [PATCH] Copy the list of active skills during operations A skill can be missed if a skill is removed (due to an error) from the list during iteration --- mycroft/skills/intent_service.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/mycroft/skills/intent_service.py b/mycroft/skills/intent_service.py index 93f348109b..e0bcb36423 100644 --- a/mycroft/skills/intent_service.py +++ b/mycroft/skills/intent_service.py @@ -234,6 +234,7 @@ class IntentService: return result.data.get('result', False) def handle_converse_error(self, message): + LOG.error(message.data['error']) skill_id = message.data["skill_id"] if message.data["error"] == "skill id does not exist": self.remove_active_skill(skill_id) @@ -401,7 +402,7 @@ class IntentService: 1] <= self.converse_timeout * 60] # check if any skill wants to handle utterance - for skill in self.active_skills: + for skill in copy(self.active_skills): if self.do_converse(utterances, skill[0], lang, message): # update timestamp, or there will be a timeout where # intent stops conversing whether its being used or not