Tarik Gulandbee344 c146727510 TransactionExtension, ExtrinsicV5 (#5976)
* TransactionExtension Start

* Add V5_VERSION logic to necessary classes

* Fix latest version to 5

* Add v5 dir

* Add v5 types to interfaces

* Cleanup paths

* Update ExtrinsicSignature V5

* Cleanup v5 folders

* nits

* signed works

* general works?

* Clean linter, and imports

* fix typing

* Change sign in v5 to hash all payloads

* remove SignV5Options

* Remove SignatureV5Options

* Change versioning

* added bitmasks

* cleanup

* change version to constant

* Add tests

* Decouple payload v5 from v4

* Add helper fn to get signed extension version from the registry

* Add version to encoding

* Cleanup tests

* renamed getSignedExtensionVersion to getTransactionExtensionVersion

* removed this.type for v5

* undo this.type removal

* replaced signedExtensionVersion by transactionExtensionVersion for v5 in ExtrinsicSignature

* unfinished Preamble Class

* Revert "unfinished Preamble Class"

This reverts commit 0b1c350fcc97e6f724ed84f66742be472c5daa71.

* Added test for decoding

* Fix test

* preamble typo

* updated GeneralExtrinsic [WIP]

* added generalExtrinsic

* General Extrinsic

* linting and renaming

* renaming

* Extend the v5 signed extrinsic test

* Unmask preamble

* Set payload to GeneralExtrinsicPayload

* Add test for GeneralExtrinsicPayload

* Start GeneralExtrinsicEncoded tests

* Add GeneralExt as a replacement class

* Export GeneralExt

* Fix nits

* Start decodeu8a

* GeneralExt tests

* GeneralExt fix

* updated decodeu8a

* Fix decoding

* Add error handling for invalid version

* remove fluff

* Fix version in GeneralExtrinsic

* fixes

* add parent class methods as errors

* Reorg some types

* Add test for GeneralExtrinsic

* Fix compatibility with GeneralExtrinsic

* fix structure of GeneralExtrinsic

* Add another test

* cleanup

* Fix decoding bug for bare

* fix change from bare to signed

* linting

* Fix encodinglength

* Set default to preamble to bre

* Fix tests

* fixed version setting

* Add test

---------

Co-authored-by: bee344 <alberto.penayo@parity.io>
2024-10-02 15:17:32 -04:00
2024-09-17 21:03:21 +03:00
2020-10-23 10:16:21 +02:00
2024-03-02 09:18:14 -05:00
2017-11-18 08:38:18 +01:00
2022-01-13 10:07:16 +02:00
2017-11-28 18:03:48 +01:00
2023-05-01 18:16:56 +03:00
2021-06-08 18:05:18 +03:00
2024-01-08 15:07:13 +02:00
2024-09-17 21:03:21 +03:00
2024-09-23 09:25:08 -04:00
2024-10-01 12:34:42 +00:00
2024-01-08 15:07:13 +02:00
2022-08-12 12:27:01 +03:00
2018-11-21 13:37:27 +01:00
2024-10-01 12:34:42 +00:00
2023-04-15 13:08:25 +03:00
2024-01-08 15:07:13 +02:00
2024-10-01 12:34:42 +00:00

@polkadot/api

This library provides a clean wrapper around all the methods exposed by a Polkadot/Substrate network client and defines all the types exposed by a node. For complete documentation around the interfaces and their use, visit the documentation portal.

If you are an existing user, please be sure to track the CHANGELOG when changing versions.

tutorials

Looking for tutorials to get started? Look at examples for guides on how to use the API to make queries and submit transactions.

S
Description
Fork of polkadot-js/api. Held for the @polkadot/types side of Quantus support — ExtrinsicSignature is MultiSignature (64/65 bytes) upstream, where Quantus needs a 5261/7219-byte DilithiumSignatureScheme. May turn out to need no patch at all if registry type overrides suffice; see quantus/api#1.
Readme
142 MiB
Languages
TypeScript 99.9%