Skip to content

Commit

Permalink
Merge branch 'main' into feat/plugin-system-improvements-versioning
Browse files Browse the repository at this point in the history
  • Loading branch information
Pantani authored Oct 18, 2023
2 parents 9c3336e + 4739faf commit a641547
Show file tree
Hide file tree
Showing 8 changed files with 21 additions and 21 deletions.
17 changes: 6 additions & 11 deletions .github/workflows/test-integration.yml
Original file line number Diff line number Diff line change
Expand Up @@ -42,22 +42,17 @@ jobs:
go.sum
**/testdata/**
- uses: actions/cache@v3
if: env.GIT_DIFF
with:
path: |
~/.cache/go-build
~/go/pkg/mod
key: ${{ runner.os }}-go-${{ hashFiles('**/go.sum') }}
restore-keys: |
${{ runner.os }}-go-
- uses: actions/setup-go@v4
if: env.GIT_DIFF
with:
go-version: '1.21'
go-version: 'stable'

- name: Run Integration Tests
if: env.GIT_DIFF
run: GOSUMDB=off go test -v -timeout 120m ./integration/${{ matrix.test-path }}
env:
GOTOOLCHAIN: local+path
GOSUMDB: off
run: go test -v -timeout 120m ./integration/${{ matrix.test-path }}

status:
runs-on: ubuntu-latest
Expand Down
3 changes: 3 additions & 0 deletions .github/workflows/test-lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,10 +24,13 @@ jobs:
**/*.go
go.mod
go.sum
- uses: actions/setup-go@v4
if: env.GIT_DIFF
with:
go-version-file: go.mod
cache: false

- uses: golangci/golangci-lint-action@v3
if: env.GIT_DIFF
with:
Expand Down
1 change: 1 addition & 0 deletions changelog.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@

### Changes

- [#3701](https://github.com/ignite/cli/pull/3701) Bump `go` version to 1.21
- [#3621](https://github.com/ignite/cli/pull/3621) Change `pkg/availableport` to allow custom parameters in `Find` function and handle duplicated ports
- [#3559](https://github.com/ignite/cli/pull/3559) Bump network plugin version to `v0.1.1`
- [#3581](https://github.com/ignite/cli/pull/3581) Bump cometbft and cometbft-db in the template
Expand Down
2 changes: 1 addition & 1 deletion ignite/pkg/cache/cache.go
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,7 @@ func (c Cache[T]) Put(key string, value T) error {
func (c Cache[T]) Get(key string) (val T, err error) {
db, err := openDB(c.storage.storagePath)
if err != nil {
return
return val, err
}
defer db.Close()

Expand Down
10 changes: 5 additions & 5 deletions ignite/pkg/cosmosanalysis/app/app.go
Original file line number Diff line number Diff line change
Expand Up @@ -220,25 +220,25 @@ func newUnexpectedTypeErr(n any) error {
func findBasicManagerRegistrations(n ast.Node, pkgDir string, fileImports map[string]string) (packages []string, err error) {
callExprType, ok := n.(*ast.CallExpr)
if !ok {
return
return packages, err
}

selectorExprType, ok := callExprType.Fun.(*ast.SelectorExpr)
if !ok {
return
return packages, err
}

identExprType, ok := selectorExprType.X.(*ast.Ident)
if !ok {
return
return packages, err
}
basicModulePkgName := findBasicManagerPkgName(fileImports)
if basicModulePkgName == "" {
// cosmos-sdk/types/module is not imported in this file, skip
return
return packages, err
}
if identExprType.Name != basicModulePkgName || selectorExprType.Sel.Name != "NewBasicManager" {
return
return packages, err
}

// Node "n" defines the call to NewBasicManager, let's loop on its args to discover modules
Expand Down
5 changes: 3 additions & 2 deletions ignite/pkg/placeholder/error.go
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
package placeholder

import (
"errors"
"fmt"
"strings"

Expand All @@ -18,8 +19,8 @@ type MissingPlaceholdersError struct {

// Is true if both errors have the same list of missing placeholders.
func (e *MissingPlaceholdersError) Is(err error) bool {
other, ok := err.(*MissingPlaceholdersError) //nolint:errorlint
if !ok {
var other *MissingPlaceholdersError
if !errors.As(err, &other) {
return false
}
if len(other.missing) != len(e.missing) {
Expand Down
2 changes: 1 addition & 1 deletion ignite/services/plugin/template/go.mod.plush
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
module <%= ModuleName %>

go 1.20
go 1.21

require (
github.com/hashicorp/go-plugin v1.4.9
Expand Down
2 changes: 1 addition & 1 deletion ignite/templates/app/files/go.mod.plush
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
module <%= ModulePath %>

go 1.20
go 1.21

require (
cosmossdk.io/api v0.3.1
Expand Down

0 comments on commit a641547

Please sign in to comment.