diff --git a/entry b/entry index 110e56c..bac6a9d 100755 --- a/entry +++ b/entry @@ -83328,7 +83328,7 @@ function query({ // package.json var package_default = { name: "@pullfrog/action", - version: "0.0.150", + version: "0.0.151", type: "module", files: [ "index.js", @@ -98555,11 +98555,18 @@ async function deleteProgressComment(ctx) { if (!existingCommentId) { return false; } - await ctx.octokit.rest.issues.deleteComment({ - owner: ctx.owner, - repo: ctx.name, - comment_id: existingCommentId - }); + try { + await ctx.octokit.rest.issues.deleteComment({ + owner: ctx.owner, + repo: ctx.name, + comment_id: existingCommentId + }); + } catch (error41) { + if (error41 instanceof Error && error41.message.includes("Not Found")) { + } else { + throw error41; + } + } progressCommentId = null; progressCommentIdInitialized = true; progressCommentWasUpdated = true; diff --git a/mcp/comment.ts b/mcp/comment.ts index f529509..dcbbf8d 100644 --- a/mcp/comment.ts +++ b/mcp/comment.ts @@ -275,11 +275,20 @@ export async function deleteProgressComment(ctx: ToolContext): Promise return false; } - await ctx.octokit.rest.issues.deleteComment({ - owner: ctx.owner, - repo: ctx.name, - comment_id: existingCommentId, - }); + try { + await ctx.octokit.rest.issues.deleteComment({ + owner: ctx.owner, + repo: ctx.name, + comment_id: existingCommentId, + }); + } catch (error) { + // ignore 404 - comment already deleted + if (error instanceof Error && error.message.includes("Not Found")) { + // comment already deleted, continue + } else { + throw error; + } + } // reset state but mark as "updated" so ensureProgressCommentUpdated doesn't try to handle it progressCommentId = null; diff --git a/package.json b/package.json index 62d4b28..9119405 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@pullfrog/action", - "version": "0.0.150", + "version": "0.0.151", "type": "module", "files": [ "index.js",