Commit Graph
404 Commits
Author SHA1 Message Date
Jaco Greeff 677e63b66e Payload Call as Bytes, test serialization (#1304)
* Payload Call as Bytes, test serialization

* Strip hex prefixes to method (signing & payload)
2019-08-13 18:21:46 +02:00
Jaco Greeff 604812d53d Static metadata update (#1301) 2019-08-13 09:53:29 +02:00
Jaco Greeff b9142bcf83 Add Forcing enum (staking) (#1300) 2019-08-13 07:36:56 +02:00
Jaco Greeff e942e68798 Swap to latest extrinsic version if no blocks found (#1298)
* Swap to latest extrinsic version if no blocks found

* Rename const
2019-08-12 14:25:05 +02:00
Jaco Greeff 2a5fd1caef Low-hanging circular deps (#1297)
* Low-hanging circular deps

* Cleanup Compact check

* Null does not allow .hash
2019-08-11 23:53:26 +02:00
Jaco Greeff 5ee2caf00e More small readability enhancements (#1296)
* More small readability enhancements

* Pacify CC on manual checks
2019-08-11 22:44:02 +02:00
Jaco Greeff 07b89e759c Some non-functionality readability cleanups (#1295)
* Some non-functionality readability cleanups

* Small Address cleanups
2019-08-11 21:45:16 +02:00
Jaco Greeff 7e3da636ea Cleanup, simplify, remove Fallback (type injection) (#1294) 2019-08-11 16:09:50 +02:00
Jaco Greeff e5cc6836eb BlockNumber, Nonce -> u32 (#1284)
* BlockNumber -> u32

* Interface types extend, not re-use

* Merge master, rebuild

* Merge typo

* Lazy create struct types (extended definitions)

* Cleanup tests for Nonce u32

* Remove polkadot u64 BlockNumber (substrate default)

* Warn on type dup & still clear

* Allow type overrides to work at any point
2019-08-11 15:07:00 +02:00
Jaco Greeff 1aa7899a7a Allow string types inputs into codec (#1292)
* Allow string types inputs into codec

* Linkage allows string constructors

* Import case

* Cleanup keyof imports

* Attempt linkage doc fix
2019-08-11 14:01:20 +02:00
Jaco Greeff b595428372 Lazily create registry types (also solves resolution order) (#1291)
* Lazily create registry types (also solves resolution order)

* Typo in comment

* Alphabetical definitions (ordering detected)

* Make fallback & SessionKeys work as expected

* Cleanup registration, user-types takes priority

* typo

* Api constructors only take options

* Cleanup typos

* Don't create classes while validating metadata

* Adjust badges... well, waiting for CI, so...

* typo
2019-08-10 14:24:04 +02:00
Jaco Greeff aa3de431ba Update VestingSchedule (#1289) 2019-08-10 09:50:26 +02:00
Jaco Greeff 1c885a25b0 Update Polkadot session keys (#1287) 2019-08-10 08:02:16 +02:00
Jaco Greeff 40cf70f415 Add polkadot attestations types (#1286)
* Add polkadot attestations types

* Config updates (misc, non-related)
2019-08-10 00:45:37 +02:00
Jaco Greeff 2e109ba2a5 Swap Keys to "Opaque" tuple definitions (#1281) 2019-08-09 09:19:47 +02:00
Jaco Greeff 2ddc87c70f Extract abrs author (#1278)
* ABRS types

* Extrcat abrs author
2019-08-07 23:34:25 +02:00
Jaco Greeff b2102d9a2b Cater for key definitions rework (#1269)
* Keys structure update

* Bump metadata, pull new keys

* Update for latest

* Update tests for new values

* Polkador session keys override

* Cleanup tests (browserlist adjustments)

* Update metadata

* Bump deps
2019-08-07 21:21:45 +02:00
Jaco Greeff 438c02def5 Add types for Polkadot claims module (#1277)
* Add types for Polkadot claims module

* ' instead of `

* Adjust types, `[u8; x]` workarounds

* One less import

* Map [u8; x] -> Uint8Array

* Fix Codec imports
2019-08-07 18:08:38 +02:00
Jaco Greeff 3d8fbcf107 Making interfaces less noisy (#1276)
* Making interfaces less noisy

* Wrap loose-standing parts into a main
2019-08-07 13:52:35 +02:00
Jaco Greeff 1b94f0ca7f Vote decoding tweaks (#1270) 2019-08-06 11:09:58 +02:00
Jaco Greeff 21e2d2843e AuthorityIndex -> u32 (#1261)
* AuthorityIndex -> u32

* Interface update

* Run build:interfaces as part of build command
2019-08-03 09:38:47 +02:00
Jaco Greeff 782f4f1f54 Support new v3 extrinsic (payload with genesisHash) (#1248)
* Make a start, copy stuff

* Payload adjusted

* Linting

* Small cleanups after testing

* Some duplication cleanups (yes... this needs work)

* Slightly less duplication (still not great)

* Typo in getter
2019-08-02 14:36:08 +02:00
Amaury Martiny 92044d471c Make api.rpc.*.* typed (#1237)
* Generate correctly

* Fix rpc-core

* Flexible types

* Make types work!

* Lint

* Fix grumble

* Re generate

* Fix lint

* Fix small bugs

* Maybe really fix lint?

* Fix lint again

* Fix lint

* Small ordering & formatting  changes while playing...
2019-08-01 10:46:28 +02:00
Jaco Greeff 6999f8c71f Fix doc generation for DoubleMap (#1245)
* Fix doc generation for DoubleMap

* Add ; - VSCode, why are you failing me? ...
2019-07-31 15:01:21 +02:00
Jaco Greeff ddc46ed237 Re-add StorageData from 0.82.0-beta.96 (not an alias) (#1240) 2019-07-31 09:07:44 +02:00
Jaco Greeff e70f26d957 Align const method names (#1234) 2019-07-30 13:17:00 +02:00
Jaco Greeff 03581355be Add author_removeExtrinsic RPC (#1233) 2019-07-30 13:16:20 +02:00
Jaco Greeff c90a4ba69d Bump metadata (#1231) 2019-07-30 08:14:50 +02:00
Jaco Greeff 54e9a81f5f MemberCount is u32 (#1230)
* MemberCount is u32

* Generate, add interfaces to ignore

* Marge master
2019-07-30 07:09:55 +02:00
Xiliang Chen 0323b27da4 Generic Asset module type definitions (#1229)
* Fix missing type import for generated code

* Add GenericAsset module type definations

* eslint --fix
2019-07-30 06:47:14 +02:00
Jaco Greeff 0d68f98c75 Extra block author for babe (#1227)
* Update examples for 0.90

* Fix number typo

* Adapth to use timestamp.now (blockPeriod now in all versions)

* Babe extract block author

* TODO for cleaner aura extraction

* Update Babe id

* Update & split tests
2019-07-29 21:23:34 +02:00
Jaco Greeff fe35527a65 Method -> Call, expose findMethod on api (#1222)
* Rename Method -> Call (interface, align with Rust)

* Export Call types from types, expose findCall
2019-07-29 09:04:37 +02:00
Jaco Greeff a06db4cfb9 Swap isPedantic to warn (with fallback) (#1221)
* Swap isPedantic to warn (with fallback)

* Remove extra instanceof

* One less check (toU8a implies codec)

* Comment typo

* Handle fallback grecefully
2019-07-28 10:45:26 +02:00
Jaco Greeff 38e8ad659a Cleanup isPedantic mismatches (#1220)
* Don't assert, warn on isPedantic mismatches

* Re-apply assert
2019-07-28 09:23:22 +02:00
Jaco Greeff 4094b44625 Linked queries accept params again (#1217)
* Linked queries accept params again

* Remove invalidated test, cleanup prefix strip
2019-07-27 23:58:09 +02:00
Jaco Greeff 8aed9a4170 Fix decoding of unsigned extrinsics (#1216) 2019-07-27 20:42:27 +02:00
Jaco Greeff e833069d1e Update to latest metadata (#1215) 2019-07-27 20:00:01 +02:00
Jaco Greeff 5280874fbe Remove TypeDef duplication (#1211) 2019-07-27 11:25:50 +02:00
Jaco Greeff 3db898d104 Moment as definition, u64 (#1210)
* Moment as definition, u64

* Move Signature (just above extrinsic/block)

* Ordering

* Vec<u8> === Bytes, re-introduce injected type checks
2019-07-27 10:57:06 +02:00
Jaco Greeff d516e9eefc Adjust session Keys for Babe (#1209) 2019-07-27 08:53:48 +02:00
Jaco Greeff 99368a6d4d createType allows multiple params (#1207) 2019-07-27 08:05:11 +02:00
Jaco Greeff d56905d1b5 Move Extrinsic/Method to generic (#1205)
* Move Extrinsic/Method to generic

* Strip Generic* primitives

* Move Origin & Method, pass lint/tests
2019-07-26 18:04:33 +02:00
Jaco Greeff b3431ce892 Don't export I/U{8|6|32|64|128|256} only lowercase (#1204) 2019-07-26 17:15:58 +02:00
Jaco Greeff 02cd1331aa Move Event, Address, AccountId, AccountIndex to generic (#1202)
* Move Event, Address, AccountId, AccountIndex to generic

* Move AccountId, AccountIndex, Address & Event to generic

* Move Vote
2019-07-26 16:39:28 +02:00
Amaury Martiny 894f07e3c9 Fix moment is compact again (#1201) 2019-07-26 15:54:50 +02:00
Jaco Greeff 70bc823d25 Make Block, Header & Digest generic (#1196)
* Make Block, Header & Digest generic

* It lints

* Linting passes, tests passes
2019-07-26 14:34:41 +02:00
Amaury Martiny 441148889d CreateType is typed, add createTypeUnsafe just in case (#1199)
* Use unsafe internally

* Add comments

* Remove <> in createType

* Fix lint

* Fix classOf

* Remove createType from Text

* Fix lint

* Fix Fallback type

* Fix fallback in createType
2019-07-26 14:00:25 +02:00
Amaury Martiny ec0b9a84a3 Put all mapping of InterfaceRegistry in one file (#1200)
* Remove module augmentation

* Put all definitions in one file

* Add back compacts
2019-07-26 13:53:12 +02:00
Jaco Greeff 2a37b8746d Rename srml to interfaces (#1198)
* Rename srml to interfaces

* newline, package.json
2019-07-26 12:08:17 +02:00
Jaco Greeff a0d7a52a5c Add hash: IHash on Codec base (#1193)
* Convert RPC classes to primitive classes or /srml types

* Lint passes... lokking at tests next.

* Tests pass.

* Types with basic docs (lots of work here)

* Add hash: IHash on Codec base

* codec hash resturns U8a

* Fix imports
2019-07-26 11:20:34 +02:00