near-sdk (Rust) 4.0.0-pre.3
This release comes with a few very minor API changes but also some new features. For up-to-date changes, see CHANGELOG.
- A pre-release, not marked stable on GitHub.
- The newest stable release in the 4.0 line: near-sdk (Rust) 4.0.0
- Newest near-sdk (Rust): near-sdk (Rust) 5.30.0
This release comes with a few very minor API changes but also some new features. For up-to-date changes, see CHANGELOG.
4.0.0-pre.3 [10-12-2021]
- Introduce
#[callback_result]annotation, which acts like#[callback]except that it returnsResult<T, PromiseError>to allow error handling. PR 554- Adds
#[callback_unwrap]to replacecallback
- Adds
- mock: Update
method_namesfield ofAddKeyWithFunctionCallto aVec<String>fromVec<Vec<u8>>. PR 555- Method names were changed to be strings in
4.0.0-pre.2but this one was missed
- Method names were changed to be strings in
- env: Update the register used for temporary
envmethods tou64::MAX - 2from0. PR 557.- When mixing using
sysandenv, reduces chance of collision for using0
- When mixing using
- store: Implement caching
LookupMaptype. This is the new iteration of the previous version ofnear_sdk::collections::LookupMapthat has an updated API, and is located atnear_sdk::store::LookupMap. PR 487.- The internal storage format has changed from
collections::LookupMapso the type cannot be swapped out without some migration.
- The internal storage format has changed from
- store: Implement caching
UnorderedMaptype. PR 584.- Similar change to
LookupMapupdate, and is an iterable version of that data structure. - Data structure has also changed internal storage format and cannot be swapped with
collections::UnorderedMapwithout manual migration.
- Similar change to