Files
api/CHANGELOG.md
T
Jaco Greeff c1a6f0230c Cater for signature over hash (with version checks) (#655)
* Cater for signature over hash (with version checks)

* Allow Submittable signAndSend

* isUndefined for nonce check

* .sign with backwards compat

* e2e tests started

* Work around optional callback for Promise

* Commit actual e2e test

* Promise allows for submitExtrinsic

* e2e tests are passing

* Bump version, update CHANGELOG
2019-01-31 18:01:14 +01:00

2.4 KiB

0.42.1

  • Support for substrate hash signing with implVersion >= 18
  • Changed signatures for Extrinsic signing, this should not have (much) of an impact since it is generally not used directly. SubmittableExtrinsic (as exposed by the API), supports the old-style use.

0.41.1

  • Support the V1 metadata specification from Substrate in addition to the currently testnet-active V0 version

0.40.1

  • The API interfaces now require a WS-compatible provider, e.g. subscription support is a must. Previously the HTTPProvider could be use (although it was very limited in the interactions).

0.39.1

  • The Promise API now returns a Promise<UnsubFunction> instead of UnsubFunction when making subscriptions.

0.38.1

Substrate has been updated with a breaking new transaction format where the Index/Nonce is now encoded as a Compact. This change is being rolled out to both Alexander (Polkadot testnet) as well as Charred Cherry (Substrate testnet) - transactions between old and new are not compatible.

0.37.1

api-observable has been removed. This was only used in /apps and inconsistent with the api/rx and api/promise APIs. Future work will include derivates like was included in api-observable into the base.

Tuples now return single types when only one type is available, i.e. (AccountId) would now resolve as AccountId. The extra type wrapper adds no benefit to users here.

0.36.1

Api Promise has been updated in the way we deal with subscriptions. Previously a subscription returned Promise<number> where the caller was to keep track of the id and use it in subsequent unsubscribes. Now any subscriptions return an unsubscribe/destroy function (): void, that is use for removing the subscriptions, e.g.

const unsubscribe = api.query.balance.freeBalance(Alice, (balance) => {...});

unsubscribe(); // here we destroy the subscription

0.35.1

Swapped to new metadata structures from Substrate. If the API is not working with your node, update Substrate to latest master branch. (Or 0.9.1 for Charred Cherry). Dropped support for old metadata as found as far back as BBQ Birch.

0.34.1

Changed the send signature (for future expansion of eg. events) to return result: { status: ExtrinsicStatus } instead of status: ExtrinsicStatus. For most cases where only status type checks are used, i.e. status.type === 'Finalised' this should not be a breaking change. Deep inspection of the status object however will need to adapt.