From fffe8c25b6c52f1753d365830f413b62f95c8a45 Mon Sep 17 00:00:00 2001 From: Benedikt Ziemons Date: Fri, 1 May 2020 00:22:07 +0200 Subject: [PATCH] Fix unpacking error --- wmn.py | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/wmn.py b/wmn.py index 3e026c6..7f7dae3 100644 --- a/wmn.py +++ b/wmn.py @@ -145,8 +145,10 @@ def process_jenkins_request(): commit_link = f"{bare_commit_link}" else: commit_link = bare_commit_link - return (f"
  • {shorten(change_message)} {commit_link} by {change['author']} at {htimestamp}
  • ", - f"- {shorten(change_message)} {bare_commit_link} by {change['author']} at {htimestamp}") + return ( + f"- {shorten(change_message)} {bare_commit_link} by {change['author']} at {htimestamp}", + f"
  • {shorten(change_message)} {commit_link} by {change['author']} at {htimestamp}
  • ", + ) else: return shorten(json.dumps(change).replace("<", "&"), appendix="...}") @@ -154,7 +156,7 @@ def process_jenkins_request(): project_name = request.json["project"]["fullDisplayName"] result_type = request.json["result"]["type"] result_color = request.json["result"]["color"] - html_change_messages, text_change_messages = map(extract_change_message, request.json['changes']) + text_change_messages, html_change_messages = zip(*map(extract_change_message, request.json['changes'])) newline = '\n' try: room.send_html(f"

    Build {build_name} on project {project_name} complete: "