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

Merged chaos #7

Closed
wants to merge 1,094 commits into from
Closed
Changes from 1 commit
Commits
Show all changes
1094 commits
Select commit Hold shift + click to select a range
decffbc
Update to 2.1.0-rc.1
chipshort Jun 25, 2024
c0b5da6
Bump curve25519-dalek and self_cell
chipshort Jun 25, 2024
e8310e2
Adjust cache size values
chipshort Jun 25, 2024
9ce2011
Fix lint
chipshort Jun 26, 2024
69c8d72
Merge pull request #540 from CosmWasm/chipshort/migrate-version
chipshort Jun 26, 2024
1de5cd8
[skip ci] Built release libraries
Jun 26, 2024
3391e19
Add IBCSourceChainCallbackMsg type
chipshort Feb 23, 2024
698cee4
Add ibc_source_chain_callback entrypoint
chipshort Feb 29, 2024
cc508db
Add ibc-callbacks to deploy_to_git branch
chipshort Feb 29, 2024
32a1401
Add destination chain callback
chipshort Apr 4, 2024
c6a435e
Update destination chain callback type
chipshort Apr 5, 2024
628249f
Fix destination chain callback
chipshort Apr 5, 2024
bc9921f
Adjust IBC Callback types
chipshort Apr 16, 2024
3852424
Update ibc callback types
chipshort Apr 23, 2024
cbe0b07
Update callback types
chipshort May 10, 2024
ea935a7
Remove branch from deploy_to_git job
chipshort Jun 25, 2024
15d29dc
Merge pull request #520 from CosmWasm/ibc-callbacks
chipshort Jun 26, 2024
eec191a
[skip ci] Built release libraries
Jun 26, 2024
d9078c7
Add bindings for the pinned metrics
aumetra Mar 18, 2024
b55dc36
Update go.mod
aumetra Mar 18, 2024
06deb1e
Fix lints
aumetra Mar 18, 2024
47f2674
Make unmarshal function associated
aumetra Mar 19, 2024
94cb09d
Add Nix flake with dev shell
aumetra Mar 19, 2024
260e8e1
Add Go test for pinned metrics
aumetra Mar 19, 2024
ac29471
Fix test expectation
aumetra Mar 19, 2024
e1dbd4e
Swap around assert order
aumetra Mar 19, 2024
88cb2d7
Tag map as array
aumetra Mar 19, 2024
37b95b0
Use `HashMap` in Rust
aumetra Mar 19, 2024
99cb47c
Fix test expectations
aumetra Mar 19, 2024
f4d0a92
Implement `Stringer` interface, skip `HashMap` on Rust side
aumetra Mar 19, 2024
cfd0f16
Add `Stringer` test
aumetra Mar 19, 2024
074e7d6
Update IBCMsg type
chipshort May 10, 2024
b6a20d5
Change field name and type
aumetra Jun 26, 2024
34c853f
Serialize as byte array
aumetra Jun 26, 2024
61b6bcd
Fix name
aumetra Jun 26, 2024
b12bab6
Fix tests
aumetra Jun 26, 2024
5144d94
Update libwasmvm/src/cache.rs
aumetra Jun 26, 2024
372c10c
Merge pull request #542 from CosmWasm/co/async-ack
chipshort Jun 26, 2024
caa4c0f
[skip ci] Built release libraries
Jun 26, 2024
98ab989
Switch how fields are encoded
aumetra Jun 26, 2024
a716026
Fix memory leak
chipshort Jun 26, 2024
73b87c0
Merge pull request #543 from CosmWasm/co/fix-errorWithMessage
chipshort Jun 26, 2024
75fd983
[skip ci] Built release libraries
Jun 26, 2024
1ecdacb
Update flake.nix
aumetra Jun 26, 2024
39c9e09
Merge pull request #526 from CosmWasm/aw/pinned-metrics
chipshort Jun 27, 2024
6f5c9c9
Set libwasmvm version to 2.1.0-rc.1
chipshort Jun 27, 2024
f3fe7e7
[skip ci] Built release libraries
Jun 27, 2024
90b3c0d
Expose pinned metrics through vm
chipshort Jul 3, 2024
0dc2068
Improve doc comment
chipshort Jul 3, 2024
4359354
Merge pull request #544 from CosmWasm/co/expose-pinned-metrics
chipshort Jul 3, 2024
a3e18dd
[skip ci] Built release libraries
Jul 3, 2024
e1c2e4e
Set libwasmvm version to 2.1.0-rc.2
chipshort Jul 3, 2024
5da9f8c
[skip ci] Built release libraries
Jul 3, 2024
ccf6865
Set libwasmvm version to 2.1.0
chipshort Jul 11, 2024
d7906b3
[skip ci] Built release libraries
Jul 11, 2024
1921fe0
Add ibc fees messages
chipshort Jul 29, 2024
f5a2110
Update comments on stripping
webmaster128 Jul 31, 2024
873a6a3
Merge pull request #546 from CosmWasm/strip-comments
webmaster128 Jul 31, 2024
f72d5de
[skip ci] Built release libraries
Jul 31, 2024
8256c81
Create debian build and use for build_gnu_aarch64.sh
Apr 6, 2023
36c4286
Add CI step: Check .so files
webmaster128 Jul 3, 2024
bc06f57
Add script to check required glibc versions
webmaster128 Jul 3, 2024
6bff967
Use Debian 11 instead of 12
webmaster128 Jul 3, 2024
8b890e0
Use debian for build_gnu_x86_64.sh too
webmaster128 Jul 3, 2024
9785cc6
Remove references to centos7
webmaster128 Jul 14, 2024
a3d7091
Rename repo to cosmwasm/libwasmvm-builder and bump version
webmaster128 Jul 16, 2024
9245dcb
Add CentOS -> Debian CHANGELOG entry
webmaster128 Jul 16, 2024
069c8d9
Let builders target /target
webmaster128 Jul 2, 2024
c27b736
Bump version to 100
webmaster128 Jul 30, 2024
a353aa7
Merge pull request #439 from CosmWasm/debian-builders
webmaster128 Jul 31, 2024
b9a3dd9
Remove unused Dockerfile.centos7
webmaster128 Jul 31, 2024
23be57a
Fixup builders 0100
webmaster128 Jul 31, 2024
f3df522
Update calling convention of builders to 0100
webmaster128 Jul 31, 2024
66ddabb
Upgrade clippy to 1.80.0
webmaster128 Jul 31, 2024
81003e2
[skip ci] Built release libraries
Jul 31, 2024
9dac350
Update time crate
webmaster128 Aug 1, 2024
aa38d97
Merge pull request #547 from CosmWasm/clippy-1.80.0
webmaster128 Aug 1, 2024
0191dea
[skip ci] Built release libraries
Aug 1, 2024
7064f6a
Upgrade cbindgen to 0.27.0
webmaster128 Aug 10, 2024
b301626
Streamline licensing
webmaster128 Aug 10, 2024
6ba66cb
Merge pull request #548 from CosmWasm/upgrade-cbindgen
webmaster128 Aug 12, 2024
091279a
[skip ci] Built release libraries
Aug 12, 2024
a11bb42
Update IBC fee messages
chipshort Aug 12, 2024
0ef8a35
Add IBC fee query
chipshort Aug 12, 2024
5ba509b
Merge pull request #545 from CosmWasm/co/ibc-fees
chipshort Aug 12, 2024
621a87c
[skip ci] Built release libraries
Aug 12, 2024
ce32bc1
Cleanup build commands in Makefile
webmaster128 Aug 12, 2024
c43840a
Upgrade Rust version in builders to 1.80.0; use Bookworm
webmaster128 Aug 12, 2024
e673aa6
Rename .cargo/config to .cargo/config.toml to silence warning
webmaster128 Aug 12, 2024
1b8be74
Merge pull request #552 from CosmWasm/sw/rust-1.80
webmaster128 Aug 13, 2024
44e2980
[skip ci] Built release libraries
Aug 13, 2024
debea64
Merge pull request #550 from CosmWasm/sw/makefile-build-commands
webmaster128 Aug 13, 2024
57bf368
[skip ci] Built release libraries
Aug 13, 2024
51f2940
Update to cosmwasm 2.1.2
chipshort Aug 8, 2024
f947671
Bump wasmvm version
chipshort Aug 8, 2024
3001118
Update cosmwasm to 2.1.3
chipshort Aug 8, 2024
f96710f
Bump wasmvm version
chipshort Aug 8, 2024
8c38def
Merge pull request #555 from CosmWasm/merge-2.1
chipshort Aug 21, 2024
f8d401a
[skip ci] Built release libraries
Aug 21, 2024
38f557f
Upgrade bytes to 1.7.1
webmaster128 Aug 26, 2024
bf06957
Merge pull request #557 from CosmWasm/upgrade-bytes
webmaster128 Aug 27, 2024
4728aa1
[skip ci] Built release libraries
Aug 27, 2024
819e52d
Use rc of cosmwasm-std and cosmwasm-vm
chipshort Oct 7, 2024
a327452
Fix gas values
chipshort Oct 7, 2024
f68e792
Merge pull request #561 from CosmWasm/co/bump-cw
chipshort Oct 7, 2024
9674c32
Bump cosmwasm rc
chipshort Oct 8, 2024
9e38458
Merge pull request #562 from CosmWasm/co/bump-cw
chipshort Oct 8, 2024
365e3bf
[skip ci] Built release libraries
Oct 8, 2024
6fced70
Set libwasmvm version to 2.2.0-rc.1
chipshort Oct 8, 2024
7d28c41
[skip ci] Built release libraries
Oct 8, 2024
c9d63a4
feat: Add conditional migrate calling
kulikthebird Aug 21, 2024
34db228
Merge pull request #556 from CosmWasm/tkulik/conditional_migrate
chipshort Oct 10, 2024
925f59e
[skip ci] Built release libraries
Oct 10, 2024
b7c1cbf
Update builder to Rust 1.81
chipshort Oct 12, 2024
010196c
Bump cosmwasm rc
chipshort Oct 12, 2024
4f7575a
[skip ci] Built release libraries
Oct 12, 2024
bc859c9
Add cosmwasm-vm config
chipshort Aug 23, 2024
740a8c0
Improve Size type
chipshort Aug 23, 2024
5510ac3
Update naming
chipshort Aug 28, 2024
9846576
Use JSON for VMConfig
chipshort Aug 30, 2024
bdc225e
Use JSON for VMConfig
chipshort Sep 15, 2024
48d8494
Update test names
chipshort Sep 15, 2024
7250c10
Fix pinned metrics
chipshort Sep 15, 2024
ec3a0a7
Expose VMConfig constructor
chipshort Sep 25, 2024
7b88fd4
Simplify NewVM
chipshort Sep 25, 2024
d455a68
Improve docs
chipshort Oct 7, 2024
da987f6
Remove unused import
chipshort Oct 7, 2024
f5160b2
Fix lints
chipshort Oct 8, 2024
8d3938d
Rename config fields
chipshort Oct 12, 2024
65d03d3
Merge pull request #560 from CosmWasm/co/customizable-limits
chipshort Oct 14, 2024
682a176
Merge pull request #563 from CosmWasm/co/update-rust-builder
chipshort Oct 14, 2024
8f48616
[skip ci] Built release libraries
Oct 14, 2024
87b5cdf
Set builders version 0101
webmaster128 Oct 14, 2024
c6d88fd
Merge pull request #564 from CosmWasm/set-builders-0101
webmaster128 Oct 14, 2024
198f254
[skip ci] Built release libraries
Oct 14, 2024
0661bee
docs: Move `spec` to cosmwasm documentation
kulikthebird Oct 17, 2024
f86be64
Merge pull request #566 from CosmWasm/tkulik/move_spec_docs
chipshort Oct 23, 2024
7e81281
[skip ci] Built release libraries
Oct 23, 2024
484d39b
Update builder rust version to 1.82
chipshort Oct 24, 2024
5bd7543
Set builder version to 0102
chipshort Oct 24, 2024
97280d1
Merge pull request #567 from CosmWasm/co/update-builder-rust
chipshort Oct 25, 2024
17ea7ca
[skip ci] Built release libraries
Oct 25, 2024
0a2eab2
Set libwasmvm version to 2.2.0-rc.2
chipshort Oct 25, 2024
2b79acd
[skip ci] Built release libraries
Oct 25, 2024
7dd9fa5
Add panic handler function
webmaster128 Oct 30, 2024
b785826
Move called function and error into handle_vm_panic
webmaster128 Oct 30, 2024
0d7a848
Merge pull request #569 from CosmWasm/add-handle_vm_panic
chipshort Nov 5, 2024
cb4b649
[skip ci] Built release libraries
Nov 5, 2024
4c0d2ea
Fix
chipshort Nov 6, 2024
ca5f3d3
Add comments
chipshort Nov 13, 2024
7ba94cd
Merge pull request #571 from CosmWasm/fix-ptr-bug
chipshort Nov 13, 2024
443d534
[skip ci] Built release libraries
Nov 13, 2024
03abf89
Set libwasmvm version to 2.2.0-rc.3
chipshort Dec 11, 2024
8a26f8d
[skip ci] Built release libraries
Dec 11, 2024
1ea7305
Update to cosmwasm 2.2
chipshort Dec 17, 2024
a5c3a79
Update CI libwasmvm_audit Rust version
chipshort Dec 17, 2024
5dfac8d
Merge pull request #578 from CosmWasm/cp/update-cosmwasm-2.2
chipshort Dec 17, 2024
9aa2649
[skip ci] Built release libraries
Dec 17, 2024
2fa12a9
Set libwasmvm version to 2.2.0
chipshort Dec 17, 2024
ee9d20c
[skip ci] Built release libraries
Dec 17, 2024
57a7cd3
Add SimulateStoreCode function
chipshort Oct 28, 2024
24209d3
Add test for SimulateStoreCode
chipshort Dec 19, 2024
4f4b1ad
Fix panic msg
chipshort Dec 19, 2024
1ccfa6b
Add typo check
chipshort Dec 19, 2024
4b11623
Merge pull request #580 from CosmWasm/co/add-store-code
chipshort Dec 19, 2024
bdbeadc
Fix typos
chipshort Dec 19, 2024
e95ff2f
[skip ci] Built release libraries
Dec 19, 2024
af3791a
Set libwasmvm version to 2.2.1
chipshort Dec 19, 2024
bb5b8c1
[skip ci] Built release libraries
Dec 19, 2024
5eeb9ab
most tests pass
faddat Dec 19, 2024
26fc9f5
Merge remote-tracking branch 'origin/main'
faddat Dec 19, 2024
c114170
sleep`
faddat Dec 19, 2024
7e23cac
cleanup
faddat Dec 19, 2024
ae1b69e
don't close cache in ReleasCache
faddat Dec 19, 2024
03575a1
additional cleanup
faddat Dec 19, 2024
d06a50d
resolve further issues
faddat Dec 19, 2024
8fc8213
fix issues with siguantures
faddat Dec 20, 2024
9a337bb
memory management
faddat Dec 20, 2024
62a2b75
fix analyzecode
faddat Dec 20, 2024
e0a26b2
database functions
faddat Dec 20, 2024
adddaef
fix issues related to db_scan
faddat Dec 20, 2024
b0fe30b
fix addr_validate
faddat Dec 20, 2024
e51b683
add 3 types of sig verification
faddat Dec 20, 2024
f849192
Merge pull request #581 from CosmWasm/co/add-typo-check
chipshort Dec 20, 2024
6480176
[skip ci] Built release libraries
Dec 20, 2024
e8bb8f1
add query_chain host function
faddat Dec 20, 2024
1aba7bc
gci
faddat Dec 20, 2024
06918ac
fix testfloats
faddat Dec 20, 2024
fdeda87
fix out of bounds memory access
faddat Dec 21, 2024
237fa73
add missing host functions
faddat Dec 21, 2024
51a29b3
revert golangci changes to focus on the insantiate issue
faddat Dec 21, 2024
76ab8e1
Merge remote-tracking branch 'upstream/main' into merged-chaos
faddat Dec 21, 2024
136538c
Refactor memory management and host functions in wasmvm
faddat Dec 22, 2024
5b2ef78
testifylint execpt for the MockInfoBin
faddat Dec 22, 2024
58a57ab
Create tests.yml
faddat Dec 22, 2024
9404e32
testifylint execpt for the MockInfoBin
faddat Dec 22, 2024
3eb0c97
gci'd
faddat Dec 22, 2024
64e241e
continue test cleanup
faddat Dec 22, 2024
675f892
gci is much better than goimports
faddat Dec 22, 2024
1921179
use latest linter
faddat Dec 22, 2024
f8005f8
resolve issues with goroutine
faddat Dec 22, 2024
445f165
enable errcheck and thelper linters
faddat Dec 22, 2024
4881ea2
Update Go and golangci-lint version in CI
webmaster128 Dec 22, 2024
2226db6
remove manual host side deallocation
faddat Dec 22, 2024
f2476ef
progress...
faddat Dec 22, 2024
80e9ddd
update runtime
faddat Dec 22, 2024
cbcf5a9
update contracts used in testing`
faddat Dec 22, 2024
3286d4f
update capabilities
faddat Dec 22, 2024
bd565b4
correct typo from adjusting tests.
faddat Dec 22, 2024
7bd5e19
Merge branch 'faddat/testifylint' into faddat/errcheck
faddat Dec 22, 2024
806765d
Merge commit 'cbcf5a9' into merged-chaos
faddat Dec 22, 2024
1ad7343
Merge commit '3286d4f' into merged-chaos
faddat Dec 22, 2024
ee2187d
Revert "update capabilities"
faddat Dec 23, 2024
6875d5f
Revert "update runtime"
faddat Dec 23, 2024
eb485f8
add cryptographic imports
faddat Dec 23, 2024
1e0588a
replace deprecated library
faddat Dec 23, 2024
4dacdd8
all signature mismatches resolved
faddat Dec 23, 2024
da99b00
add validation.go
faddat Dec 23, 2024
6b34c21
TestStoreCode passes, introduce table-driven test
faddat Dec 23, 2024
35f5986
improve debug
faddat Dec 24, 2024
9810ad1
Merge commit '58a57ab' into merged-chaos
faddat Dec 25, 2024
4f8afaa
`Merge commit 'bd565b4' into merged-chaos
faddat Dec 25, 2024
8ac36b5
Merge commit '7bd5e19' into merged-chaos
faddat Dec 25, 2024
dda5695
lint
faddat Dec 25, 2024
ccc48d7
update linter config
faddat Dec 25, 2024
4309b4e
Update .gitignore, modify mock time format, and enhance host function…
faddat Dec 26, 2024
9af9725
restore libwasmvm to ease reference
faddat Dec 26, 2024
83a8f08
high quality debug info
faddat Jan 2, 2025
03e886a
add additional debug (look at adapted vs actual...)
faddat Jan 3, 2025
0d45e1e
turn on debug
faddat Jan 3, 2025
4e497f5
Enhance testing capabilities, improve gas tracking, and validate memo…
faddat Jan 4, 2025
4a5e8a9
Add new contracts and update existing ones with improved schemas and …
faddat Jan 4, 2025
311ef12
Refactor WazeroRuntime to support additional parameters in contract f…
faddat Jan 5, 2025
7282c60
Add gas tracking functionality and refactor gas costs in runtime
faddat Jan 5, 2025
0a8eb5c
Refactor tests and improve error handling in IBC and memory database
faddat Jan 5, 2025
38c321e
Update .gitignore, enhance debug logging in host functions, and impro…
faddat Jan 5, 2025
fa17dcf
align runtime with lib
faddat Jan 5, 2025
f78dd37
Refactor WazeroRuntime to centralize parameter validation
faddat Jan 5, 2025
f6910f8
Enhance callContractFn with structured memory management and detailed…
faddat Jan 6, 2025
58af4fd
fix lints
faddat Jan 6, 2025
ef57261
add wzaero code
faddat Jan 6, 2025
d37b8a9
make it reviewable...
faddat Jan 7, 2025
d3f9f1e
change gitignore and remove extra files
faddat Jan 7, 2025
a16560c
Merge pull request #590 from CosmWasm/update-golangci-lint
webmaster128 Jan 7, 2025
95ca0c0
[skip ci] Built release libraries
Jan 7, 2025
700f44e
Use locked dependencies for cargo-audit install
chipshort Jan 7, 2025
0864d7f
Update cargo-audit
chipshort Jan 7, 2025
f829083
Merge pull request #604 from CosmWasm/co/fix-audit-job
chipshort Jan 7, 2025
0b82922
[skip ci] Built release libraries
Jan 7, 2025
e7c998a
Merge branch 'main' into merged-chaos
faddat Jan 9, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
don't close cache in ReleasCache
faddat committed Dec 19, 2024
commit ae1b69e741db1a64e70672de047f838fb00fce6e
4 changes: 3 additions & 1 deletion internal/api/lib.go
Original file line number Diff line number Diff line change
@@ -63,10 +63,12 @@ func InitCache(config types.VMConfig) (Cache, error) {

func ReleaseCache(cache Cache) {
currentRuntime.ReleaseCache(cache.handle)
cache.lockfile.Close()
}

func StoreCode(cache Cache, wasm []byte, persist bool) ([]byte, error) {
if cache.handle == nil {
return nil, fmt.Errorf("cache handle is nil")
}
checksum, err, _ := currentRuntime.StoreCode(wasm)
return checksum, err
}
26 changes: 22 additions & 4 deletions internal/runtime/wazeroruntime.go
Original file line number Diff line number Diff line change
@@ -99,7 +99,7 @@ func (w *WazeroRuntime) RemoveCode(checksum []byte) error {

mod, ok := w.compiledModules[csHex]
if !ok {
return errors.New("wasm file does not exist")
return errors.New("Wasm file does not exist")
}
mod.Close(context.Background())
delete(w.compiledModules, csHex)
@@ -108,12 +108,28 @@ func (w *WazeroRuntime) RemoveCode(checksum []byte) error {
}

func (w *WazeroRuntime) Pin(checksum []byte) error {
// no-op for wazero
if len(checksum) != 32 {
return errors.New("Checksum not of length 32")
}
w.mu.Lock()
defer w.mu.Unlock()
if _, ok := w.codeCache[hex.EncodeToString(checksum)]; !ok {
return errors.New("Error opening Wasm file for reading")
}
// no-op on success
return nil
}

func (w *WazeroRuntime) Unpin(checksum []byte) error {
// no-op for wazero
if len(checksum) != 32 {
return errors.New("Checksum not of length 32")
}
w.mu.Lock()
defer w.mu.Unlock()
if _, ok := w.codeCache[hex.EncodeToString(checksum)]; !ok {
return errors.New("Error opening Wasm file for reading")
}
// no-op on success
return nil
}

@@ -194,7 +210,9 @@ func (w *WazeroRuntime) GetMetrics() (*types.Metrics, error) {
}

func (w *WazeroRuntime) GetPinnedMetrics() (*types.PinnedMetrics, error) {
return &types.PinnedMetrics{}, nil
return &types.PinnedMetrics{
PerModule: []types.PerModuleEntry{},
}, nil
}

func (w *WazeroRuntime) callContractFn(fnName string, checksum, env, info, msg []byte) ([]byte, types.GasReport, error) {