Skip to content

Commit

Permalink
lints and remove some unnecessary CI jobs
Browse files Browse the repository at this point in the history
  • Loading branch information
czarcas7ic committed Jan 31, 2024
1 parent 5a57777 commit d0e0786
Show file tree
Hide file tree
Showing 9 changed files with 7 additions and 67 deletions.
22 changes: 0 additions & 22 deletions .github/workflows/dependencies-review.yml

This file was deleted.

17 changes: 0 additions & 17 deletions .github/workflows/labeler.yml

This file was deleted.

17 changes: 0 additions & 17 deletions .github/workflows/project.yml

This file was deleted.

3 changes: 1 addition & 2 deletions server/start.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ package server
// DONTCOVER

import (
"encoding/hex"
"errors"
"fmt"
"net"
Expand All @@ -24,8 +25,6 @@ import (
"google.golang.org/grpc"
"google.golang.org/grpc/credentials/insecure"

"encoding/hex"

"cosmossdk.io/tools/rosetta"
crgserver "cosmossdk.io/tools/rosetta/lib/server"
"github.com/cosmos/cosmos-sdk/client"
Expand Down
2 changes: 1 addition & 1 deletion snapshots/store.go
Original file line number Diff line number Diff line change
Expand Up @@ -260,7 +260,7 @@ func (s *Store) Save(
snapshotHasher := sha256.New()
chunkHasher := sha256.New()
for chunkBody := range chunks {
defer chunkBody.Close() //nolint:staticcheck
defer chunkBody.Close()

Check failure on line 263 in snapshots/store.go

View workflow job for this annotation

GitHub Actions / golangci-lint

File is not `gofumpt`-ed (gofumpt)
dir := s.pathSnapshot(height, format)
err = os.MkdirAll(dir, 0o755)
if err != nil {
Expand Down
2 changes: 1 addition & 1 deletion x/auth/vesting/types/period.go
Original file line number Diff line number Diff line change
Expand Up @@ -254,7 +254,7 @@ func ConjunctPeriods(startP, startQ int64, periodsP, periodsQ []Period) (startTi
}

// consumeBoth processes simultaneous events in P and Q and emits an
// event if the minumum of P and Q changes
// event if the minimum of P and Q changes
consumeBoth := func(nextTime int64) {
amountP = amountP.Add(periodsP[iP].Amount...)
amountQ = amountQ.Add(periodsQ[iQ].Amount...)
Expand Down
8 changes: 4 additions & 4 deletions x/auth/vesting/types/vesting_account.go
Original file line number Diff line number Diff line change
Expand Up @@ -617,8 +617,10 @@ func marshalYaml(i interface{}) (interface{}, error) {

// Clawback Vesting Account

var _ vestexported.VestingAccount = (*ClawbackVestingAccount)(nil)
var _ authtypes.GenesisAccount = (*ClawbackVestingAccount)(nil)
var (
_ vestexported.VestingAccount = (*ClawbackVestingAccount)(nil)
_ authtypes.GenesisAccount = (*ClawbackVestingAccount)(nil)
)

// NewClawbackVestingAccount returns a new ClawbackVestingAccount
func NewClawbackVestingAccount(
Expand Down Expand Up @@ -702,7 +704,6 @@ func CoinEq(a, b sdk.Coins) bool {
func (va ClawbackVestingAccount) Validate() error {
if va.GetStartTime() >= va.GetEndTime() {
return errors.New("vesting start-time must be before end-time")

}

lockupEnd := va.GetStartTime()
Expand Down Expand Up @@ -778,7 +779,6 @@ func (cga clawbackGrantAction) AddToAccount(ctx sdk.Context, rawAccount exported
}
cva.addGrant(ctx, cga.grantStartTime, cga.grantLockupPeriods, cga.grantVestingPeriods, cga.grantCoins)
return nil

}

func (va *ClawbackVestingAccount) AddGrant(ctx sdk.Context, action exported.AddGrantAction) error {
Expand Down
1 change: 0 additions & 1 deletion x/bank/keeper/supply_offset.go
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,6 @@ func (k BaseKeeper) GetPaginatedTotalSupplyWithOffsets(ctx sdk.Context, paginati
supply = supply.Add(sdk.NewCoin(denom, amount))
return nil
})

if err != nil {
return nil, nil, err
}
Expand Down
2 changes: 0 additions & 2 deletions x/staking/keeper/delegation.go
Original file line number Diff line number Diff line change
Expand Up @@ -847,7 +847,6 @@ func (k Keeper) Undelegate(
func (k Keeper) InstantUndelegate(
ctx sdk.Context, delAddr sdk.AccAddress, valAddr sdk.ValAddress, sharesAmount sdk.Dec,
) (sdk.Coins, error) {

validator, found := k.GetValidator(ctx, valAddr)
if !found {
return nil, types.ErrNoDelegatorForAddress
Expand All @@ -872,7 +871,6 @@ func (k Keeper) InstantUndelegate(
return nil, err
}
return res, nil

}

// CompleteUnbonding completes the unbonding of all mature entries in the
Expand Down

0 comments on commit d0e0786

Please sign in to comment.