Skip to content

Commit

Permalink
adding logic for comment in PR in edge case with error ChangesetFileM…
Browse files Browse the repository at this point in the history
…ustNotExistWithSkipEntryOption

Signed-off-by: Samuel Valdes Gutierrez <[email protected]>
  • Loading branch information
BigSamu committed Apr 12, 2024
1 parent a9f71f6 commit 876b13d
Showing 1 changed file with 9 additions and 1 deletion.
10 changes: 9 additions & 1 deletion src/utils/handlers.utils.js
Original file line number Diff line number Diff line change
Expand Up @@ -198,7 +198,15 @@ export const handleSkipEntry = async (
// For manual changeset creation, add failed label to PR and throw error
else {
console.error("Error processing 'skip' entry option in changelog");
throw new ChangesetFileMustNotExistWithSkipEntryOption(prData.prNumber);
const error = new ChangesetFileMustNotExistWithSkipEntryOption(prData.prNumber);
const commentInput = error;
await handlePullRequestComment(
octokit,
prData,
commentInput,
"changeset-check-error"
);
throw error;
}
}

Expand Down

0 comments on commit 876b13d

Please sign in to comment.