forked from cosmos/cosmos-sdk
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'cosmos:main' into main
- Loading branch information
Showing
913 changed files
with
33,731 additions
and
17,756 deletions.
There are no files selected for viewing
This file contains 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 contains 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 contains 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,60 @@ | ||
name: Auto Assign Reviewers | ||
|
||
on: | ||
pull_request: | ||
types: [opened, edited, review_requested] | ||
|
||
jobs: | ||
assign-reviewers: | ||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- name: Check out the repository | ||
uses: actions/checkout@v4 | ||
|
||
- name: Assign reviewers as assignees | ||
uses: actions/github-script@v7 | ||
with: | ||
github-token: ${{ secrets.PRBOT_PAT }} | ||
script: | | ||
const { owner, repo } = context.repo; | ||
async function getCurrentPR() { | ||
if (context.payload.pull_request) { | ||
return context.payload.pull_request; | ||
} | ||
const allPRs = await github.rest.pulls.list({ | ||
owner, | ||
repo, | ||
state: 'open', | ||
}); | ||
return allPRs.data.find(pr => pr.head.sha === context.sha); | ||
} | ||
const pr = await getCurrentPR(); | ||
if (!pr) { | ||
console.log('No matching PR found.'); | ||
return; | ||
} | ||
console.log(`Processing PR #${pr.number}`); | ||
const reviewers = pr.requested_reviewers.map(reviewer => reviewer.login); | ||
if (reviewers.length === 0) { | ||
console.log('No reviewers found for this PR.'); | ||
return; | ||
} | ||
console.log(`Current reviewers: ${reviewers.join(', ')}`); | ||
await github.rest.issues.addAssignees({ | ||
owner, | ||
repo, | ||
issue_number: pr.number, | ||
assignees: reviewers, | ||
}); | ||
console.log(`Assigned ${reviewers.join(', ')} as assignees to PR #${pr.number}`); |
This file contains 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 contains 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 contains 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 contains 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 |
---|---|---|
|
@@ -20,7 +20,7 @@ jobs: | |
if: ${{ failure() }} | ||
steps: | ||
- name: Notify Slack on failure | ||
uses: rtCamp/[email protected].0 | ||
uses: rtCamp/[email protected].1 | ||
env: | ||
SLACK_WEBHOOK: ${{ secrets.SLACK_WEBHOOK }} | ||
SLACK_CHANNEL: sdk-sims | ||
|
This file contains 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,52 @@ | ||
name: PR Review Reminder | ||
|
||
on: | ||
schedule: | ||
- cron: '0 9 * * 1-5' # Every weekday at 9:00 AM UTC | ||
|
||
permissions: | ||
pull-requests: read | ||
|
||
jobs: | ||
pr-review: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout repository | ||
uses: actions/checkout@v4 | ||
|
||
- name: List open pull requests using GitHub Script | ||
uses: actions/github-script@v7 | ||
id: pr-list | ||
with: | ||
script: | | ||
const { data: pullRequests } = await github.rest.pulls.list({ | ||
owner: context.repo.owner, | ||
repo: context.repo.repo, | ||
state: 'open', | ||
}); | ||
let table = ''; | ||
pullRequests.forEach(pr => { | ||
const assignees = pr.assignees.length > 0 ? `Assignees: ${pr.assignees.map(assignee => assignee.login).join(', ')}` : 'No assignees'; | ||
table += pr.draft ? '' : ` | ||
Title: ${pr.title} | ||
Link: <${pr.html_url}> | ||
Assigness: ${assignees} | ||
`; | ||
}); | ||
return table; | ||
- name: Send Slack Reminder | ||
if: steps.pr-list.outputs.result != '' | ||
uses: rtCamp/[email protected] | ||
env: | ||
SLACK_WEBHOOK: ${{ secrets.SLACK_WEBHOOK }} | ||
SLACK_CHANNEL: pr-github | ||
SLACK_USERNAME: PR-Reminder | ||
MSG_MINIMAL: true | ||
SLACK_ICON_EMOJI: ":think:" | ||
SLACK_COLOR: good | ||
SLACKIFY_MARKDOWN: true | ||
SLACK_TITLE: Daily Pull Request Review Reminder | ||
SLACK_MESSAGE: | | ||
${{ steps.pr-list.outputs.result }} |
This file contains 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 |
---|---|---|
|
@@ -37,7 +37,7 @@ jobs: | |
runs-on: ubuntu-latest | ||
steps: | ||
- name: Notify Slack on success | ||
uses: rtCamp/[email protected].0 | ||
uses: rtCamp/[email protected].1 | ||
env: | ||
SLACK_WEBHOOK: ${{ secrets.SLACK_WEBHOOK }} | ||
SLACK_CHANNEL: cosmos-tech | ||
|
This file contains 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 |
---|---|---|
|
@@ -115,7 +115,7 @@ jobs: | |
|
||
- name: Notify Slack on success | ||
if: ${{ steps.last_status.outputs.last_status == 'failure' }} | ||
uses: rtCamp/[email protected].0 | ||
uses: rtCamp/[email protected].1 | ||
env: | ||
SLACK_WEBHOOK: ${{ secrets.SLACK_WEBHOOK }} | ||
SLACK_CHANNEL: sdk-sims | ||
|
@@ -134,7 +134,7 @@ jobs: | |
if: ${{ failure() }} | ||
steps: | ||
- name: Notify Slack on failure | ||
uses: rtCamp/[email protected].0 | ||
uses: rtCamp/[email protected].1 | ||
env: | ||
SLACK_WEBHOOK: ${{ secrets.SLACK_WEBHOOK }} | ||
SLACK_CHANNEL: sdk-sims | ||
|
This file contains 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 |
---|---|---|
|
@@ -115,7 +115,7 @@ jobs: | |
|
||
- name: Notify Slack on success | ||
if: ${{ steps.last_status.outputs.last_status == 'failure' }} | ||
uses: rtCamp/[email protected].0 | ||
uses: rtCamp/[email protected].1 | ||
env: | ||
SLACK_WEBHOOK: ${{ secrets.SLACK_WEBHOOK }} | ||
SLACK_CHANNEL: sdk-sims | ||
|
@@ -134,7 +134,7 @@ jobs: | |
if: ${{ failure() }} | ||
steps: | ||
- name: Notify Slack on failure | ||
uses: rtCamp/[email protected].0 | ||
uses: rtCamp/[email protected].1 | ||
env: | ||
SLACK_WEBHOOK: ${{ secrets.SLACK_WEBHOOK }} | ||
SLACK_CHANNEL: sdk-sims | ||
|
This file contains 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 |
---|---|---|
|
@@ -111,7 +111,7 @@ jobs: | |
|
||
- name: Notify Slack on success | ||
if: ${{ steps.last_status.outputs.last_status == 'failure' }} | ||
uses: rtCamp/[email protected].0 | ||
uses: rtCamp/[email protected].1 | ||
env: | ||
SLACK_WEBHOOK: ${{ secrets.SLACK_WEBHOOK }} | ||
SLACK_CHANNEL: sdk-sims | ||
|
@@ -135,7 +135,7 @@ jobs: | |
if: ${{ failure() }} | ||
steps: | ||
- name: Notify Slack on failure | ||
uses: rtCamp/[email protected].0 | ||
uses: rtCamp/[email protected].1 | ||
env: | ||
SLACK_WEBHOOK: ${{ secrets.SLACK_WEBHOOK }} | ||
SLACK_CHANNEL: sdk-sims | ||
|
This file contains 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 |
---|---|---|
|
@@ -44,7 +44,7 @@ jobs: | |
|
||
- name: Notify Slack on success | ||
if: ${{ steps.last_status.outputs.last_status == 'failure' }} | ||
uses: rtCamp/[email protected].0 | ||
uses: rtCamp/[email protected].1 | ||
env: | ||
SLACK_WEBHOOK: ${{ secrets.SLACK_WEBHOOK }} | ||
SLACK_CHANNEL: sdk-sims | ||
|
@@ -62,7 +62,7 @@ jobs: | |
if: ${{ failure() }} | ||
steps: | ||
- name: Notify Slack on failure | ||
uses: rtCamp/[email protected].0 | ||
uses: rtCamp/[email protected].1 | ||
env: | ||
SLACK_WEBHOOK: ${{ secrets.SLACK_WEBHOOK }} | ||
SLACK_CHANNEL: sdk-sims | ||
|
This file contains 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 |
---|---|---|
|
@@ -102,7 +102,7 @@ jobs: | |
|
||
- name: Notify Slack on success | ||
if: ${{ steps.last_status.outputs.last_status == 'failure' }} | ||
uses: rtCamp/[email protected].0 | ||
uses: rtCamp/[email protected].1 | ||
env: | ||
SLACK_WEBHOOK: ${{ secrets.SLACK_WEBHOOK }} | ||
SLACK_CHANNEL: sdk-sims | ||
|
@@ -126,7 +126,7 @@ jobs: | |
if: ${{ failure() }} | ||
steps: | ||
- name: Notify Slack on failure | ||
uses: rtCamp/[email protected].0 | ||
uses: rtCamp/[email protected].1 | ||
env: | ||
SLACK_WEBHOOK: ${{ secrets.SLACK_WEBHOOK }} | ||
SLACK_CHANNEL: sdk-sims | ||
|
This file contains 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 |
---|---|---|
|
@@ -46,7 +46,7 @@ jobs: | |
|
||
- name: Notify Slack on success | ||
if: ${{ steps.last_status.outputs.last_status == 'failure' }} | ||
uses: rtCamp/[email protected].0 | ||
uses: rtCamp/[email protected].1 | ||
env: | ||
SLACK_WEBHOOK: ${{ secrets.SLACK_WEBHOOK }} | ||
SLACK_CHANNEL: sdk-sims | ||
|
@@ -64,7 +64,7 @@ jobs: | |
if: ${{ failure() }} | ||
steps: | ||
- name: Notify Slack on failure | ||
uses: rtCamp/[email protected].0 | ||
uses: rtCamp/[email protected].1 | ||
env: | ||
SLACK_WEBHOOK: ${{ secrets.SLACK_WEBHOOK }} | ||
SLACK_CHANNEL: sdk-sims | ||
|
This file contains 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 contains 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 |
---|---|---|
|
@@ -109,3 +109,43 @@ jobs: | |
if: env.GIT_DIFF | ||
run: | | ||
cd server/v2/cometbft && go test -mod=readonly -race -timeout 30m -tags='ledger test_ledger_mock' | ||
test-system-v2: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v4 | ||
with: | ||
fetch-tags: true | ||
- uses: actions/setup-go@v5 | ||
with: | ||
go-version: "1.23" | ||
check-latest: true | ||
cache: true | ||
cache-dependency-path: | | ||
simapp/v2/go.sum | ||
systemtest/go.sum | ||
- uses: technote-space/[email protected] | ||
id: git_diff | ||
with: | ||
PATTERNS: | | ||
**/*.go | ||
go.mod | ||
go.sum | ||
**/go.mod | ||
**/go.sum | ||
**/Makefile | ||
Makefile | ||
- name: Install musl lib for simd (docker) binary | ||
if: env.GIT_DIFF | ||
run: | | ||
sudo apt-get install -y musl | ||
- name: system tests v2 | ||
if: env.GIT_DIFF | ||
run: | | ||
COSMOS_BUILD_OPTIONS=v2 make test-system | ||
- uses: actions/upload-artifact@v3 | ||
if: failure() | ||
with: | ||
name: "testnet-setup" | ||
path: ./systemtests/testnet/ | ||
retention-days: 3 |
This file contains 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 |
---|---|---|
|
@@ -119,3 +119,5 @@ linters-settings: | |
- regexpMust | ||
- appendAssign | ||
- ifElseChain | ||
unused: | ||
local-variables-are-used: false |
Oops, something went wrong.