Skip to content

Commit

Permalink
feat!: Nymlab (AVIDA Protocol) Prop31 Stage 1 implementation(#628) (#682
Browse files Browse the repository at this point in the history
)

* feat!: Nymlab Prop31 (#628)

* fix: LD_FLAGS -> LDFLAGS

* feat/resource: pump consensus version to v3, update ibcModule, types + keeper

* tests/resource/ibc: OnChanOpen* tests

* chore: bump x/resource pb version 2->3

* wip: comment out migration to test build

* wip test

* chore: store resource v2 types

* tests/resource: ibc on recv packets

* feat/resource: add more detailed errors

* feat: starship test base

* feat/resources: resourcePortId as const /proto revert

* chore: remove deadcode

* feat: upgrade and migration

* fix: update app migrator for keeper

* wip: conflict

* chore: bump version and remove test in go.work

* chore: make sure ibc-app-version aligns with consensus

* chore: move interchain tests out of repo

* fix: ibc connection

---------

Co-authored-by: bwty <[email protected]>
Co-authored-by: j0nl1 <[email protected]>
Co-authored-by: Tasos Derisiotis <[email protected]>
Co-authored-by: Belsy <[email protected]>

* chore: Align with overall codebase + cleanups

* chore: Removed incompatible cache based setup

* chore: Resolved lint issues

* test: Bump upgrade test suite in prep for v2 major (#683)

* test: Transition to v2 + relevant indicative upgrade tests

* Overall format

* Added distinction on build flags + binary paths

* Switched to ordered container

* Updated relative path references

* Switched to url-safe

* Added padding where relevant

* Cleanup

* Switch to legacy literals

* Removed optional prop info

* Added sample realistic upgrade info

* Added checksum indication

* Removed legacy querier

* Bumped extra blocks

* Streamline expected payloads as proto JSON

* Cleanup

* Added intermittent EOL

* Cleanup

* fix: Add msg signature normalisation for deactivate did doc msg (#685)

* Add msg signature normalization for deactivate did doc msg

* Update MD rules

* Pin GoReleaser

* Pin GoReleaser v1.22.1

* Removed pin

---------

Co-authored-by: Tasos Derisiotis <[email protected]>

* build(deps): bump cosmos-sdk to v047 (#690)

* bump cosmos sdk

* code clean up

* clean

* fix proto-gen

* fix build

* !build(deps): fix build (#692)

* code clean up

* clean

* fix proto-gen

* fix build

* fix build

* fix build

* fix makefile

* fix chain

* fix app.go

* protocgen

* fix ci job

* fix build

* fixes

* review changes

* review changes

* chore: delete simapp package

* feat!: `x/did` and `x/resource`  module changes according to sdk v0.47 (#691)

* chore: did module upgrade changes

* fix lint

* go mod tidy

* remove commented code

* remove commented line

* update golang version

* fix lint

* fix lint

* try fix lint

* fix lint

* fix proto-gen

* add logs

* add log

* update

* fix lint

* fix proto-gen

* add perms

* fix build

* lint fix

* lint:gofmt enabled in ci

* try fixing lint

* try fix lint

* reveert

* try lint

* try fix lint

* fix lint

* lint fixes

* fix permissions

* fix releases

* revert

* review changes

* try fixing jobs

* try fixing jobs

* add logs

* add change perms

* revert

* chore: appmodule missing methods added

* try fix build

* add perms

* chore: missing method with attrition variable

* Update .github/linters/.golangci.yaml

Co-authored-by: Akhil Kumar P <[email protected]>

* Update scripts/protocgen.sh

Co-authored-by: Akhil Kumar P <[email protected]>

* review changes

---------

Co-authored-by: atheesh <[email protected]>
Co-authored-by: atheeshp <[email protected]>
Co-authored-by: Akhil Kumar P <[email protected]>

* proto-gen

* ci: Go releaser fix (#689) (#693)

* fix: release permission check

* try fix go releaser

* touch

* touch

* release check

* try fix

* release check

* fix swagger

* fix swagger gen

* fix

* release check

* update goreleaser config

* revert changes

* fix: ante handler ibc fix

* review changes

---------

Co-authored-by: atheesh <[email protected]>
Co-authored-by: akhilkumarpilli <[email protected]>

* fix: failing tests (#694)

* fix: release permission check

* try fix go releaser

* touch

* touch

* release check

* try fix

* release check

* fix swagger

* fix swagger gen

* fix

* release check

* update goreleaser config

* revert changes

* fix: ante handler ibc fix

* fix tests

* remove test.sh

* fix: integration test check

* keys check

* try fix start script

* fix jq

* remove logs

* fix import keys

* revert

* fix: tx msgServer fixes

* fix: keys check

* fix import keys

* revert

* fix tests

* fix panic

* fix build

* add wait timer

* reduce timer

* increase time

* fix: upgrade test fixes for old binary

* fix: old binary setup.sh

* fix: localnet dir path fix

* fix: upgrade test fix

* add missing post hand;er

* fix tests

* add timer

* add post handler

* add handler

* fix test

* add timer

* try increasing the time

* decrease the timer

* fix tests

* fix lint

* fix lint

* fix lint

* fix tests

* fix

* increase time

* fix: upgrade test moduleVersion fix

* fix: upgrade test fix

* fix: test docker ps

* fix: checking docker before post test

* fix: parse fix

* fix: docker check

* fix: docker keys check

* revert: entrypoint revert

* fix: docker ps check with logs

* fix: upgrade handler with consensus, crisis

* test: docker ps logs check

* test: SendEnabled param fix

* lint: gofumpt fix

* chore: consensus module included

* chore: bank subspace fix

* lint: golang ci fix

* test: feeparam register fix

* fix: bankType param fix

* ci: Update CI workflows (#695)

* update package lock

* Update .releaserc.json

* Bump setup-go

* Update dependabot.yml

* Update pull-request.yml

* Update release workflows

* Uploaded download/upload artifact

* Ignore twitter links

* archives.rlcp is deprecated

* Standardise quotes

* ci: Resolved Integration, Upgrade test suites (#696)

* Debug

* Switch to param key table

* Skip deprecation staticcheck

* Added crisis param key table

* Added distribution parameter key table

* Added gov parameter key table

* Added mint parameter key table

* Added slashing parameter key table

* Added staking parameter key table

* Removed exclusion

* Added auth parameter key table

* Added consensus module expected definition

* Added legacy gov router registration

* Added artificial idle time against sequence mismatch

* Additional idle time

* Run sequential

* Switch to utilise other op acc

* Additional overhead

* Re-order against sequence mismatch

* Removed idle time

* Added polling for optimistic tx submission

* Additional overhead

---------

Co-authored-by: deepan95dev <[email protected]>
Co-authored-by: akhilkumarpilli <[email protected]>
Co-authored-by: Ankur Banerjee <[email protected]>
Co-authored-by: Tasos Derisiotis <[email protected]>

* chore: removed commented lines

* deps: updated bufbuild version + idle time extended in integration test

* fix: ibc defi tests (#697)

* fix ibc tests

* fix ibc tests

* add keys to gitignore

* remove unwanted line

* update ibc handler

* add comments

* fix: state sync fixes using upgrade handler (#708)

* test: state-sync upgrade handler fix

* fix: state sync param fix

---------

Co-authored-by: Deepan kumar <[email protected]>
Co-authored-by: Akhil Kumar P <[email protected]>
Co-authored-by: akhilkumarpilli <[email protected]>
Co-authored-by: deepan95dev <[email protected]>
Co-authored-by: Ankur Banerjee <[email protected]>
Co-authored-by: Tasos Derisiotis <[email protected]>

---------

Co-authored-by: Ankur Banerjee <[email protected]>
Co-authored-by: bwty <[email protected]>
Co-authored-by: j0nl1 <[email protected]>
Co-authored-by: Belsy <[email protected]>
Co-authored-by: Andrew Nikitin <[email protected]>
Co-authored-by: atheeshp <[email protected]>
Co-authored-by: Deepan kumar <[email protected]>
Co-authored-by: Akhil Kumar P <[email protected]>
Co-authored-by: akhilkumarpilli <[email protected]>
Co-authored-by: deepan95dev <[email protected]>
  • Loading branch information
11 people authored Mar 13, 2024
1 parent 513dac8 commit be1135a
Show file tree
Hide file tree
Showing 325 changed files with 4,983 additions and 22,174 deletions.
13 changes: 10 additions & 3 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,20 +4,27 @@

version: 2
updates:

# Maintain dependencies for GitHub Actions
- package-ecosystem: "github-actions"
target-branch: "develop"
directory: "/"
schedule:
interval: "weekly"
interval: "weekly"
ignore:
- dependency-name: "*"
update-types:
- version-update:semver-patch

# Maintain dependencies for NPM
- package-ecosystem: "npm"
target-branch: "develop"
directory: "/"
schedule:
interval: "weekly"
interval: "weekly"
ignore:
- dependency-name: "*"
update-types:
- version-update:semver-patch

# Maintain dependencies for Docker
- package-ecosystem: "docker"
Expand Down
28 changes: 24 additions & 4 deletions .github/linters/.golangci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ linters:
- goconst
- gocritic
- gofumpt
- gofmt
- goimports
- gosimple
- govet
Expand All @@ -25,7 +26,12 @@ linters:
- typecheck
- unconvert
- unused


issues:
exclude-rules:
- text: "ST1003:"
linters:
- stylecheck

linters-settings:
dogsled:
Expand All @@ -42,8 +48,8 @@ linters-settings:
- badCall # Remove this after CI workflow PR

gofumpt:
lang-version: "1.18"
lang-version: "1.21"

misspell:
ignore-words:
- cheqd
Expand All @@ -52,7 +58,7 @@ linters-settings:

stylecheck:
# Select the Go version to target.
go: "1.18"
go: "1.21"
# STxxxx checks in https://staticcheck.io/docs/configuration/options/#checks
# Default: ["*"]
checks: ["all"]
Expand All @@ -62,3 +68,17 @@ linters-settings:
- "github.com/onsi/gomega"
# https://staticcheck.io/docs/configuration/options/#initialisms
initialisms: ["ACL", "API", "ASCII", "CPU", "CSS", "DNS", "EOF", "GUID", "HTML", "HTTP", "HTTPS", "ID", "IP", "JSON", "QPS", "RAM", "RPC", "SLA", "SMTP", "SQL", "SSH", "TCP", "TLS", "TTL", "UDP", "UI", "GID", "UID", "UUID", "URI", "URL", "UTF8", "VM", "XML", "XMPP", "XSRF", "XSS", "SIP", "RTP", "AMQP", "DB", "TS"]

depguard:
rules:
main:
files:
- $all
list-mode: lax
allow: "*"

goconst:
min-occurrences: 5
ignore-tests: true
ignore-strings: "echo '"

16 changes: 13 additions & 3 deletions .github/linters/mlc_config.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,12 @@
{
"aliveStatusCodes": [0, 200, 206, 403, 501, 999],
"aliveStatusCodes": [
0,
200,
206,
403,
501,
999
],
"replacementPatterns": [
{
"pattern": "\" %}",
Expand All @@ -12,8 +19,11 @@
],
"ignorePatterns": [
{
"pattern": "^https://resolver.cheqd.net/"
"pattern": "^https://resolver.cheqd.net/"
},
{
"pattern": "^https://twitter.com/"
}
],
"retryOn429": true
}
}
10 changes: 7 additions & 3 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,10 @@ on:
defaults:
run:
shell: bash
permissions:
contents: write
packages: read
checks: write


jobs:
Expand All @@ -15,7 +19,7 @@ jobs:
steps:
- uses: actions/checkout@v4

- uses: actions/setup-go@v4
- uses: actions/setup-go@v5
with:
go-version-file: ./go.mod
cache: true
Expand All @@ -28,7 +32,7 @@ jobs:
args: build --clean --snapshot --single-target

- name: Store artifact
uses: actions/upload-artifact@v3
uses: actions/upload-artifact@v4
with:
name: cheqd-noded
path: dist/linux-amd64_linux_amd64_v1/cheqd-noded
Expand Down Expand Up @@ -75,7 +79,7 @@ jobs:
cache-to: type=gha,mode=min

- name: Upload Docker build image
uses: actions/upload-artifact@v3
uses: actions/upload-artifact@v4
with:
name: cheqd-node-build.tar
path: /tmp/cheqd-node-build.tar
2 changes: 1 addition & 1 deletion .github/workflows/codeql.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ jobs:
languages: 'go'
queries: security-and-quality

- uses: actions/setup-go@v4
- uses: actions/setup-go@v5
with:
go-version: 1.18

Expand Down
27 changes: 13 additions & 14 deletions .github/workflows/lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,17 +11,16 @@ jobs:
sh-euox-pipefail-check:
name: "Shell pipefail check"
runs-on: ubuntu-20.04

steps:
- uses: actions/checkout@v4

- name: Run 'set -euox pipefail' check
run: bash ./.github/scripts/ensure_set_euox_pipefail.sh

md-link-check:
name: "Broken Markdown links"
runs-on: ubuntu-20.04

steps:
- uses: actions/checkout@v4

Expand All @@ -30,43 +29,43 @@ jobs:
with:
config-file: '.github/linters/mlc_config.json'
use-quiet-mode: 'yes'

go-lint:
# We can't use VALIDATE_GO from super linter because of this issue:
# https://github.com/github/super-linter/issues/143
name: "Golang"
runs-on: ubuntu-20.04

steps:
- uses: actions/checkout@v4

- uses: actions/setup-go@v4
- uses: actions/setup-go@v5
with:
go-version-file: ./go.mod
cache: true
cache: false # temporarily off, as golangci-lint doesn't align 100% with cached setup-go@v4, see: https://github.com/golangci/golangci-lint-action/issues/807

- name: Run golangci-lint
uses: golangci/golangci-lint-action@v3
with:
version: v1.49.0
version: v1.56.2
args: --config .github/linters/.golangci.yaml

proto-lint:
name: "Protobuf"
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v4

# Install the `buf` CLI
- uses: bufbuild/buf-setup-action@v1.27.0
- uses: bufbuild/buf-setup-action@v1.28.1
with:
github_token: ${{ secrets.GITHUB_TOKEN }}

# Lint
- uses: bufbuild/buf-lint-action@v1
with:
input: proto

# Breaking change detection
- uses: bufbuild/buf-breaking-action@v1
continue-on-error: true
Expand All @@ -77,7 +76,7 @@ jobs:
super-lint:
name: "Super Linter"
runs-on: ubuntu-20.04

steps:
- uses: actions/checkout@v4
with:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/pull-request.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ jobs:
steps:
- uses: actions/checkout@v4

- uses: amannn/action-semantic-pull-request@v5.3.0
- uses: amannn/action-semantic-pull-request@v5.4.0
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
Expand Down
24 changes: 10 additions & 14 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,6 @@ on:
defaults:
run:
shell: bash
permissions:
contents: write
packages: write


jobs:
# Super Linter only runs on diffs in PRs
Expand All @@ -17,7 +13,7 @@ jobs:
super-lint:
name: "Super Linter"
runs-on: ubuntu-20.04

steps:
- uses: actions/checkout@v4
with:
Expand Down Expand Up @@ -48,23 +44,23 @@ jobs:
outputs:
RELEASE_VERSION: ${{ steps.set-version.outputs.RELEASE_VERSION }}
EXECUTE_RELEASE: ${{ steps.execute-release.outputs.EXECUTE_RELEASE }}

steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0 # Required to fetch version
persist-credentials: false

# Node.js setup is needed to run Semantic Release
- uses: actions/setup-node@v3
- uses: actions/setup-node@v4
with:
node-version: 18
node-version: 20
cache: 'npm'

# Required for short-lived token provided to Semantic Release
- name: "Obtain Github App token"
id: app-token
uses: getsentry/action-github-app-token@v2.0.0
uses: getsentry/action-github-app-token@v3.0.0
with:
app_id: ${{ secrets.BOT_APP_ID }}
private_key: ${{ secrets.BOT_APP_PRIVATE_KEY }}
Expand All @@ -81,7 +77,7 @@ jobs:
- name: Check whether to execute release
id: execute-release
run: |
tag=$(git describe --tags --exact-match)
tag=$(git describe --tags --exact-match) || exit 0
if [[ $tag =~ ^v ]]; then
echo "EXECUTE_RELEASE=true" >> "$GITHUB_OUTPUT"
else
Expand All @@ -103,20 +99,20 @@ jobs:
needs: [ super-lint, release-guard ]
# Only run if release-guard outputs EXECUTE_RELEASE=true
if: needs.release-guard.outputs.EXECUTE_RELEASE == 'true'

steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0 # Required to fetch version
persist-credentials: false

- uses: actions/setup-go@v4
- uses: actions/setup-go@v5
with:
go-version-file: ./go.mod
cache: true

# Setup for pushing to Buf.build later
- uses: bufbuild/buf-setup-action@v1.27.0
- uses: bufbuild/buf-setup-action@v1.28.1
with:
github_token: ${{ secrets.GITHUB_TOKEN }}

Expand Down Expand Up @@ -162,7 +158,7 @@ jobs:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}

- name: Configure Docker image metadata
id: meta
uses: docker/metadata-action@v5
Expand Down
Loading

0 comments on commit be1135a

Please sign in to comment.