Skip to content
This repository has been archived by the owner on Apr 15, 2024. It is now read-only.

v1.2.0

Compare
Choose a tag to compare
@DyrellC DyrellC released this 06 Oct 19:39
· 545 commits to develop since this release
b94da49

Changelog

All notable changes to this project will be documented in this file.
The format is based on Keep a Changelog,
and this project adheres to Semantic Versioning.

[1.2.0] - 2021-10-06

This version is not reverse compatible with v1.1.0

Added

- Added fetch_prev_msg and fetch_prev_msgs
- State reset available
- Allow transport to be clonable
- Added single depth channel implementation and example
- Added manual subscription/unsubscription for Authors
- Reintroduce unsubscribe message 
- Added guards against adding existing users 
- Added reset_state to author api
- Added announcement_link function 
- New workflows and actions for PR's, including compiling c and wasm bindings
- Select transport in .env in examples

Removed

- Removed encoding and payload length, replaced with implementation type enum
- All core functions converted to async (removing double api)
- Removed Subscriber::recover (it is unnecessary now without internal sync)
- Remove all cargo.locks from git state

Changed

- Unified state storage for pk's and psk's
- Refactored Client to allow for use of existing iota.rs client features including authentication and permanode support
- Corrected error message discrepancy for missing links
- Updated Author::recover to not conduct internal sync
- Fixed a panic in fetch_prev_msgs if a user tries to walk too far back 

Other

Bindings

- Add all new functions and bring to feature parity
- Cleanup and channels.h updates
- Exposed Address::toMsgIndex 
- WASM api refactor for getters/setters/copy

Development

- General linting fixes, performance refactoring
- Doc migration to Docusaurus, all docs available in IOTA wiki 
- Began setting up testing procedure for WASM

Breaking Changes

Protocol

  • Messages are now indexed with the binary digest of the blake2b256 hash of the Message's Address . Messages from previous versions were indexed with the hexadecimal encoding of this digest, resulting in indexes twice as large. This change implies that messages sent with prior versions of Streams won't be found when using Streams v1.2.0 or newer.

Rust

  • Author::new and Subscriber::new signatures has changed
  • sync client has been removed, Streams is now async only. Use block_on() of your preferred runtime to make it sync
  • Address::from_str now takes a single string (the whole string returned by Address::to_string(). It requires importing FromStr trait.
  • Address::to_string() now requires importing ToString
  • Display for Address now outputs the String "<channel-address>:<msgid>" in hexadecimal (the reciprocal of Address::from_str. The hash used for indexing the messages can be obtained with Address::to_msg_index()
  • Author::send_keyload(..) now takes an iterable of &Identifier as parameter, which can be either Identifier::edPubKey or Identifier::PskId

Wasm

  • patching global with node-fetch is no longer needed (but adding node-fetch in the dependencies is still required)
  • SendOptions constructor signature has changed
  • Author constructor signature has changed
  • Address#to_string() has been renamed to Address#toString()
  • Address.from_str has been renamed to Address.parse and takes 1 single string now (that outputted by Address#toString()
  • UserResponse#get_link() method has been removed in favour of accessing to the attribute UserResponse#linkdirectly
  • UserResponse#get_seq_link() method has been removed in favour of accessing to the attribute UserResponse#seqLinkdirectly
  • UserResponse#get_message() method has been removed in favour of accessing to the attribute UserResponse#messagedirectly
  • Message#get_pk() has been renamed Message#get_identifier()
  • Client has been renamed StreamsClient, to make room for iota.rs Client which can now be instantiated from @iota/streams either directly of with a ClientBuilder