From f02815d02211a5b6de7e26cf7a0f984eadbc999e Mon Sep 17 00:00:00 2001 From: lloydzhou Date: Thu, 1 Feb 2024 11:32:29 +0800 Subject: [PATCH 1/2] hotfix: save pull request. close #182 --- server/tasks/github/pull_request.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/server/tasks/github/pull_request.py b/server/tasks/github/pull_request.py index a8f15b46..663e7e0b 100644 --- a/server/tasks/github/pull_request.py +++ b/server/tasks/github/pull_request.py @@ -66,7 +66,7 @@ def on_pull_request_opened(event_dict: dict | list | None) -> list: repo_id=repo.id, pull_request_number=pr_info.number, title=pr_info.title, - description=pr_info.body, + description=pr_info.body[:1000], base=pr_info.base.ref, head=pr_info.head.ref, state=pr_info.state, From 1ad69b8f722e74d6965733ddaa1842f1e5f7d746 Mon Sep 17 00:00:00 2001 From: lloydzhou Date: Thu, 1 Feb 2024 11:34:41 +0800 Subject: [PATCH 2/2] hotfix: create issue error. close #179 --- server/tasks/lark/chat.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/server/tasks/lark/chat.py b/server/tasks/lark/chat.py index ca3d1177..a99be469 100644 --- a/server/tasks/lark/chat.py +++ b/server/tasks/lark/chat.py @@ -172,7 +172,7 @@ def create_issue( title = json.loads(parent_message["body"]["content"]).get("text") if not title: return send_chat_failed_tip( - "issue 标题为空", app_id, message_id, content, data, *args, bot=bot, **kwargs + "issue 标题为空", app_id, message_id, content, data, *args, **kwargs ) chat_id = data["event"]["message"]["chat_id"]