Project

General

Profile

Actions

Demande #6478

open

agirbot/redminebot: "IndexError: list index out of range"

Added by Pierre-Louis Bonicoli 5 months ago.

Status:
Nouveau
Priority:
Normale
Assignee:
-
Category:
-
Target version:
Start date:
07/18/2024
Due date:
% Done:

0%

Estimated time:
Difficulté:
2 Facile

Description

Jul 18 13:26:50 bots welcomebot.py[120997]: 2024-07-18T13:26:50.082006 PING :copper.libera.chat
Jul 18 13:26:50 bots redminebot.py[120996]: 2024-07-18 13:26:50,082 ERROR MainThread __main__ Exception raised to irc message parsing
Jul 18 13:26:50 bots redminebot.py[120996]: Traceback (most recent call last):
Jul 18 13:26:50 bots redminebot.py[120996]:   File "/srv/redminebot/redminebot.py", line 95, in parse_irc_messages
Jul 18 13:26:50 bots redminebot.py[120996]:     target = irc_msg.split(":")[1].split(" ")[2]
Jul 18 13:26:50 bots redminebot.py[120996]:              ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^
Jul 18 13:26:50 bots redminebot.py[120996]: IndexError: list index out of range
Jul 18 13:26:50 bots redminebot.py[120996]: 2024-07-18 13:26:50,082 INFO MainThread __main__ Checking all projects updates...

Le message qui déclenche l'exception: irc_msg='PING :copper.libera.chat'.

Étant donné que :
- le message est en fait correctement parsé (la méthode parse_irc_messages retourne 'PING :copper.libera.chat', 'copper.libera.chat', None plutôt que None, None, None;
- le bot répond bien pong aux messages ping,
Je propose de changer le niveau du log : debug plutôt que error.

No data to display

Actions

Also available in: Atom PDF