Skip to content

Commit 8f9ddbd

Browse files
committed
feat: update go/tinygo versiont
1 parent e8fd742 commit 8f9ddbd

File tree

25 files changed

+175
-43
lines changed

25 files changed

+175
-43
lines changed

.github/workflows/go.yml

+5-5
Original file line numberDiff line numberDiff line change
@@ -17,9 +17,9 @@ jobs:
1717
run: sudo apt-get -o Acquire::Retries=3 update && sudo apt-get -o Acquire::Retries=3 install make git mesa-opencl-icd ocl-icd-opencl-dev wget -y && sudo apt upgrade -y
1818

1919
- name: Set up Go
20-
uses: actions/setup-go@v3
20+
uses: actions/setup-go@v4
2121
with:
22-
go-version: 1.18
22+
go-version: 1.20.3
2323

2424
- name: setup rust
2525
uses: actions-rs/toolchain@v1
@@ -42,9 +42,9 @@ jobs:
4242

4343
- name: install tinygo
4444
run: |
45-
wget https://github.com/tinygo-org/tinygo/releases/download/v0.25.0/tinygo_0.25.0_amd64.deb
46-
sudo dpkg -i tinygo_0.25.0_amd64.deb
47-
rm tinygo_0.25.0_amd64.deb
45+
wget https://github.com/tinygo-org/tinygo/releases/download/v0.27.0/tinygo_0.27.0_amd64.deb
46+
sudo dpkg -i tinygo_0.27.0_amd64.deb
47+
rm tinygo_0.27.0_amd64.deb
4848
4949
- name: Build
5050
run: |

.golangci.yml

+1
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,7 @@ issues:
3030
exclude-use-default: false
3131
exclude:
3232
- "\\w+Id should be \\w+ID"
33+
- "main redeclared in this block"
3334

3435
linters-settings:
3536
goconst:

Makefile

+6-1
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,10 @@ code-gen:
2020
cd ./examples/erc20 && fvm_go_sdk build
2121
cd ./examples/frc46token/gen && go run main.go
2222
cd ./examples/frc46token && fvm_go_sdk build
23+
cd ./examples/wallet/gen && go run main.go
24+
cd ./examples/wallet && fvm_go_sdk build
25+
cd ./examples/queuecall/gen && go run main.go
26+
cd ./examples/queuecall && fvm_go_sdk build
2327

