Commit Graph

113 Commits

Author SHA1 Message Date
Andrew Jones 4ed8e37ffe Fix up contracts pallet tests (#163)
* Revert contracts put_code test to pure code (not using the macro)

* Test contract instantiate

* Fmt
2020-09-15 08:32:33 +01:00
Greg Hill 2829d7d7c1 fix option decoding and add basic sanity test (#161)
Signed-off-by: Gregory Hill <gregorydhill@outlook.com>
2020-09-15 08:24:05 +01:00
David Ackerman f2cf79847a Remove visibility limiter pub (crate) from Metadata (#162)
* Remove visibility limiter `pub (crate)`

* Run fmt

* Add comments
2020-09-14 15:51:42 +01:00
Greg Hill e85d01ed08 decode option event arg (#158)
Signed-off-by: Gregory Hill <gregorydhill@outlook.com>
2020-09-07 14:58:45 +01:00
Andrew Jones af45c39fb1 Release v0.12.0 (#157)
* Bump version, update changelog

* Bump proc-macro crate

* Bump client crate
v0.12.0
2020-09-01 15:54:01 +01:00
David Craven e9c50e21d0 Only return an error if the extrinsic failed. (#156) 2020-09-01 11:15:04 +01:00
David Craven 3ea9d3b8bb Update to rc6. (#155)
* Update to rc6.

* Fix clippy warnings.
2020-08-25 09:50:14 +01:00
David Craven eac2ce3b2a Different assert. (#153) 2020-08-17 09:14:26 +01:00
Yuanchao Sun 59b9c117b7 Add a method to fetch an unhashed key, close #100 (#152)
* Add a method to fetch an unhashed key, close #100

* Return decoded value

* Refactoring
2020-08-13 21:06:30 +01:00
David Craven 9aa32ef63d Fix port number. (#151) 2020-08-13 16:04:30 +01:00
Demi Obenour 511e6f5a16 Implement the concat in twox_64_concat (#150)
Co-authored-by: Demi M. Obenour <demiobenour@gmail.com>
2020-08-10 11:05:17 +01:00
David Craven 271775bf99 Storage map iter (#148)
* Add example file

* Fmt

* Add KeyIter.

* Add iter method to store proc-macro.

* Fetch all values at once.

* Update docs.

* Run rustfmt.

Co-authored-by: Andrew Jones <ascjones@gmail.com>
2020-08-05 09:08:12 +01:00
Andrew Jones 663934ca37 Fetch paged storage keys 2020-08-03 12:40:37 +01:00
Andrew Jones d3e7bd2282 Release v0.11.0 (#145)
* Bump versions

* Update changelog

* Update PR links

* Fix changelog linebreak

* Remove explicit wabt-sys dependency

* Update changelog

* Update parity-scale-codec version
v0.11.0
2020-07-31 11:02:21 +01:00
hewigovens cb23cb24e0 Fix build error, wabt 0.9.2 is yanked (#146) 2020-07-31 08:29:48 +01:00
David Craven e6f3a82f99 Rc5 (#143)
* Update to rc6.

* Update runtime.

* Update node to rc6.

* Update client.

* Fix node.

* Add option to enable telemetry.
2020-07-27 08:53:02 +01:00
Andrew Jones cd6b8f43f1 Refactor: extract functions and types for creating extrinsics (#138)
* Extract extrinsic

* Extract extrinsic types to own module

* Fix compiler errors

* Fix warnings

* Fmt

* Pin wabt-sys to 0.7.1, it fails (on my machine) with 0.7.2

* Fix up tests

* Fmt

* Reexport RuntimeVersion
2020-07-20 09:17:19 +01:00
Amar Singh 015a819759 event subscription example (#140)
* added example

* fmt
2020-07-16 08:09:03 +01:00
David a4ba74ed72 Document the Call derive macro (#137)
* Document the `Call` derive macro

* Obey the fmt

* Update proc-macro/src/lib.rs

Co-authored-by: Andrew Jones <ascjones@gmail.com>

* Review feedback

Co-authored-by: Andrew Jones <ascjones@gmail.com>
2020-07-07 08:20:58 +01:00
David 536c54c843 Document the #[module] macro (#135)
* Document the #[module] macro

* Obey the fmt

* Review feedback

* More docs

* Tweak wording

* tweak wording

* whitespace

* Tweak docstring
2020-07-07 08:19:44 +01:00
David Craven c6350fcc11 Support authors api. (#134) 2020-07-01 15:27:14 +01:00
Andrew Jones 4265dd6a69 Release client v0.2.0 (#133)
* Bump client version

* Bump client dev dependency version

* Changelog

* Bump subxt version
2020-06-29 13:21:20 +01:00
Andrew Jones f08f316741 Release client v0.2.0 (#133)
* Bump client version

* Bump client dev dependency version

* Changelog

* Bump subxt version
2020-06-29 11:44:33 +01:00
Andrew Jones cc25207a2a Release client v0.2.0 (#133)
* Bump client version

* Bump client dev dependency version

* Changelog

* Bump subxt version
2020-06-29 10:12:21 +01:00
Andrew Jones d3e9e3f757 Upgrade to substrate rc4 release (#131)
* Upgrade to substrate rc4 release

* Fix up test-node/service

* Fix up client node config

* Fix up remaining compilation errors

* Fmt

* Remove fixme

* Fix test

* Release v0.10.0
v0.10.0
2020-06-29 09:32:07 +01:00
David Craven 4ee7fb11ad Support unsigned extrinsics. (#130) 2020-06-26 07:38:37 +01:00
Andrew Jones 5fd83f8bdb Release v0.9.0 (#129)
* Bump version, update changelog

* Add client version
v0.9.0
2020-06-25 10:49:28 +01:00
David Craven 7f0847107c Events sub (#126)
* Make event subscription logic more generic.

* Fix build.

* Add test-node.

* Update deps.

* Address review comments.
2020-06-25 07:05:00 +01:00
David Craven 3080ec91a6 Improve error handling in proc-macros, handle DispatchError etc. (#123)
* Improve error handling.

* Fix build.

* Handle runtime errors.

* Add runtime trait for better type inference.

* Use runtime trait part 1.

* wip

* Add support for sudo.

* Finish error handling.

* Fix tests.

* Fix clippy warnings.
2020-06-22 07:39:40 +01:00
David Craven 21d07c6c24 Support embedded full/light node clients. (#91)
* Add support for light clients.

* Add wasm toolchain to ci.

* Fix ci tests.

* Address review comments.

* Use expect instead of unwrap.

* Purge light client chain too.

* Add README section.
2020-06-15 08:01:16 +01:00
David Craven 91203b91d3 Zero sized types (#121)
* Fix zero sized types.

* Cleanup.

* Expose genesis hash.

* Fix clippy warnings.

* Readd default type sizes for now.

* Cleanup ret type.
2020-06-08 12:25:51 +01:00
David Craven 26ada75dec Fix optional store items. (#120)
* Fix optional store items.

* Support querying a block hash.
2020-06-01 12:24:56 +01:00
Demi Obenour a2eead0c3d Make signing fallable and asynchronous (#119)
* Make signing fallable and asynchronous

This is needed for hardware wallets, which require human confirmation to
sign transactions.  Blocking on a human to sign transactions is not a
good idea, and the signing might fail for many reasons (device
unplugged, authorization not granted, etc).

* Reformat

* Refactor as suggested by Andrew Jones (@ascjones).

* Use future::ok

Co-authored-by: Andrew Jones <ascjones@gmail.com>
2020-05-29 08:49:27 +01:00
Andrew Jones 5f9ebf28da Release v0.8.0 (#117)
* Bump version to 0.8

* Update changelog
v0.8.0
2020-05-26 14:53:52 +01:00
Andrew Jones 0d58f4b67c Update to Substrate release candidate (#116)
* Substrate rc1

* Add tx version extra

* Remove CheckBlockGasLimit

* Substrate rc2
2020-05-26 13:53:08 +01:00
David Craven 4dadb2c9b5 Update to alpha.8 (#114) 2020-05-26 10:55:54 +01:00
David Craven 67f3ce529e Refactors the api (#113)
* Refactor api.

* Try fix ci.

* Fix test.

* Address review comments.
2020-05-26 10:04:44 +01:00
Andrew Jones 6e6a8bbd28 Substrate alpha.8 2020-05-22 07:39:35 +01:00
Andrew Jones bec7e47d8c v0.7.0 release extras (#110)
* Explicit proc-macro version for crates.io release

* Upgrade partity-scale-codec

* Add proc-macro crate metadata
v0.7.0
2020-05-13 10:16:04 +01:00
Andrew Jones e8b4eb3030 Release v0.7.0 (#109)
* Bump version and update changelog

* Add link to examples in README
2020-05-13 09:13:53 +01:00
David Craven f861f3fac4 Split subxt (#102)
* Proc macro improvements.

* Use proc-macros.

* Update examples.

* Fix build.

* Run rustfmt.

* Fix total issuance test.

* Remove gas limit from put code call.

* Handle runtime errors.

* Fix tests.

* Make test more reliable.

* Revert "Handle runtime errors."

This reverts commit 26f30a9f4cfcfddfb3e49308cded46cfe6468697.

* Use expect instead of unwrap.

* Parse marker type.

* Fetch doesn't fail.
2020-05-12 12:25:22 +01:00
Yuanchao Sun 825f3ab64c Add support for RPC state_getReadProof (#106)
* Add support for RPC `state_getReadProof`

* Format code

* Add test
2020-05-07 07:41:27 +01:00
Andrew Jones f2c42f88cf Update to substrate alpha.7 release (#105)
* Update to substrate alpha.7

* Remove gas limit from contracts put code

* Rename SystemEvent::ReapedAccount to KilledAccount

* Log debug event received before attempting to decode

* Temporary registration of Balance type before #102 merged

* Show contract test errors, increase instantiate gas_limit
2020-05-06 09:15:14 +01:00
Cody Lamson 5001a161d7 file updates for license recognition (#101)
* file updates for license recognition

* update rustfmt to use FILE_TEMPLATE
2020-05-04 10:00:26 +01:00
Andrew Jones 194c7bcf2f Add missing license headers and CI check (#98)
* Add missing license headers and add CI check

* Remove log line

* Remove stale todos
2020-04-30 22:26:22 +01:00
David Craven 6f27489378 Double map and plain storage support, introduce macros (#93)
* Support custom clients.

* Simplify trait bounds.

* Plain and double map storage support.

* Simplify more trait bounds.

* Add proc macro.

* Add Call, Event and Store traits.

* Update proc-macros.

* Add with_system for proc-macro.

* proc-macro: test: support signature and extra fields.

* proc-macro: test: support sharing state accross steps.

* proc-macro: test: fetch state sequentially.

* Elide lifetimes.

* Add test for plain storage.

* Run rustfmt.
2020-04-28 20:04:26 +01:00
bwty 216b5614dd Raw payload return SignedPayload struct (#92)
* create SignedPayload struct

* align with generic extra updates

Co-authored-by: bwty <whalelephant@users.noreply.github.com>
2020-04-20 07:25:37 +01:00
Andrew Jones b8159efcab Release v0.6.0 (#90)
* Update to substrate alpha 6

* Bump version and add release notes

* Upgrade async-std dev dependency

* Fix readme license links
v0.6.0
2020-04-15 09:40:14 +01:00
Andrew Jones dc2a73dc4a Wrap and export BlockNumber (#87)
* Add fetch example and wrap BlockNumber impl

* Fmt
2020-04-15 08:45:58 +01:00
David Craven 8cf652605f Custom extra (#89)
* Run rustfmt.

* Make extra customizable.

* Update to alpha 6.
2020-04-15 08:21:19 +01:00