Repository navigation
ci: review uci's own pull requests with seidroid, retire ai-review #120
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
bdchatham
wants to merge
2
commits into
main
Choose a base branch
from
ci/seidroid-review
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,96 @@ | ||
| # Wiring only. The review logic is this repository's seidroid-review.yml, called at a | ||
| # released commit so a pull request that changes it is reviewed by the last release, | ||
| # not by itself. The reviewer binary is sei-internal-skills' sei-agent-driver. | ||
| # | ||
| # @seidroid review review this pull request | ||
| # @seidroid review close destroy this pull request's session now | ||
| name: seidroid review | ||
|
|
||
| on: | ||
| issue_comment: | ||
| types: [created] | ||
| pull_request_review_comment: | ||
| types: [created] | ||
| pull_request_review: | ||
| types: [submitted] | ||
| pull_request: | ||
| types: [opened, ready_for_review, synchronize, reopened, closed] | ||
|
|
||
| permissions: {} | ||
|
|
||
| jobs: | ||
| # A run Dependabot triggers gets Dependabot's secrets only, so the review would fail | ||
| # on the missing machine credential; it is skipped. A person's push, or | ||
| # `@seidroid review`, on a Dependabot pull request still reviews it. | ||
| seidroid-review: | ||
| if: >- | ||
| (github.event_name == 'pull_request' && | ||
| github.event.action != 'closed' && | ||
| github.actor != 'dependabot[bot]') || | ||
| (((github.event_name == 'issue_comment' && | ||
| github.event.issue.pull_request != null) || | ||
| github.event_name == 'pull_request_review_comment' || | ||
| github.event_name == 'pull_request_review') && | ||
| contains(github.event.comment.body || github.event.review.body, | ||
| '@seidroid review') && | ||
| !contains(github.event.comment.body || github.event.review.body, | ||
| '@seidroid review close')) | ||
| uses: sei-protocol/uci/.github/workflows/seidroid-review.yml@0dc48cfb58b6c88f528b6def9784524d444ed0f6 # v0.0.26 | ||
| permissions: | ||
| contents: read | ||
| pull-requests: write | ||
| checks: write | ||
| issues: write | ||
| secrets: | ||
| OMNIGENT_MACHINE_CLIENT_SECRET: ${{ secrets.OMNIGENT_MACHINE_CLIENT_SECRET }} | ||
| SEIDROID_APP_ID: ${{ secrets.PLATFORM_CODE_AGENT_APP_ID }} | ||
| SEIDROID_APP_PRIVATE_KEY: ${{ secrets.PLATFORM_CODE_AGENT_APP_PK }} | ||
| with: | ||
| mode: review | ||
| approve-on-success: true | ||
| allowed-team: 'sei-protocol/sei-core' | ||
|
|
||
| # Anchored, unlike the review job's `contains`: the reusable workflow does not | ||
| # re-derive the mode from the body, so a comment that starts with `@seidroid review` | ||
| # and quotes the close command later must not reach this destructive job. Such a | ||
| # comment runs neither job. | ||
| seidroid-review-close: | ||
| if: >- | ||
| github.event_name == 'issue_comment' && | ||
| github.event.issue.pull_request != null && | ||
| startsWith(github.event.comment.body, '@seidroid review close') | ||
| uses: sei-protocol/uci/.github/workflows/seidroid-review.yml@0dc48cfb58b6c88f528b6def9784524d444ed0f6 # v0.0.26 | ||
| permissions: | ||
| contents: read | ||
| pull-requests: write | ||
| checks: write | ||
| issues: write | ||
| secrets: | ||
| OMNIGENT_MACHINE_CLIENT_SECRET: ${{ secrets.OMNIGENT_MACHINE_CLIENT_SECRET }} | ||
| SEIDROID_APP_ID: ${{ secrets.PLATFORM_CODE_AGENT_APP_ID }} | ||
| SEIDROID_APP_PRIVATE_KEY: ${{ secrets.PLATFORM_CODE_AGENT_APP_PK }} | ||
| with: | ||
| mode: close | ||
| allowed-team: 'sei-protocol/sei-core' | ||
|
|
||
| # Skipped when Dependabot closes its own pull request, because that run lacks the | ||
| # secrets. After a manual review of a Dependabot pull request, comment | ||
| # `@seidroid review close` if Dependabot may supersede it. A fork pull request gets | ||
| # no secrets either, so close it the same way before merging. | ||
| seidroid-review-reclaim: | ||
| if: >- | ||
| github.event_name == 'pull_request' && | ||
| github.event.action == 'closed' && | ||
| github.actor != 'dependabot[bot]' | ||
| uses: sei-protocol/uci/.github/workflows/seidroid-review.yml@0dc48cfb58b6c88f528b6def9784524d444ed0f6 # v0.0.26 | ||
| permissions: | ||
| contents: read | ||
| pull-requests: write | ||
| checks: write | ||
| issues: write | ||
| secrets: | ||
| OMNIGENT_MACHINE_CLIENT_SECRET: ${{ secrets.OMNIGENT_MACHINE_CLIENT_SECRET }} | ||
| SEIDROID_APP_ID: ${{ secrets.PLATFORM_CODE_AGENT_APP_ID }} | ||
| SEIDROID_APP_PRIVATE_KEY: ${{ secrets.PLATFORM_CODE_AGENT_APP_PK }} | ||
| with: | ||
| mode: close | ||
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.