mirror of
https://github.com/Sea-Haven-Industries/open-swe.git
synced 2026-09-30 10:23:14 +00:00
feat: Include run and thread IDs in the issue comment (#378)
This commit is contained in:
parent
417c2e6650
commit
fa10a3e42a
1 changed files with 15 additions and 1 deletions
|
|
@ -52,6 +52,20 @@ const getPayload = (body: string): Record<string, any> | null => {
|
|||
}
|
||||
};
|
||||
|
||||
const createDevMetadataComment = (runId: string, threadId: string) => {
|
||||
return `<details>
|
||||
<summary>Dev Metadata</summary>
|
||||
${JSON.stringify(
|
||||
{
|
||||
runId,
|
||||
threadId,
|
||||
},
|
||||
null,
|
||||
2,
|
||||
)}
|
||||
</details>`;
|
||||
};
|
||||
|
||||
const getHeaders = (
|
||||
c: Context,
|
||||
): {
|
||||
|
|
@ -179,7 +193,7 @@ webhooks.on("issues.labeled", async ({ payload }) => {
|
|||
owner: issueData.owner,
|
||||
repo: issueData.repo,
|
||||
issue_number: issueData.issueNumber,
|
||||
body: `🤖 Open SWE has been triggered for this issue. Processing...\n\n${appUrlCommentText}`,
|
||||
body: `🤖 Open SWE has been triggered for this issue. Processing...\n\n${appUrlCommentText}\n\n${createDevMetadataComment(run.run_id, threadId)}`,
|
||||
},
|
||||
);
|
||||
} catch (error) {
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue