Commit Graph

58 Commits

Author SHA1 Message Date
Alex Peters
4a1d1b1e42 Add factory contract scenario 2022-09-14 10:42:03 +02:00
Alex Peters
ccb2fdd0b6 Make contract addresses predictable 2022-09-09 12:42:41 +02:00
Alexander Peters
42758d3a13 Rename features to availableCapabilities (#993)
* Rename features to availableCapabilities as in wasmvm

* Review feedback
2022-09-09 09:22:31 +02:00
Alexander Peters
0e41c8cc1c Better wasmvm 1.1 integration test (#988)
* Add cosmwasm_1_1 cability, bump reflect contract, supply query integration test

* Review feedback
2022-09-09 08:36:00 +02:00
Alex Peters
f9912e9333 Test contract history order 2022-09-08 14:48:57 +02:00
Alexander Peters
e714fdf3b4 Charge gas to unzip wasm code (#898)
* Charge gas for unzip wasm code

* Add uncompress test

* Apply review feedback

* Add testcase to uncompress spec
2022-08-31 16:17:03 +02:00
Jacob Gadikian
4875db2055 depracte-ioutil (#934) 2022-08-24 10:21:16 +02:00
Alex Peters
20fb936205 Fix keeper test 2022-08-24 08:54:57 +02:00
Alexander Peters
9d63bc061c Merge pull request #901 from CosmWasm/access_config
Restrict code access config modifications
2022-08-23 17:03:31 +02:00
Alex Peters
e5ff7c195a Restrict code access config modifications 2022-07-08 14:28:45 +02:00
Alex Peters
ffd8a3c871 Prevent migration to a restricted code 2022-07-08 13:13:21 +02:00
Ethan Frey
2b0b1677df Prepare release notes for 0.27 (#860)
* Add warning notes about intertx

* Update CHANGELOG

* Run all tests on m1 as it is stable now
2022-05-17 13:13:57 +02:00
Ethan Frey
27d30513b2 Add a few more tests as requested in review 2022-05-10 16:25:11 +02:00
Ethan Frey
a67dae70b7 Enforce permission less permissive than default 2022-05-10 16:09:35 +02:00
Ethan Frey
bff3aff95b Run new "make format" 2022-05-09 22:34:26 +02:00
Alexander Peters
bfb4d31fca Consolidate MaxWasmSize constraints into a single var (#826)
* Convert MaxWasmSize to var

Also removes redundant maxWasmSize param

* Convert MaxWasmSize to int

* Update CHANGELOG

* Complete max wasm size changes

* Update compile flags

Co-authored-by: Cole Brown <bigswim@gmail.com>
2022-04-29 18:54:06 +02:00
Simon Warta
72062f160e Upgrade wasmvm to v1.0.0-beta10 2022-04-06 14:02:49 +02:00
Ethan Frey
feeccb666b Mark a whole lot of tests to skip on m1 as they core dump 2022-03-07 22:09:39 +01:00
Ethan Frey
3acc8c960c Expose SetParams as I will need that for migration code outside of this package 2022-01-24 13:46:18 +01:00
Alexander Peters
b8319aa334 Upgrade to cosmos-sdk v0.45.0 (#717)
* Upgrade to cosmos-sdk v0.44.5

* Upgrade to sdk v0.45.0-rc1

* Fix local test deploy scripts

* Bump to v0.45.0 final release

* Fixed replace to 0.45.0 not rc1

* Fix changed import path since rc1

Co-authored-by: Ethan Frey <ethanfrey@users.noreply.github.com>
2022-01-20 12:47:01 +01:00
Alexander Peters
dfba1395d9 Fix message representation for signing (#658)
* Introduce RawContractMessage type

* Add json signbytes test for proposals

* No assumptions on MsgIBCSend.data content

* Smart query uses RawContractMessage

* Revert method signature change to be consistent

* Review comment

* Update after discussions
2021-10-25 15:23:19 +02:00
fkneeland-figure
57517b0c33 Add golangci lint check on pull requests (#645)
* added golangci lint check on pull requests

* changelog update

* updated to use circleci instead of github actions

* testing a golang change

* added workflow

* updated how we find the golangci command in the make file

* using orb for golangci

* Added golangci install make command

* use docker image for golangci

* stop using make in circleci

* reverted golang change to trigger ci

* gofmt

* make fmt

* fixed a few things

* updated version on golintci

* fixed all the lint errors

* check version

* skipped wrongly failing lint

* Revert generated file changes

* fix import grouping, return errors on failures, initialization of arrays revert

* fixed a few lint errors

* addressed more code review comments

* updated with error check

* increased timeout for golangci-lint

* dont format autogenerated files

Co-authored-by: Carlton Hanna <channa@figure.com>
2021-10-25 09:09:47 +02:00
fkneeland-figure
dd390d7f5f Go Formatting update (#648)
* make fmt

* changelog update
2021-10-21 14:54:16 +02:00
Alexander Peters
bc7a52260d Update gas costs (#636)
* Update gas costs

* Review feedback

* Review comments
2021-10-08 14:34:44 +02:00
Alexander Peters
62e976a551 Upgrade wasmvm-v1.0.0-soon2 (#628)
* Upgrade wasmvm-v1.0.0-soon2

* Improve comment on DefaultGasMultiplier

Co-authored-by: Simon Warta <simon@warta.it>
2021-10-07 14:11:37 +02:00
Alexander Peters
58f3776f6e Implement tx counter for transaction info (#621)
* Implement tx counter for transaction info

* Count tx before pre-conditions

* Doc update
2021-09-27 21:53:01 +02:00
Ethan Frey
5c42c10b71 Adjust gas prices for new contracts 2021-09-22 19:19:58 +02:00
Ethan Frey
f5dc720926 Important: add iterator feature support 2021-09-22 19:11:49 +02:00
Alexander Peters
a447ee0c12 Ensure query isolation (#611)
* Ensure query isolation

* Review feedback
2021-09-14 17:25:05 +02:00
Alex Peters
2fe56bffaf Fix query handler instantiation 2021-09-13 09:48:31 +02:00
Piotr Husiatyński
b2fc913398 Keeper tests (#590)
* More keeper tests

x/wasm/keeper tests are extended to test various input validation.
Keeper input is validated before passing to the keeper method when used
within wasmd application. We cannot ensure such validation when this
keeper is used outside of wasmd application. To keep it safe, fully
validate keeper methods input.

hackatom.wasm is loaded into memory during initialization to avoid
reading file in each test separately. Once migrated to go 1.16, embed
package should be used instead.

Run goimport on certain files.

Some comments fixed or removed.

* ensure that creator address is not nil
2021-08-27 15:37:07 +02:00
Ethan Frey
f51ec67099 Remove (now-unneeded) filtering in DefaultWasmVMContractResponseHandler.Handle 2021-08-12 13:36:22 +02:00
Alex Peters
7b2cfa48ed Strip message events and reorder 2021-08-11 14:08:56 +02:00
Alex Peters
7bc048e1ed Add tests for events 2021-08-11 13:12:46 +02:00
Alex Peters
e9156be200 Refactor events 2021-08-10 18:19:16 +02:00
Ethan Frey
12b6eb4fa8 Update gas price 2021-07-28 23:05:05 +02:00
Ethan Frey
b34290772b Adjust gas prices in tests 2021-07-28 13:06:09 +02:00
Ethan Frey
c9360f63d1 keeper and types pass tests 2021-07-28 11:24:44 +02:00
Ethan Frey
6bde321974 x/wasm/keeper compiled 2021-07-28 11:24:44 +02:00
Ethan Frey
92850081f0 Fix last tests 2021-07-28 11:18:58 +02:00
Ethan Frey
b8b0f209b2 Update tests (new default contract addr) 2021-07-28 11:18:21 +02:00
Ethan Frey
81c46ae567 Use _contract_address attribute in emitted events 2021-07-21 22:15:49 +02:00
Alex Peters
b0b1fa88bc Upgrade wasmvm v0.15.x 2021-07-07 09:53:03 +02:00
Alexander Peters
c05df881fb Charge gas for custom event attributes and messages (#539)
* Charge gas for custom event attributes

* Introduce gas register for gas costs

* Review feedback

* Tests and minor updates

* Godoc
2021-06-25 10:00:46 +02:00
Alex Peters
0dd695c126 Cleanup keeper result types 2021-06-11 12:38:30 +02:00
Alex Peters
470b2dacc7 Test Pinned contract does not loop forever 2021-06-07 11:28:10 +02:00
Alex Peters
2f2d59a151 Allow access to contract address builder 2021-06-01 10:42:07 +02:00
Alexander Peters
3d4b3d184f Upgrade to wasmvm v0.14.0-rc1 (#508)
* Upgrade to wasmvm v0.14.0-rc1

* Update contracts from cosmwasm#910, re-enable test

* Fix parsing in query type

Co-authored-by: Ethan Frey <ethanfrey@users.noreply.github.com>
2021-04-30 08:26:41 +02:00
Alexander Peters
305f13cc0a Submessage reply can overwrite caller response (#502)
* Reply may overwrite result data

* Fix interface name

* Refacting for tests

* Test response handler

* Fix naked error
2021-04-27 14:00:42 +02:00
Alex Peters
8c7967e5b4 Review feedback 2021-04-27 09:04:58 +02:00