2428
clean:
2529
rm -rf ./bin/*
@@ -36,6 +40,7 @@ test: build code-gen
3640
cd ./examples/frc46token && fvm_go_sdk test
3741
cd ./examples/frc46token/contract && go test --tags simulate
3842
cd ./examples/hellocontract/contract && go test --tags simulate
39-
43+
cd ./examples/queuecall/contract && go test --tags simulate
44+
cd ./examples/wallet/contract && go test --tags simulate
4045

4146
check: code-gen lint build-client-example test

README.MD

+1-1
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ Key features of `go-fvm-sdk` are...
1616

1717
## Install
1818

19-
Install [Go](https://go.dev/doc/install)v1.17 or above and [TinyGo](https://tinygo.org/getting-started/install/)v0.25 or above.
19+
Install [Go](https://go.dev/doc/install)v1.20.x or above and [TinyGo](https://tinygo.org/getting-started/install/)v0.27 or above.
2020

2121
*Note: latest Go or TinyGo versions may not be tested.*
2222

examples/erc20/client_example/go.mod

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
module client_example
22

3-
go 1.18
3+
go 1.20
44

55
replace (
66
erc20 => ../

examples/erc20/gen/go.mod

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
module gen
22

3-
go 1.18
3+
go 1.20
44

55
require (
66
erc20 v0.0.0-00010101000000-000000000000

examples/erc20/go.mod

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
module erc20
22

3-
go 1.18
3+
go 1.20
44

55
replace (
66
erc20 => ./

examples/frc46token/client_example/go.mod

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
module client_example
22

3-
go 1.18
3+
go 1.20
44

55
replace (
66
frc46token => ../

examples/frc46token/gen/go.mod

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
module gen
22

3-
go 1.18
3+
go 1.20
44

55
require (
66
frc46token v0.0.0-00010101000000-000000000000

examples/frc46token/go.mod

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
module frc46token
22

3-
go 1.18
3+
go 1.20
44

55
replace (
66
erc20 => ./

examples/hellocontract/client_example/go.mod

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
module client_example
22

3-
go 1.18
3+
go 1.20
44

55
replace (
66
github.com/ipfs-force-community/go-fvm-sdk => ../../../

examples/hellocontract/gen/go.mod

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
module gen
22

3-
go 1.18
3+
go 1.20
44

55
require (
66
github.com/ipfs-force-community/go-fvm-sdk/gen v0.0.0-00010101000000-000000000000

examples/hellocontract/go.mod

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,8 @@
11
module hellocontract
22

3-
go 1.18
3+
go 1.20
44

55
replace (
6-
hellocontract => ./
76
github.com/davecgh/go-spew => github.com/ipfs-force-community/go-spew v1.1.2-0.20220524052205-0034150c051a
87
github.com/filecoin-project/go-address => github.com/ipfs-force-community/go-address v0.0.7-0.20230207015848-7a27d889c267
98
github.com/ipfs-force-community/go-fvm-sdk => ../..
@@ -16,6 +15,7 @@ replace (
1615
github.com/stretchr/testify => github.com/ipfs-force-community/testify v1.7.1-0.20220616060316-ea4f53121ac3
1716
github.com/whyrusleeping/cbor-gen => github.com/ipfs-force-community/cbor-gen v0.0.0-20220421100448-dc345220256c
1817
golang.org/x/crypto => github.com/ipfs-force-community/crypto v0.0.0-20220523090957-2aff239c26f7
18+
hellocontract => ./
1919
lukechampine.com/blake3 => github.com/ipfs-force-community/blake3 v1.1.8-0.20220609024944-51450f2b2fc0
2020
)
2121

examples/queuecall/client/client_gen.go

+100
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

examples/queuecall/contract/queuecall.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -160,7 +160,7 @@ func (e *State) Execute(ctx context.Context, id *types.CborString) (*types.Recei
160160
return nil, err
161161
}
162162
if !found {
163-
return nil, fmt.Errorf("call %s not found", id)
163+
return nil, fmt.Errorf("call %v not found", id)
164164
}
165165

166166
timestamp, err := sdk.TipsetTimestamp(ctx)

examples/queuecall/entry_gen.go

+35-1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

examples/queuecall/gen/go.mod

+3-3
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,16 @@
11
module gen
22

3-
go 1.18
3+
go 1.20
44

55
require (
6-
queuecall v0.0.0-00010101000000-000000000000
76
github.com/ipfs-force-community/go-fvm-sdk/gen v0.0.0-00010101000000-000000000000
7+
queuecall v0.0.0-00010101000000-000000000000
88
)
99

1010
replace (
11-
queuecall => ../
1211
github.com/ipfs-force-community/go-fvm-sdk => ../../..
1312
github.com/ipfs-force-community/go-fvm-sdk/gen => ../../../gen
13+
queuecall => ../
1414
)
1515

1616
require (

examples/queuecall/go.mod

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
module queuecall
22

3-
go 1.18
3+
go 1.20
44

55
replace (
66
github.com/davecgh/go-spew => github.com/ipfs-force-community/go-spew v1.1.2-0.20220524052205-0034150c051a
@@ -32,6 +32,7 @@ require (
3232
github.com/ipfs-force-community/go-fvm-sdk v0.0.0-00010101000000-000000000000
3333
github.com/ipfs/go-block-format v0.0.3
3434
github.com/ipfs/go-ipld-cbor v0.0.6
35+
github.com/minio/blake2b-simd v0.0.0-20160723061019-3f5f724cb5b1
3536
github.com/stretchr/testify v1.8.0
3637
)
3738

@@ -99,7 +100,6 @@ require (
99100
github.com/libp2p/go-openssl v0.1.0 // indirect
100101
github.com/mattn/go-isatty v0.0.16 // indirect
101102
github.com/mattn/go-pointer v0.0.1 // indirect
102-
github.com/minio/blake2b-simd v0.0.0-20160723061019-3f5f724cb5b1 // indirect
103103
github.com/minio/sha256-simd v1.0.0 // indirect
104104
github.com/mr-tron/base58 v1.2.0 // indirect
105105
github.com/multiformats/go-base32 v0.0.4 // indirect

examples/wallet/gen/go.mod

+3-3
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,16 @@
11
module gen
22

3-
go 1.18
3+
go 1.20
44

55
require (
6-
wallet v0.0.0-00010101000000-000000000000
76
github.com/ipfs-force-community/go-fvm-sdk/gen v0.0.0-00010101000000-000000000000
7+
wallet v0.0.0-00010101000000-000000000000
88
)
99

1010
replace (
11-
wallet => ../
1211
github.com/ipfs-force-community/go-fvm-sdk => ../../..
1312
github.com/ipfs-force-community/go-fvm-sdk/gen => ../../../gen
13+
wallet => ../
1414
)
1515

1616
require (

examples/wallet/go.mod

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
module wallet
22

3-
go 1.18
3+
go 1.20
44

55
replace (
66
github.com/davecgh/go-spew => github.com/ipfs-force-community/go-spew v1.1.2-0.20220524052205-0034150c051a

0 commit comments

Comments
 (0)