Skip to content

v1.4.2

Compare
Choose a tag to compare
@breathx breathx released this 19 Jul 16:21

Release v1.4.2 changes

  • Crates versions bumped to "v1.4.2", runtime spec version bumped to 1420 (#3969);
  • Weights of extrinsic and WASM calls from now on are benched on bare metal machine and WERE updated to fit new network costs (#3994), schedule version was bumped to 1420 (#4035);

Update requirements

Name Character
JS clients ⚪ Insubstantial / 🔴 Required (depending on logic of the program)
Programs 🟡 Recommended
Node bin 🔴 Required

User-space

📚 Supported operating of cargo workspaces in cargo-gbuild (#3960);


📚 Implemented GasTree for gtest (#3962);

Note

From now on, gtests mocking manages messages gas in the same manner as its done on-chain. Previously, all gasless were treated as gas allowance, that wasn't correct.

Warning

That kind of change may fail a lot of your tests, if you didn't calculate gas for them well. Don't worry and properly go through all of the gas limits you apply to your messages.


📚 Added empty implementations for all syscalls for non-wasm target (#3964);

Note

This allows to avoid windows compiling issues, as well as common building for non-wasm targets without extra features.


📚 Implemented new crate for ease of testing: gear-node-wrapper (#4003; #4041);

Note

This crate provides functionality of running separate nodes for tests, operating them through rust codes as OS processes.


📚 Previously implemented RPC call gear_calculateReplyForHandle now has rust api in gsdk and gclient (#3998);


📚 Many gsdk apis, previously required Option<T>, now may accept just T for simplicity (#4022);


📚 According to recent substrate update, primary pallet-balances transfer funcs supported in gsdk and gclient (#4027);

Runtime

📚Allocations of the programs now stored as numerated::IntervalsTree instead of BTreeSet (#3791);

Note

That's one of the latest steps of implementing unlimited memory (up to 4GB due to 32bit arch of WASMs used) for program within Gear Protocol.


📚Fixed core bug of non-atomicity for syscalls that fail and don't revert states on failures (#3901);


📚 Approach of benchmarking was refined and appended with updated weights. Moreover, new benchmarks for WASM notion usages (such as tables etc) were measured (#3929; #4000)

Note

This highly improves security and stability of the network on corner cases and malicious programs.


📚Previous programs pausing logic were totally wiped (#3947);

Key-features of the release

🔥📖 Programs existence balances invariant implemented (#3961);

Note

From now on each active program is guaranteed to have balances key for it with non-zero balance: it has 1 Vara (ED) token locked as fixed deposit, that could only be withdrawn on programs gr_exit termination.

This highly simplifies code base and improves UX of network interacting due to absence of previous restrictions and bound in favour of just one token locked on each program creation. Moreover, it makes possible to guarantee safety of the upcoming updates such as staking built-in.

For already existing programs, migrations will provide supply for it from treasury.

Important

There's no more limits of outgoing value for programs' messaging and users' extrinsic: you can send even 1/(10^12) of token.


📚 Bls381 built-in actor was extended with new cryptographic calls (#3948);

Note

These fns are aggregate_g1 and map_to_g2affine, that are necessary for some operations.

Important

⚠️ This change caused changes in node binary (providing the host calls impl). And due to this change it's necessary to update before runtime upgrade with the release! Make sure to perform update of your RPC and validator in due time.


📚 Gear Protocol primitive types were merged into one single crate (#3919);

Note

If previously you were dependent on multiple gear crates such as gstd, gcore and even gsdk, you might have noticed, that each of these declares it's own primitives that convertible to others. This was causing a plenty of problems and difficulties while developing. Especially if we speak about io crates.

Now all of them (ActorId, CodeId, MessageId etc) are merged into gprimitives and used across all of our libraries within the project.

It's worth noticing that this crate re-exports primitive-types from parity and implements its own NonZeroU256 (#4012);

Full Changelog: v1.4.1...v1.4.2