Skip to content

Commit

Permalink
Adjust naming of allHead notifications (#227)
Browse files Browse the repository at this point in the history
* Adjust naming of `allHead` notifications

* CHANGELOG entry

---------

Co-authored-by: Pierre Krieger <[email protected]>
  • Loading branch information
skunert and tomaka authored Feb 24, 2023
1 parent 2bd5965 commit 890f31a
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 1 deletion.
1 change: 1 addition & 0 deletions lib/src/json_rpc/methods.rs
Original file line number Diff line number Diff line change
Expand Up @@ -503,6 +503,7 @@ define_methods! {
author_extrinsicUpdate(subscription: Cow<'a, str>, result: TransactionStatus) -> (),
chain_finalizedHead(subscription: Cow<'a, str>, result: Header) -> (),
chain_newHead(subscription: Cow<'a, str>, result: Header) -> (),
chain_allHead(subscription: Cow<'a, str>, result: Header) -> (),
state_runtimeVersion(subscription: Cow<'a, str>, result: Option<RuntimeVersion<'a>>) -> (), // TODO: the Option is a custom addition
state_storage(subscription: Cow<'a, str>, result: StorageChangeSet) -> (),

Expand Down
2 changes: 1 addition & 1 deletion light-base/src/json_rpc_service/state_chain.rs
Original file line number Diff line number Diff line change
Expand Up @@ -490,7 +490,7 @@ impl<TPlat: Platform> Background<TPlat> {
.requests_subscriptions
.try_push_notification(
&state_machine_subscription,
methods::ServerToClient::chain_newHead {
methods::ServerToClient::chain_allHead {
subscription: (&subscription_id).into(),
result: header,
}
Expand Down
1 change: 1 addition & 0 deletions wasm-node/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
## Fixed

- Fix panic when the input data of a Wasm function call is larger than a Wasm page. ([#218](https://github.com/smol-dot/smoldot/pull/218))
- Subscriptions to the `chain_subscribeAllHeads` JSON-RPC function now generate notifications named `chain_allHead`, like in Substrate. They were erroneously named `chain_newHead`. ([#227](https://github.com/smol-dot/smoldot/pull/227))

## 0.7.12 - 2022-02-22

Expand Down

0 comments on commit 890f31a

Please sign in to comment.