v4.0.0-beta.1
Pre-release
Pre-release
·
744 commits
to master
since this release
This supersedes #1590, but RC coming soon™
Version 4.0.0-beta.1
The coolest feature included in this release is the first first published version of
ink!'s native "end-to-end" (E2E) testing framework.
This enables testing of a contract by deploying and calling it on a Substrate node with
pallet-contracts. See the erc20 example for usage.
Breaking Changes
This release includes a couple of breaking changes.
- The
CallBuilder::returns()method does not require an extraMessageResultanymore
as the type is now added under the hood (#1525) - The
CallBuilder::invoke()andCreateBuilder::instantiate()methods now unwrap the
Resultfrompallet-contractsunder the hood (#1602)
If you wish to handle the error use the newtry_variants of those methods instead. - The
CallBuilder::fire()method has been renamed toinvoke()
(#1604) - The
returns_resultflag has been removed from the#[ink(extension = …)]attribute
(#1569)
We now infer this information at compile time. Ifhandle_statusis set totrue,
the return type will still be wrapped intoResultas before. - The Minimum Supported Rust Version (MSRV) has been set to
1.63.0. This was already
the case, but previously it was enforced bycargo-contractinstead of ink!
(#1609)
Added
Fixed
- Add Determinism enum from pallet-contracts ‒ #1547
- Added missed
WhereClosurefor the generics intostorage_item‒ #1536 (thanks @xgreenx)
Changed
- Handle
LangErrorfrom instantiate ‒ #1512 - FFI: no more
__unstable__wasm import module ‒ #1522 - Clean up CallBuilder
return()type ‒ #1525 - Fix trait message return type metadata ‒ #1531
- Bump Dylint dependencies ‒ #1551
- Stabilize
take_storage‒ #1568 - Chain Extension: Evaluation of method return type at compile time ‒ #1569
- Make more functions be const ‒ #1574 (thanks @yjhmelody)
- Unify fallible and non fallible
instantiatemethods ‒ #1591 - Make
CallBuilderandCreateBuildererror handling optional ‒ #1602 - Rename
CallBuilder::fire()method toinvoke()‒ #1604 - chore: add minimum rust version to the ink crate ‒ #1609 (thanks @Kurtsley)