Skip to content

Commit 15e356d

Browse files
authored
Expose-errors (#461)
* Bumped to golang 1.22 * Bumped golangci-lint to `v1.56.2` * Bumped mockery to `v2.42.0` * Bumped version to 1.0.3
1 parent 27dcaec commit 15e356d

File tree

5 files changed

+9
-11
lines changed

5 files changed

+9
-11
lines changed

Makefile

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
VERSION=v1.0.2
1+
VERSION=v1.0.3
22

33
ifndef GOBIN
44
ifndef GOPATH
@@ -48,9 +48,9 @@ cur-version:
4848
@echo -n $(VERSION)
4949

5050
$(GOBIN)/mockery:
51-
@go install github.com/vektra/mockery/v2@v2.39.1
51+
@go install github.com/vektra/mockery/v2@v2.42.0
5252
@mockery --version
5353

5454
$(GOBIN)/golangci-lint:
5555
@echo installing: golangci-lint
56-
@curl -sSfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh | sh -s -- -b $(GOBIN) v1.55.2
56+
@curl -sSfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh | sh -s -- -b $(GOBIN) v1.56.2

codefresh.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ steps:
1717
prepare_env_vars: &deps
1818
stage: Prepare
1919
title: prepare-env
20-
image: quay.io/codefresh/golang-ci-helper:1.21
20+
image: quay.io/codefresh/golang-ci-helper:1.22
2121
commands:
2222
- cf_export GO111MODULE=on
2323
- cf_export GOCACHE=/codefresh/volume/gocache # change gopath to codefresh shared volume

go.mod

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,6 @@
11
module github.com/codefresh-io/go-sdk
22

3-
go 1.21
4-
5-
toolchain go1.21.5
3+
go 1.22
64

75
require (
86
github.com/stretchr/testify v1.8.4

pkg/client/client.go

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ type (
4848
}
4949

5050
GraphqlErrorResponse struct {
51-
errors []GraphqlError
51+
Errors []GraphqlError
5252
concatenatedErrors string
5353
}
5454

@@ -186,7 +186,7 @@ func (e GraphqlErrorResponse) Error() string {
186186
}
187187

188188
var sb strings.Builder
189-
for _, err := range e.errors {
189+
for _, err := range e.Errors {
190190
sb.WriteString(fmt.Sprintln(err.Message))
191191
}
192192

@@ -219,7 +219,7 @@ func GraphqlAPI[T any](ctx context.Context, client *CfClient, query string, vari
219219
}
220220

221221
if wrapper.Errors != nil {
222-
err = &GraphqlErrorResponse{errors: wrapper.Errors}
222+
err = &GraphqlErrorResponse{Errors: wrapper.Errors}
223223
}
224224

225225
return result, err

pkg/mocks/http_mock.go

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)