Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

v1.4.0 (CosmWasm v1) #930

Merged
merged 577 commits into from
Sep 12, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
577 commits
Select commit Hold shift + click to select a range
4058c9e
Channel close tests
liorbond Aug 28, 2022
c32ba0b
Merge remote-tracking branch 'origin/cw-1-ibc-receive-hooks' into esh…
liorbond Aug 29, 2022
a0b0bba
adding util file that lets me see a transaction more cleanly: convert…
eshelB Aug 29, 2022
b49d664
IBC packet receive tests and bag fixes
liorbond Aug 29, 2022
498d961
Merge pull request #1096 from scrtlabs/lior-ibc-tests
liorbond Aug 29, 2022
7d0f85a
IBC ack and timeout should be encrypted
liorbond Aug 29, 2022
b058d3c
IBC ack tests
liorbond Aug 29, 2022
5b97e6f
Encrypt the output of every reply (Should be changed)
liorbond Aug 30, 2022
8152de2
adding util file that lets me see a transaction more cleanly: convert…
eshelB Aug 29, 2022
7d65399
Encrypt plaintext replies only if the original message was encrypted
liorbond Aug 30, 2022
b7ab07f
Merge pull request #1097 from scrtlabs/lior-ibc-tests
liorbond Aug 30, 2022
dfd161b
Merge branch 'eshel-ibc' of github.com:scrtlabs/SecretNetwork into es…
eshelB Aug 30, 2022
add2302
Fix gtests
liorbond Aug 30, 2022
50551f0
Merge pull request #1098 from scrtlabs/lior-ibc-tests
liorbond Aug 30, 2022
5dfee90
added the v010 integratoin-test for bankMsgSend
eshelB Aug 30, 2022
819352f
Merge branch 'eshel-ibc' of github.com:scrtlabs/SecretNetwork into es…
eshelB Aug 30, 2022
07d51f4
Commented code
liorbond Aug 30, 2022
2888b8a
Fix test setup
Cashmaney Aug 30, 2022
b9312c1
Log with "code_id" when storing contract
liorbond Aug 30, 2022
30a4318
Merge pull request #1099 from scrtlabs/lior-ibc-tests
liorbond Aug 30, 2022
b115959
Fixed debug printing to do much less if debug-print isn't defined
Cashmaney Aug 31, 2022
21fe583
Fixed debug printing to do much less if debug-print isn't defined
Cashmaney Aug 31, 2022
9f30493
Fixed secretcli dependency on SGX_MODE environment variable when inte…
Cashmaney Aug 31, 2022
cc98d0a
Merge remote-tracking branch 'origin/eshel-ibc' into cosmwasm-v1-with…
liorbond Aug 31, 2022
7f10223
Merge pull request #1105 from scrtlabs/cosmwasm-v1-with-every
liorbond Aug 31, 2022
e1f4475
logging integration test contract code and tx, since it helps debugging
eshelB Aug 31, 2022
3bc94c2
Fix redundant base64
liorbond Aug 31, 2022
2d22526
Merge pull request #1107 from scrtlabs/fix-redundant-base64
liorbond Aug 31, 2022
b66b585
Merge branch 'cosmwasm-v1' into eshel-ibc
eshelB Aug 31, 2022
460b951
causing integration tests to run on the ibc setup
eshelB Aug 31, 2022
fa8019e
avoiding a sequence mismatch by using a different account for the rel…
eshelB Aug 31, 2022
fbad24e
clippy
assafmo Aug 31, 2022
66ed573
Increase go-tests timeout from 40m to 90m
assafmo Aug 31, 2022
8d23d2f
increase test timeout to give the relayer the time to open the channels
eshelB Aug 31, 2022
a891416
Fix CI by uploading the artifacts
liorbond Aug 31, 2022
c1f96ef
Split events when using StoreCode
liorbond Aug 31, 2022
eabc980
tested ibc-tranfer of 1 uscrt between 2 different chains
eshelB Aug 31, 2022
4094d3e
Merge pull request #1113 from scrtlabs/ibc-integration-tests
eshelB Aug 31, 2022
b8b4aeb
CW v1 supports every error rather than only StdErrors in query
liorbond Aug 31, 2022
6454dfa
Merge pull request #1110 from scrtlabs/upload-artifact
liorbond Aug 31, 2022
111b684
Fix xbuild the same way as it was fixed in master
liorbond Aug 31, 2022
3001846
Merge pull request #1115 from scrtlabs/fix-xbuild
liorbond Aug 31, 2022
4c70d6d
Merge pull request #1114 from scrtlabs/fix-query-error-parsing
liorbond Aug 31, 2022
779dc5e
Merge pull request #1111 from scrtlabs/split-store-events
liorbond Aug 31, 2022
1236aae
Prettier
assafmo Aug 31, 2022
20b76a4
See 229bc8132255a292b8fb47fbd08065cad467adc5
assafmo Aug 31, 2022
041f01f
CI: Fix make build-ibc-hermes in Integration-Tests
assafmo Aug 31, 2022
daa3fe9
Merge pull request #1104 from scrtlabs/fu-sgx-mode
assafmo Aug 31, 2022
8892abb
Add /cosmos/tx/v1beta1 to swagger
assafmo Jul 26, 2022
16a2199
Rebuild swagger as v1.4.0
assafmo Aug 31, 2022
80580c0
empty
assafmo Aug 31, 2022
750c8d3
Merge pull request #1117 from scrtlabs/cw1-fix-swagger-for-cosmos/tx/…
assafmo Aug 31, 2022
c39bd56
Fix `make build-ibc-hermes`
assafmo Aug 31, 2022
cf8034a
Fix `make build-ibc-hermes`: Vol 2
assafmo Aug 31, 2022
7f75294
Merge pull request #1067 from scrtlabs/go-1.19
assafmo Aug 31, 2022
bfffb72
Refactor integration tests + Test MsgDelegate
assafmo Aug 31, 2022
b56363c
Merge pull request #1118 from scrtlabs/cw1-some-integration-tests
assafmo Aug 31, 2022
f3885d3
Code comment
assafmo Sep 1, 2022
8771a63
Integration tests: StakingMsg/Delegate/v0.10/error
assafmo Sep 1, 2022
901e81a
s/expect(tx.code).toBe(0)/expect(tx.code).toBe(TxResultCode.Success)/
assafmo Sep 1, 2022
e5ba279
Integration tests: Skip StakingMsg/Delegate/v1
assafmo Sep 1, 2022
992f4fb
Debug CI
assafmo Sep 1, 2022
05bdbdf
lint
assafmo Sep 1, 2022
3245c61
code comments
assafmo Sep 1, 2022
e5da311
lint
assafmo Sep 1, 2022
d849225
lint
assafmo Sep 1, 2022
1ea8d4d
Undo debug CI
assafmo Sep 1, 2022
39463aa
Refactor compute grpc handler + legacy handler code comments
assafmo Sep 1, 2022
d9d528f
lint
assafmo Sep 1, 2022
6737c5b
improving the method with which the relayer waits for the localsecret…
eshelB Sep 1, 2022
e65d5e1
logging docker compose version and increasing retires count on hermes…
eshelB Sep 1, 2022
70bfd2c
logging dockers in ci
eshelB Sep 1, 2022
fd34723
Merge branch 'hermes-docker-v2' into ibc-integration-tests
eshelB Sep 1, 2022
e6a0103
INtegration tests: BankMsg/Send/v0.10/error
assafmo Sep 1, 2022
5c5dbbe
killing ibc containers so that secret.js step in ci can have the port…
eshelB Sep 1, 2022
5049dd3
Merge branch 'hermes-docker-v2' into ibc-integration-tests
eshelB Sep 1, 2022
3c5310c
Integration tests are passing?
assafmo Sep 1, 2022
0d48b68
Merge remote-tracking branch 'origin/hermes-docker-v2' into fix-integ…
assafmo Sep 1, 2022
cc9004b
CI fix run docker compose of integration tests
assafmo Sep 1, 2022
a9d327c
Debug CI
assafmo Sep 1, 2022
f2f0a6d
Add support for nano ledger s+
gjermundgaraba Sep 2, 2022
a53c7f3
Fix healt checks for IBC integration tests
assafmo Sep 4, 2022
077d27f
Remove redundant healthcheck from IBC docker-compose
assafmo Sep 4, 2022
f686cf2
IBC docker-compose: remove port 1337
assafmo Sep 4, 2022
dccab46
Revert "Remove redundant healthcheck from IBC docker-compose"
assafmo Sep 1, 2022
6c3c5c3
Integration tests: jest --forceExit to kill pending promises when a t…
assafmo Sep 4, 2022
154ece5
CI Integration-Tests docker layer caching
assafmo Sep 4, 2022
50d3556
LocalSecret: Fix HEALTHCHECK
assafmo Sep 4, 2022
aa5ad16
Remove unused code comments
assafmo Sep 4, 2022
df21e8c
LocalSecret: golang 1.8 -> 1.19
assafmo Sep 4, 2022
ca8d153
LocalSecret: Fix HEALTHCHECK
assafmo Sep 4, 2022
2899d60
CI debug prints
assafmo Sep 4, 2022
a2aea33
LocalSecret: Try to fix healthcheck to make hermes happy
assafmo Sep 4, 2022
6e0803e
make go tests start up faster when rerunning them
reuvenpo Sep 4, 2022
7729e07
LocalSecret: Fix healthcheck?
assafmo Sep 4, 2022
78ce31f
CI: Remove debug prints
assafmo Sep 4, 2022
8d8bd40
Merge pull request #1121 from scrtlabs/fix-integration-tests-ci
assafmo Sep 4, 2022
80367a5
Merge pull request #1123 from bjaanes/cosmwasm-v1
assafmo Sep 4, 2022
80008a3
Remove `go.buildTags: secretcli` from vscode as it messes up go debug…
assafmo Sep 4, 2022
262ecae
Merge pull request #969 from scrtlabs/gitignore
assafmo Sep 4, 2022
b6b52c4
Merge pull request #1124 from scrtlabs/faster-go-tests-startup
assafmo Sep 4, 2022
26b183a
Integration tests: StakingMsg/Undelegate/v0.10
assafmo Sep 4, 2022
73164e8
Fix .only() in integration tests
assafmo Sep 4, 2022
0d2cc80
Integration tests: StakingMsg/Redelegate/v0.10
assafmo Sep 4, 2022
2ab0307
Integration tests: StakingMsg/Withdraw/v0.10
assafmo Sep 4, 2022
bf85115
Integration tests: CustomMsg/v0.10
assafmo Sep 4, 2022
05fb57b
Fixed dependencies so it actually compiles and can be tested now
Cashmaney Sep 4, 2022
7d27674
Fixed dependencies so it actually compiles and can be tested now
Cashmaney Sep 4, 2022
d816cbe
Merge remote-tracking branch 'origin/cosmwasm-v1' into cw1-upgrade-an…
Cashmaney Sep 4, 2022
2a83cbb
Consensus version = 1
Cashmaney Sep 4, 2022
ab9f17b
more perf adjustments
reuvenpo Sep 5, 2022
9a341b7
Merge pull request #1125 from scrtlabs/faster-go-tests-startup
reuvenpo Sep 5, 2022
baba093
Merge branch 'master' into cosmwasm-v1
assafmo Sep 5, 2022
279e73f
Merge branch 'cosmwasm-v1' of github.com:scrtlabs/SecretNetwork into …
assafmo Sep 5, 2022
03c0497
Add message.contract_address attribute to new msg router
assafmo Sep 5, 2022
3d851ba
Amino for x/authz + x/feegrant
assafmo Sep 5, 2022
c79564b
Revert /.vscode in .gitignore
assafmo Sep 5, 2022
63c269f
Merge remote-tracking branch 'origin/fix-integration-tests-ci' into i…
eshelB Sep 5, 2022
b617687
opened faucet port on localsecret
eshelB Sep 5, 2022
fdb2907
* Refactored v1/v010 contracts to be in the same path
Cashmaney Sep 5, 2022
53decf4
Merge remote-tracking branch 'origin/cosmwasm-v1' into ibc-integratio…
eshelB Sep 5, 2022
6b9e623
Enclave: Parse StdSignDoc from EIP191 sign_bytes
assafmo Sep 5, 2022
32e2e9e
Forgot one
Cashmaney Sep 5, 2022
fd40e6e
basic structure of ibc contract
eshelB Sep 5, 2022
589f0dc
contracts pass compilation
eshelB Sep 5, 2022
79bf782
Enclave EIP191: Don't use regex to parse StdSignDoc
assafmo Sep 5, 2022
8ceefd0
clippy
assafmo Sep 5, 2022
0241230
Refactor substring
assafmo Sep 5, 2022
e161627
EIP191: Prettify Amino JSON
assafmo Sep 5, 2022
b941c74
EIP191: Prettify Amino JSON
assafmo Sep 5, 2022
0e29051
Integration tests: GovMsgVote/v0.10/{success,error}
assafmo Sep 5, 2022
019b2b2
CI: Remove faulty docker layer caching
assafmo Sep 5, 2022
eb1e3d7
CI: Remove faulty docker layer caching
assafmo Sep 5, 2022
99f54ab
golangci-lint run ./... --fix
assafmo Sep 5, 2022
543a390
CI: Remove faulty docker layer caching
assafmo Sep 5, 2022
f935f3d
Merge branch 'cosmwasm-v1' into cw1-lint
assafmo Sep 5, 2022
8389903
Merge branch 'cosmwasm-v1' into cw1-upgrade-and-migrations
assafmo Sep 5, 2022
236bfa3
Integration tests: Wasm/MsgInstantiateContract/v0.10/{success,error}
assafmo Sep 5, 2022
1cb7a49
refactor
assafmo Sep 5, 2022
4633277
Integration tests: Wasm/MsgExecuteContract/v0.10/{success,error}
assafmo Sep 5, 2022
563ce65
Merge pull request #1127 from scrtlabs/eip191-enclave
assafmo Sep 5, 2022
8416613
Merge pull request #1129 from scrtlabs/cw1-lint
assafmo Sep 5, 2022
0b323ec
Merge pull request #1128 from scrtlabs/more-cw1-integration-tests
assafmo Sep 6, 2022
5bc1e2d
clippy
assafmo Sep 6, 2022
8b83130
Overhaul x/compute gRPC queries
assafmo Sep 6, 2022
ba8e73a
gRPC querier: code hash bytes -> string
assafmo Sep 6, 2022
7928fd4
Rebuild swagger
assafmo Sep 6, 2022
038a58d
Code comments
assafmo Sep 6, 2022
7c40dd6
Integration tests: update to secretjs@1.4.0-alpha.1
assafmo Sep 6, 2022
c1480d3
Merge pull request #1130 from scrtlabs/overhaul-protobuf
assafmo Sep 6, 2022
21b4a4c
CI integration tests point fix secret.js branch after PR merge
assafmo Sep 6, 2022
2275108
Merge branch 'cosmwasm-v1' into cw1-upgrade-and-migrations
assafmo Sep 6, 2022
8690d89
Remove admin & history stuff
assafmo Sep 6, 2022
acb59ff
lint
assafmo Sep 6, 2022
f70a627
Refactor v1.4 upgrade handler & add code comments
assafmo Sep 6, 2022
23ea672
Refactor setupUpgradeStoreLoaders()
assafmo Sep 6, 2022
80062d4
opened faucet port on localsecret
eshelB Sep 5, 2022
66cf606
basic structure of ibc contract
eshelB Sep 5, 2022
b599f7b
contracts pass compilation
eshelB Sep 5, 2022
7879dd2
contracts are now saved in an object that contains directives for bot…
eshelB Sep 6, 2022
0ec9f74
Remove compute 1->2 migration
assafmo Sep 6, 2022
16e5007
Revert mode changes
assafmo Sep 6, 2022
f529309
v2 store migration example
assafmo Sep 6, 2022
c07b341
uploading contracts to second chain too
eshelB Sep 6, 2022
b7e4a5b
Merge branch 'ibc-integration-tests' of github.com:scrtlabs/SecretNet…
eshelB Sep 6, 2022
c1d2284
Add ibc routing for compute module
liorbond Sep 6, 2022
5a94d71
Merge pull request #1132 from scrtlabs/add-compute-ibc-route
liorbond Sep 6, 2022
b0d68f8
Init transaction info in the env
liorbond Sep 5, 2022
65b5599
Fix
liorbond Sep 6, 2022
e04de64
fix
liorbond Sep 6, 2022
e329ff1
opened faucet port on localsecret
eshelB Sep 5, 2022
6d74359
basic structure of ibc contract
eshelB Sep 5, 2022
14ad976
contracts pass compilation
eshelB Sep 5, 2022
993e751
contracts are now saved in an object that contains directives for bot…
eshelB Sep 6, 2022
04db45e
uploading contracts to second chain too
eshelB Sep 6, 2022
ca07792
Merge branch 'ibc-integration-tests' of github.com:scrtlabs/SecretNet…
eshelB Sep 6, 2022
93495f4
Merge pull request #1131 from scrtlabs/init-tx-info
liorbond Sep 6, 2022
059b547
Rust logs `stdout` -> `stderr`
toml01 Aug 23, 2022
ade5aa1
fix build
toml01 Aug 24, 2022
538c344
fix tests
toml01 Aug 24, 2022
fb635a4
Add env variable to control log level
toml01 Aug 24, 2022
4b1ef77
triggering relayer's channel open from test, adding packet send endpo…
eshelB Sep 6, 2022
94d3783
seems like the packets are sent
eshelB Sep 6, 2022
3de05c6
saving to state the values passed on ack and receive, to try to verif…
eshelB Sep 6, 2022
33d39c0
Merge pull request #1134 from scrtlabs/stderr-logs-cosmwasmv1
liorbond Sep 7, 2022
78b6ccb
Type switch instead of if elses
toml01 Aug 22, 2022
0aff497
parseEncryptedBlob()
toml01 Aug 22, 2022
614bf70
Merge pull request #1109 from scrtlabs/cw1-upgrade-and-migrations
assafmo Sep 7, 2022
1b3a674
saving timeouts to state too, querying for all cases in both contract…
eshelB Sep 7, 2022
182b27c
Change proto types to allow multiple messages decryption
toml01 Sep 7, 2022
373991f
multiple messages decryption
toml01 Aug 22, 2022
4d27ddf
Change OutputError to be a string
toml01 Sep 7, 2022
8619e89
Fix OutputError
toml01 Aug 22, 2022
632f62b
Merge branch 'cosmwasm-v1' into refactored-test-contracts
Cashmaney Sep 7, 2022
1aad22d
using account c to open the channel between the contracts, to avoid s…
eshelB Sep 7, 2022
2bb6317
Merge pull request #1135 from scrtlabs/decrypt-multiple-cv1
liorbond Sep 7, 2022
c11a88a
Make Hermes send all pending packets
liorbond Sep 7, 2022
acf6fb7
Merge remote-tracking branch 'origin/ibc-integration-tests' into ibc-…
liorbond Sep 7, 2022
dddb150
Fix whitespaces
liorbond Sep 7, 2022
42aa1e7
Cargo.lock
assafmo Sep 7, 2022
4fee1b1
Fix IBC test
liorbond Sep 7, 2022
3e465b3
Dont skip tests
liorbond Sep 7, 2022
08d61b4
Merge pull request #1137 from scrtlabs/ibc-integration-tests-cw
liorbond Sep 7, 2022
b20f773
Bump gas costs to 100K per contract instance and another 200_000 (was…
Cashmaney Sep 6, 2022
f3f4bbe
Update gas.rs
Cashmaney Sep 7, 2022
a6bd7c5
Integration tests: Increase gas limit
assafmo Sep 7, 2022
4bed248
stuff
assafmo Sep 7, 2022
2c7241f
things
assafmo Sep 7, 2022
900491c
Merge pull request #1133 from scrtlabs/bump-gas-costs
assafmo Sep 7, 2022
39f982a
Fix release
liorbond Sep 7, 2022
ccc3da5
Merge pull request #1139 from scrtlabs/fix-release
liorbond Sep 7, 2022
cfa439b
Merge remote-tracking branch 'origin/cosmwasm-v1' into refactored-tes…
Cashmaney Sep 7, 2022
f5e9d17
lint
assafmo Sep 8, 2022
8cecf34
Add vscode debug config for secretcli
assafmo Sep 8, 2022
bb306ce
secretcli q compute tx: add `--node` flag
assafmo Sep 8, 2022
ededce2
secretcli q compute tx: fix log decryption
assafmo Sep 8, 2022
d9f5b7f
secretcli q compute tx: fix output data decryption
assafmo Sep 8, 2022
40f0d2c
Edit vscode debug config for secretcli
assafmo Sep 8, 2022
411026d
Merge pull request #1140 from scrtlabs/fix-secretcli-data-field-decrypt
assafmo Sep 8, 2022
e6534cc
`addr_validate()`: add normalized check
assafmo Sep 8, 2022
06e7e6b
Add aliases for secretcli compute subcommands
assafmo Sep 8, 2022
a0458bd
Better jest output
assafmo Sep 8, 2022
af91aab
Trigger CI (Fixed secret.js tests)
assafmo Sep 8, 2022
8bcf46c
Update stargateQueryAllowlist compute queries
assafmo Sep 8, 2022
3744932
Test addr validate
liorbond Sep 8, 2022
d4b5a44
Merge pull request #1141 from scrtlabs/add-validate-test
liorbond Sep 8, 2022
094ef0f
Protobuf code comments
assafmo Sep 8, 2022
531730d
Testing passing locally -
Cashmaney Sep 8, 2022
baefa7e
Trigger CI
assafmo Sep 8, 2022
985638d
Merge branch 'master' into cosmwasm-v1
liorbond Sep 8, 2022
7480df2
Merge pull request #1020 from scrtlabs/codeql-test
Cashmaney Sep 8, 2022
c2d6901
Merge remote-tracking branch 'origin/cosmwasm-v1' into refactored-tes…
Cashmaney Sep 8, 2022
1d3582f
Another old contract path
Cashmaney Sep 11, 2022
67f8130
Test init and execute data
liorbond Sep 11, 2022
4c3624f
Fix v0.10 `env.block.time`
assafmo Sep 11, 2022
f9464c1
Also go-tests env for init & query
assafmo Sep 11, 2022
8430557
Merge pull request #1126 from scrtlabs/refactored-test-contracts
Cashmaney Sep 11, 2022
3840269
Merge remote-tracking branch 'origin/cosmwasm-v1' into fix-v010-env-b…
Cashmaney Sep 11, 2022
4d4c525
StartgateQuery: Remove all non-O(1) queries
assafmo Sep 11, 2022
652d804
Merge pull request #1163 from scrtlabs/remove-stargatequery-get-all-q…
assafmo Sep 11, 2022
5506e41
Update .gitignore & .vscode/setting.json for #1126
assafmo Sep 11, 2022
77952ad
Merge pull request #1162 from scrtlabs/fix-v010-env-block-time
assafmo Sep 11, 2022
cbab3ab
Remove WASMs of contracts that are compiled in CI
assafmo Sep 11, 2022
036c898
"v1.4-fix" upgrade handler
assafmo Sep 11, 2022
f6d1bf6
gofumpt
assafmo Sep 11, 2022
26c1a07
Fix tests
liorbond Sep 11, 2022
88eebbc
Merge pull request #1164 from scrtlabs/test-outputs
liorbond Sep 11, 2022
2006602
Trigger CI
assafmo Sep 11, 2022
e2cac38
Update CHANGELOG.md
liorbond Sep 12, 2022
4b9d80a
Merge remote-tracking branch 'origin/master' into cosmwasm-v1
Cashmaney Sep 12, 2022
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
73 changes: 56 additions & 17 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,10 @@ jobs:
with:
path: ~/.cache/sccache
key: ${{ runner.os }}-sccache
- run: rustup component add rust-src clippy
- run: |
rustup component add rust-src clippy
cd cosmwasm/enclaves/execute/
rustup component add rust-src clippy
- name: Install xargo
run: |
cargo --version
Expand All @@ -56,7 +59,7 @@ jobs:
- uses: actions/checkout@v2
- uses: actions/setup-go@v3
with:
go-version: "^1.18" # The Go version to download (if necessary) and use.
go-version: 1.19 # The Go version to download (if necessary) and use.
- name: Install Intel's SGX SDK
run: |
mkdir -p "$HOME/.sgxsdk"
Expand All @@ -80,7 +83,10 @@ jobs:
with:
path: ~/.cache/sccache
key: ${{ runner.os }}-sccache
- run: rustup component add rust-src clippy
- run: |
rustup component add rust-src clippy
cd cosmwasm/enclaves/execute/
rustup component add rust-src clippy
- name: Install xargo
run: |
cargo --version
Expand Down Expand Up @@ -127,7 +133,15 @@ jobs:
- uses: actions/upload-artifact@v3
with:
name: contract.wasm
path: ./x/compute/internal/keeper/testdata/test-contract/contract.wasm
path: cosmwasm/contracts/v010/compute-tests/test-compute-contract/contract.wasm
- uses: actions/upload-artifact@v3
with:
name: v1-contract.wasm
path: cosmwasm/contracts/v1/compute-tests/test-compute-contract/v1-contract.wasm
- uses: actions/upload-artifact@v3
with:
name: ibc.wasm
path: cosmwasm/contracts/v1/compute-tests/ibc-test-contract/ibc.wasm
- uses: actions/upload-artifact@v3
with:
name: enclave
Expand All @@ -139,15 +153,15 @@ jobs:
- uses: actions/upload-artifact@v3
with:
name: contract_with_floats.wasm
path: ./x/compute/internal/keeper/testdata/test-contract/contract_with_floats.wasm
path: cosmwasm/contracts/v010/compute-tests/test-compute-contract/contract_with_floats.wasm
- uses: actions/upload-artifact@v3
with:
name: too-high-initial-memory.wasm
path: ./x/compute/internal/keeper/testdata/test-contract/too-high-initial-memory.wasm
path: cosmwasm/contracts/v010/compute-tests/test-compute-contract/too-high-initial-memory.wasm
- uses: actions/upload-artifact@v3
with:
name: static-too-high-initial-memory.wasm
path: ./x/compute/internal/keeper/testdata/test-contract/static-too-high-initial-memory.wasm
path: cosmwasm/contracts/v010/compute-tests/test-compute-contract/static-too-high-initial-memory.wasm

Go-Tests:
runs-on: ubuntu-20.04
Expand All @@ -156,7 +170,7 @@ jobs:
- uses: actions/checkout@v2
- uses: actions/setup-go@v3
with:
go-version: "^1.18" # The Go version to download (if necessary) and use.
go-version: 1.19 # The Go version to download (if necessary) and use.
- name: Install Intel's SGX SDK
run: |
mkdir -p "$HOME/.sgxsdk"
Expand All @@ -174,6 +188,14 @@ jobs:
- uses: actions/download-artifact@v3
with:
name: contract.wasm
- uses: actions/download-artifact@v3
with:
name: v1-contract.wasm
path: ./x/compute/internal/keeper/testdata/
- uses: actions/download-artifact@v3
with:
name: ibc.wasm
path: ./x/compute/internal/keeper/testdata/
- uses: actions/download-artifact@v3
with:
name: contract_with_floats.wasm
Expand All @@ -185,12 +207,14 @@ jobs:
name: static-too-high-initial-memory.wasm
- name: Setup Files
run: |
find "$(pwd)" -name \*.wasm
cp libgo_cosmwasm.so ./go-cosmwasm/api/libgo_cosmwasm.so
cp librust_cosmwasm_enclave.signed.so ./go-cosmwasm/librust_cosmwasm_enclave.signed.so
cp contract.wasm ./x/compute/internal/keeper/testdata/test-contract/contract.wasm
cp too-high-initial-memory.wasm ./x/compute/internal/keeper/testdata/test-contract/too-high-initial-memory.wasm
cp contract_with_floats.wasm ./x/compute/internal/keeper/testdata/test-contract/contract_with_floats.wasm
cp static-too-high-initial-memory.wasm ./x/compute/internal/keeper/testdata/test-contract/static-too-high-initial-memory.wasm
cp contract.wasm ./x/compute/internal/keeper/testdata/contract.wasm
cp too-high-initial-memory.wasm ./x/compute/internal/keeper/testdata/too-high-initial-memory.wasm
cp contract_with_floats.wasm ./x/compute/internal/keeper/testdata/contract_with_floats.wasm
cp static-too-high-initial-memory.wasm ./x/compute/internal/keeper/testdata/static-too-high-initial-memory.wasm
find "$(pwd)" -name \*.wasm
- name: Test x/registration
run: |
source "$HOME/.sgxsdk/sgxsdk/environment"
Expand All @@ -205,7 +229,7 @@ jobs:
echo "not_a_key" > ias_keys/develop/spid.txt
echo "not_a_key" > ias_keys/develop/api_key.txt
LOG_LEVEL=ERROR go test -v ./x/compute/client/...
LOG_LEVEL=ERROR go test -p 1 -timeout 20m -v ./x/compute/internal/...
LOG_LEVEL=ERROR go test -p 1 -timeout 90m -v ./x/compute/internal/...

Clippy:
runs-on: ubuntu-20.04
Expand Down Expand Up @@ -234,9 +258,13 @@ jobs:
with:
path: ~/.cache/sccache
key: ${{ runner.os }}-sccache
- run: rustup component add rust-src clippy
- run: |
rustup component add rust-src clippy
cd cosmwasm/enclaves/execute/
rustup component add rust-src clippy
- name: Install xargo
run: |
cd cosmwasm/enclaves/execute/
cargo --version
rustc --version
cargo +stable install xargo --version 0.3.25
Expand All @@ -260,7 +288,7 @@ jobs:
- uses: actions/checkout@v2
- uses: actions/setup-go@v3
with:
go-version: "^1.18" # The Go version to download (if necessary) and use.
go-version: 1.19 # The Go version to download (if necessary) and use.
- name: Install xgo
run: |
go install github.com/crazy-max/xgo@v0.17.0
Expand All @@ -272,13 +300,24 @@ jobs:
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v2
- name: Build docker testnet
- name: Build LocalSecret
run: |
echo not_a_key | tee {api_key,spid}.txt
DOCKER_TAG=v0.0.0 make build-localsecret
- name: Build Hermes
run: |
DOCKER_TAG=v0.0.0 make build-ibc-hermes
- name: Run integration tests
run: |
cd integration-tests
yarn
docker compose -f ../deployment/dockerfiles/ibc/docker-compose.yml up -d
# docker compose -f ../deployment/dockerfiles/ibc/docker-compose.yml logs -f &
yarn test
make kill-localsecret # next step needs the localsecret ports
- name: Run secret.js tests
run: |
git clone --depth 1 --branch lior-fix-based-on-rpc-2 https://github.com/scrtlabs/secret.js
git clone --depth 1 --branch cosmwasm-v1 https://github.com/scrtlabs/secret.js
cd secret.js
# Use the docker images that we built just a few steps above
perl -i -pe 's/localsecret:.+?"/localsecret:v0.0.0"/' ./test/*
Expand Down
66 changes: 66 additions & 0 deletions .github/workflows/codeql-analysis.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,66 @@
# For most projects, this workflow file will not need changing; you simply need
# to commit it to your repository.
#
# You may wish to alter this file to override the set of languages analyzed,
# or to provide custom queries or build logic.
#
# ******** NOTE ********
# We have attempted to detect the languages in your repository. Please check
# the `language` matrix defined below to confirm you have the correct set of
# supported CodeQL languages.
#
name: "CodeQL"

on:
push:
branches: [ "master" ]
pull_request:
# The branches below must be a subset of the branches above
branches: [ "master" ]
schedule:
- cron: '35 19 * * 6'

jobs:
analyze:
name: Analyze
runs-on: ubuntu-20.04
permissions:
actions: read
contents: read
security-events: write

steps:
- name: Checkout repository
uses: actions/checkout@v3
- uses: actions/setup-go@v3
with:
go-version: 1.18
# Initializes the CodeQL tools for scanning.
- name: Initialize CodeQL
uses: github/codeql-action/init@v2
with:
languages: "go"
queries: crypto-com/cosmos-sdk-codeql@main,security-and-quality
# If you wish to specify custom queries, you can do so here or in a config file.
# By default, queries listed here will override any specified in a config file.
# Prefix the list here with "+" to use these queries and those in the config file.
# queries: ./path/to/local/query, your-org/your-repo/queries@main

# Autobuild attempts to build any compiled languages (C/C++, C#, or Java).
# If this step fails, then you should remove it and run the build manually (see below)
- name: Autobuild
uses: github/codeql-action/autobuild@v2

# ℹ️ Command-line programs to run using the OS shell.
# 📚 https://git.io/JvXDl

# ✏️ If the Autobuild fails above, remove it and uncomment the following three lines
# and modify them (or add more) to build your code if your project
# uses a compiled language

#- run: |
# make bootstrap
# make release

- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v2
18 changes: 11 additions & 7 deletions .github/workflows/release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ jobs:
echo "::set-output name=sha_short::$(git rev-parse --short HEAD)"
- uses: actions/setup-go@v3
with:
go-version: "^1.18" # The Go version to download (if necessary) and use.
go-version: 1.19 # The Go version to download (if necessary) and use.
- name: Install Intel's SGX SDK
run: |
mkdir -p "$HOME/.sgxsdk"
Expand Down Expand Up @@ -97,7 +97,7 @@ jobs:
run: echo ::set-output name=VERSION::${GITHUB_REF/refs\/tags\/v/}
- uses: actions/setup-go@v3
with:
go-version: "^1.18" # The Go version to download (if necessary) and use.
go-version: 1.19 # The Go version to download (if necessary) and use.
- name: Create api keys
run: |
echo $SPID_MAINNET > spid.txt
Expand Down Expand Up @@ -128,6 +128,9 @@ jobs:
os: [ubuntu-20.04, windows-latest, macos-latest]
steps:
- uses: actions/checkout@v3
- uses: actions/setup-go@v2
with:
go-version: 1.19 # The Go version to download (if necessary) and use.
- name: Build CLI
shell: bash
run: |
Expand All @@ -138,18 +141,18 @@ jobs:
name: secretcli-${{runner.os}}
path: secretcli-${{runner.os}}

x-build-cli:
MacOS-ARM64-CLI:
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v3
- uses: actions/setup-go@v3
with:
go-version: "^1.18" # The Go version to download (if necessary) and use.
go-version: 1.19 # The Go version to download (if necessary) and use.
- name: Install xgo
run: |
go install github.com/crazy-max/xgo@latest
go install github.com/crazy-max/xgo@v0.17.0
xgo || true # check installation
- name: Build CLI
- name: Build MacOS CLI
shell: bash
run: |
make build_macos_arm64_cli
Expand Down Expand Up @@ -188,7 +191,8 @@ jobs:
run: docker push ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}:${{ steps.get_version.outputs.VERSION }}

Release:
needs: [native-build-cli, build-deb-testnet, build-deb-mainnet, x-build-cli]
needs:
[native-build-cli, build-deb-testnet, build-deb-mainnet, MacOS-ARM64-CLI]
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v3
Expand Down
9 changes: 7 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@ librust_cosmwasm_enclave.signed.so
SHA256SUMS*
*.so
/third_party/vendor
.vscode
*.sealed
*.der
__debug_bin
Expand All @@ -35,4 +34,10 @@ ias_bin_sw.go
node_modules
/secretjs
/secret.js
tmp-swagger-gen
tmp-swagger-gen
x/compute/internal/keeper/testdata/contract_with_floats.wasm
x/compute/internal/keeper/testdata/contract.wasm
x/compute/internal/keeper/testdata/ibc.wasm
x/compute/internal/keeper/testdata/static-too-high-initial-memory.wasm
x/compute/internal/keeper/testdata/too-high-initial-memory.wasm
x/compute/internal/keeper/testdata/v1-contract.wasm
47 changes: 47 additions & 0 deletions .golangci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
run:
tests: false
# # timeout for analysis, e.g. 30s, 5m, default is 1m
timeout: 5m

linters:
disable-all: true
enable:
- depguard
- dogsled
- exportloopref
- errcheck
- goconst
- gocritic
- gofumpt
- gosec
- gosimple
- govet
- ineffassign
- misspell
- nakedret
- staticcheck
- stylecheck
- revive
- typecheck
- unconvert
- misspell
- nolintlint

issues:
exclude-rules:
- text: "var-naming"
linters:
- revive
- text: "ST1003:"
linters:
- stylecheck
- text: "commentFormatting"
linters:
- stylecheck
- gocritic
- text: "dupSubExpr"
linters:
- gocritic
- text: "// nolint` should be written without leading space as `//nolint"
linters:
- nolintlint
3 changes: 3 additions & 0 deletions .vscode/extensions.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
"recommendations": ["golang.go", "peterj.proto", "rust-lang.rust-analyzer"]
}
Loading