Skip to content

Commit

Permalink
chore(deps): upgrade dependencies (#1501)
Browse files Browse the repository at this point in the history
  • Loading branch information
Ja7ad committed Sep 23, 2024
1 parent fc101e4 commit 9306bef
Show file tree
Hide file tree
Showing 27 changed files with 249 additions and 246 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/coverage.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ jobs:
- name: Install Go
uses: actions/setup-go@v5
with:
go-version: '1.22.2'
go-version: '1.23.1'

- name: Checkout code
uses: actions/checkout@v4
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/deadlock.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ jobs:
- name: Install Go
uses: actions/setup-go@v5
with:
go-version: '1.22.2'
go-version: '1.23.1'

- name: Checkout code
uses: actions/checkout@v4
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/gui.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,13 +24,13 @@ jobs:
- name: Install Go
uses: actions/setup-go@v5
with:
go-version: '1.22.2'
go-version: '1.23.1'

- name: Build the binary
run: make build_gui

- name: Installing golangci-lint
run: go install github.com/golangci/golangci-lint/cmd/golangci-lint@v1.59
run: go install github.com/golangci/golangci-lint/cmd/golangci-lint@v1.61

- name: Lint check
run: BUILD_TAG=gtk make check
Expand All @@ -47,7 +47,7 @@ jobs:
- name: Install Go
uses: actions/setup-go@v5
with:
go-version: '1.22.2'
go-version: '1.23.1'

- name: Build the binary
run: make build_gui
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/linting.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,13 +17,13 @@ jobs:
- name: Install Go
uses: actions/setup-go@v5
with:
go-version: '1.22.2'
go-version: '1.23.1'

- name: Checkout code
uses: actions/checkout@v4

- name: Installing golangci-lint
run: go install github.com/golangci/golangci-lint/cmd/golangci-lint@v1.59
run: go install github.com/golangci/golangci-lint/cmd/golangci-lint@v1.61

- name: Formatting and linting the project
run: make check
10 changes: 5 additions & 5 deletions .github/workflows/releaser.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ jobs:
- name: Install Go
uses: actions/setup-go@v5
with:
go-version: '1.22.2'
go-version: '1.23.1'

- name: Create release files
run: bash ./.github/releasers/releaser_cli.sh
Expand Down Expand Up @@ -69,7 +69,7 @@ jobs:
- name: Install Go
uses: actions/setup-go@v5
with:
go-version: '1.22.2'
go-version: '1.23.1'

- name: Create release files
run: bash ./.github/releasers/releaser_gui_linux.sh
Expand Down Expand Up @@ -111,7 +111,7 @@ jobs:
- name: Install Go
uses: actions/setup-go@v5
with:
go-version: '1.22.2'
go-version: '1.23.1'

- name: Create release files
run: bash ./.github/releasers/releaser_gui_macos.sh
Expand Down Expand Up @@ -155,7 +155,7 @@ jobs:
- name: Install Go
uses: actions/setup-go@v5
with:
go-version: '1.22.2'
go-version: '1.23.1'

- name: Create release files
run: bash ./.github/releasers/releaser_gui_macos.sh
Expand Down Expand Up @@ -267,4 +267,4 @@ jobs:
with:
files: .github/releasers/pactus_downloader.sh
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
1 change: 1 addition & 0 deletions .github/workflows/semantic-pr.yml
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,7 @@ jobs:
version
wallet
grpc
proto
http
jsonrpc
nanomsg
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/testing.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ jobs:
- name: Install Go
uses: actions/setup-go@v5
with:
go-version: '1.22.2'
go-version: '1.23.1'

- name: Unit tests
run: make unit_test
5 changes: 3 additions & 2 deletions .golangci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ linters:
- errname
- errorlint
- exhaustive
- exportloopref
- copyloopvar
- forbidigo
- gci
- ginkgolinter
Expand Down Expand Up @@ -143,6 +143,7 @@ linters-settings:
excludes:
- G304
- G204
- G115

stylecheck:
# TODO: enable ST1000 (at least one file in a package should have a package comment)
Expand All @@ -159,7 +160,7 @@ linters-settings:
predeclared:
# Comma-separated list of predeclared identifiers to not report on.
# Default: ""
ignore: "len"
ignore: "len, min, max"
# Include method names and field names (i.e., qualified names) in checks.
# Default: false
q: true
Expand Down
2 changes: 1 addition & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM golang:1.22.2-alpine3.19 as builder
FROM golang:1.23.1-alpine3.19 as builder

RUN apk add --no-cache git gmp-dev build-base g++ openssl-dev
ADD . /pactus
Expand Down
9 changes: 4 additions & 5 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -14,16 +14,15 @@ all: build test
### Tools needed for development
devtools:
@echo "Installing devtools"
go install github.com/golangci/golangci-lint/cmd/golangci-lint@v1.59
go install github.com/grpc-ecosystem/grpc-gateway/v2/protoc-gen-grpc-gateway@v2.20
go install github.com/grpc-ecosystem/grpc-gateway/v2/protoc-gen-openapiv2@v2.20
go install github.com/golangci/golangci-lint/cmd/golangci-lint@v1.61
go install github.com/grpc-ecosystem/grpc-gateway/v2/protoc-gen-grpc-gateway@v2.22
go install github.com/grpc-ecosystem/grpc-gateway/v2/protoc-gen-openapiv2@v2.22
go install google.golang.org/protobuf/cmd/protoc-gen-go@v1.34
go install google.golang.org/grpc/cmd/protoc-gen-go-grpc@v1.4
go install github.com/NathanBaulch/protoc-gen-cobra@v1.2
go install github.com/pactus-project/protoc-gen-doc/cmd/protoc-gen-doc@v0.0.0-20240815105130-84e89d0170e4
go install github.com/bufbuild/buf/cmd/buf@v1.34
go install github.com/bufbuild/buf/cmd/buf@v1.42
go install mvdan.cc/gofumpt@latest
go install github.com/rakyll/statik@v0.1.7
go install github.com/pacviewer/jrpc-gateway/protoc-gen-jrpc-gateway@v0.3.2

########################################
Expand Down
2 changes: 1 addition & 1 deletion cmd/cmd.go
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ func PromptConfirm(label string) bool {
}
result, err := prompt.Run()
if err != nil {
if !errors.Is(promptui.ErrAbort, err) {
if !errors.Is(err, promptui.ErrAbort) {
PrintErrorMsgf("prompt error: %v", err)
} else {
PrintWarnMsgf("Aborted.")
Expand Down
8 changes: 4 additions & 4 deletions cmd/gtk/utils.go
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ func updateMessageDialog(dlg *gtk.MessageDialog) {

func showQuestionDialog(parent gtk.IWindow, msg string) bool {
dlg := gtk.MessageDialogNew(parent,
gtk.DIALOG_MODAL, gtk.MESSAGE_QUESTION, gtk.BUTTONS_YES_NO, msg)
gtk.DIALOG_MODAL, gtk.MESSAGE_QUESTION, gtk.BUTTONS_YES_NO, "%s", msg)
updateMessageDialog(dlg)
res := dlg.Run()
dlg.Destroy()
Expand All @@ -46,23 +46,23 @@ func showQuestionDialog(parent gtk.IWindow, msg string) bool {

func showInfoDialog(parent gtk.IWindow, msg string) {
dlg := gtk.MessageDialogNew(parent,
gtk.DIALOG_MODAL, gtk.MESSAGE_INFO, gtk.BUTTONS_OK, msg)
gtk.DIALOG_MODAL, gtk.MESSAGE_INFO, gtk.BUTTONS_OK, "%s", msg)
updateMessageDialog(dlg)
dlg.Run()
dlg.Destroy()
}

func showWarningDialog(parent gtk.IWindow, msg string) {
dlg := gtk.MessageDialogNew(parent,
gtk.DIALOG_MODAL, gtk.MESSAGE_WARNING, gtk.BUTTONS_OK, msg)
gtk.DIALOG_MODAL, gtk.MESSAGE_WARNING, gtk.BUTTONS_OK, "%s", msg)
updateMessageDialog(dlg)
dlg.Run()
dlg.Destroy()
}

func showErrorDialog(parent gtk.IWindow, msg string) {
dlg := gtk.MessageDialogNew(parent,
gtk.DIALOG_MODAL, gtk.MESSAGE_ERROR, gtk.BUTTONS_OK, msg)
gtk.DIALOG_MODAL, gtk.MESSAGE_ERROR, gtk.BUTTONS_OK, "%s", msg)
updateMessageDialog(dlg)
dlg.Run()
dlg.Destroy()
Expand Down
3 changes: 2 additions & 1 deletion crypto/hash/hash.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import (
"fmt"

"golang.org/x/crypto/blake2b"
"golang.org/x/crypto/ripemd160" //nolint:staticcheck // use to hash the public key to get the address
"golang.org/x/crypto/ripemd160" //nolint:all // used to hash the public key to generate the address.
)

const HashSize = 32
Expand All @@ -21,6 +21,7 @@ func Hash256(data []byte) []byte {
}

func Hash160(data []byte) []byte {
//nolint:all // used to hash the public key to generate the address.
h := ripemd160.New()
n, err := h.Write(data)
if err != nil {
Expand Down
Loading

0 comments on commit 9306bef

Please sign in to comment.