From 8d1fa8147c57668dd30ab55c0391e677d61cba26 Mon Sep 17 00:00:00 2001 From: Sander Vocke Date: Sat, 16 Nov 2024 11:53:51 -0300 Subject: [PATCH] Add OpenHands-resolver action --- .github/workflows/openhands-resolver.yml | 34 ++++++++++++++++++++++++ 1 file changed, 34 insertions(+) create mode 100644 .github/workflows/openhands-resolver.yml diff --git a/.github/workflows/openhands-resolver.yml b/.github/workflows/openhands-resolver.yml new file mode 100644 index 000000000..6555e1505 --- /dev/null +++ b/.github/workflows/openhands-resolver.yml @@ -0,0 +1,34 @@ +name: Resolve Issue with OpenHands + +on: + issues: + types: [labeled] + pull_request: + types: [labeled] + issue_comment: + types: [created] + +permissions: + contents: write + pull-requests: write + issues: write + +jobs: + call-openhands-resolver: + if: | + ${{ + github.event.label.name == 'fix-me' || + (github.event_name == 'issue_comment' && + startsWith(github.event.comment.body, vars.OPENHANDS_MACRO || '@openhands-agent') && + (github.event.comment.author_association == 'OWNER' || github.event.comment.author_association == 'COLLABORATOR' || github.event.comment.author_association == 'MEMBER')) + }} + uses: All-Hands-AI/OpenHands/.github/workflows/openhands-resolver.yml@main + with: + macro: ${{ vars.OPENHANDS_MACRO || '@openhands-agent' }} + max_iterations: 50 + secrets: + PAT_TOKEN: ${{ secrets.PAT_TOKEN }} + PAT_USERNAME: ${{ secrets.PAT_USERNAME }} + LLM_MODEL: ${{ secrets.LLM_MODEL }} + LLM_API_KEY: ${{ secrets.LLM_API_KEY }} + LLM_BASE_URL: ${{ secrets.LLM_BASE_URL }}