From a9bd48965e9363bb98f0076b76bcacd6e35c3809 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Christian=20Ku=C3=9Fowski?= Date: Sun, 18 May 2025 10:57:58 +0200 Subject: [PATCH] chore: Fix duplicates job --- .github/workflows/check_duplicates.yaml | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/.github/workflows/check_duplicates.yaml b/.github/workflows/check_duplicates.yaml index 276d40d24..279247d36 100644 --- a/.github/workflows/check_duplicates.yaml +++ b/.github/workflows/check_duplicates.yaml @@ -24,11 +24,13 @@ jobs: -d "{ \"contents\": [{ \"parts\":[ - {\"text\": \"Please compare issue title and body to possible duplications. If you think this issue could be a duplication, write a short response to this Github issue and link the possible duplication issues and ask the author ${{ env.author }} to check those. Otherwise just responde with an empty String.\n\nIssue title: ${{ env.title }}\nIssue body: ${{ env.body }}\n\nPossible duplications:\n$ISSUES\"} + {\"text\": \"Please compare issue title and body to possible duplications. If you think this issue could be a duplication, write a very short and nice response to this Github issue and link the possible duplication issues and ask the author ${{ env.author }} to check those. If you don't find any duplications, just reply with 'false'. \n\nIssue title: ${{ env.title }}\nIssue body: ${{ env.body }}\n\nPossible duplications:\n$ISSUES\"} ] }] }" | jq -r '.candidates[0].content.parts[0].text') echo $RESPONSE - gh issue comment ${{ github.event.issue.number }} --body "$RESPONSE" + if [ "$RESPONSE" != "false" ]; then + gh issue comment ${{ github.event.issue.number }} --body "$RESPONSE" + fi env: OPENAI_KEY: ${{ secrets.OPENAI_KEY }} \ No newline at end of file