Releases: FuelLabs/fuel-vm
v0.38.0
Version 0.38.0
The release adds no_std
compatible canonical serialization/deserialization. Along with it, all crates were updated to be no_std
compatible. The whole repository is now WASM and RiscV compatible.
Added
- #586: Added
default_asset
method to theContractIdExt
trait implementation, to mirror thedefault
method on AssetId in the Sway std lib.
Changed
Breaking
- #578: Support
no_std
environments forfuel-crypto
, falling back to a pure-Rust crypto implementation. - #582: Make
fuel-vm
andfuel-tx
crates compatible withno_std
+alloc
. This includes reworking all error handling that usedstd::io::Error
, replacing somestd::collection::{HashMap, HashSet}
withhashbrown::{HashMap, HashSet}
and many changes to feature-gating of APIs. - #587: Replace
thiserror
dependency withderive_more
, so thatcore::fmt::Display
is implemented without thestd
feature. Removesstd::io::Error
trait impls from the affected types. - #588: Re-worked the size calculation of the canonical serialization/deserialization.
Removed
- #588: Removed
SerializedSize
andSerializedFixedSize
traits. Removed support forSIZE_NO_DYNAMIC
andSIZE_STATIC
. Removed enum attributes from derive macro forSerialize
andDeserialize
traits.
What's Changed
- no_std fuel-crypto by @Dentosal in #578
- Add default_asset method by @SwayStar123 in #586
- no_std support for
fuel-tx
andfuel-vm
by @Dentosal in #582 - Replace thiserror with derive_more::Display by @Dentosal in #587
- Follow-up for canonical se/de after an additional round of review by @xgreenx in #588
- Release 0.38.0 by @Dentosal in #590
New Contributors
- @SwayStar123 made their first contribution in #586
Full Changelog: v0.37.0...v0.38.0
v0.37.0
Version 0.37.0
Breaking
- #573: Added
base_asset_id
as a required field toFeeParameters
.base_asset_id
is used to supply the ID of the base asset. - #554: Removed
debug
feature from thefuel-vm
. The debugger is always available and becomes active after calling anyset_*
method. - #537: Use dependent cost for
k256
,s256
,mcpi
,scwq
,swwq
opcodes.
These opcodes charged inadequately low costs in comparison to the amount of work.
This change should make all transactions that used these opcodes much more expensive than before. - #533: Use custom serialization for fuel-types to allow
no_std
compilation.
What's Changed
- Use dependent cost for missed opcodes by @xgreenx in #537
- Update CI RUST_VERSION to 1.72.0 by @bvrooman in #575
- Remove
debug
feature fromfuel-vm
and use debugger by default. by @xgreenx in #554 - fix: Fixed length input for BMT
node_sum
by @bvrooman in #574 - Use custom derive ser/de instead of std::io by @Dentosal in #533
- feat: Impl
fmt::Display
for canonical Error by @bvrooman in #580 - fix: Organize
ConsensusParameters
gas costs in alphabetical order by @bvrooman in #581 - feat: Configurable Base Asset ID by @bvrooman in #573
- Upgrade to version 0.37.0 by @bvrooman in #583
Full Changelog: v0.36.1...v0.37.0
v0.35.4
Version 0.35.4
Fixed
- #548: Bumped dalek to
2.0.0
to fix security vulnerability.
What's Changed
- Bump dalek version to deal with security vulnerability by @MitchTurner in #548
Full Changelog: v0.35.3...v0.35.4
v0.36.1
Version 0.36.1
Changed
- #546: Improve debug formatting of instruction in panic receipts.
Fixed
- #547: Bump
ed25519-dalek
to2.0.0
to deal with RustSec Advisory - #524: Fix a crash in
CCP
instruction when overflowing contract bounds. Fix a bug inCCP
where overflowing contract bounds in a different way would not actually copy the contract bytes, but just zeroes out the section. Fix a bug inLDC
where it would revert the transaction when the contract bounds were exceeded, when it's just supposed to fill the rest of the bytes with zeroes.
What's Changed
- Instruction debug fmt improvements by @Dentosal in #546
- Fix a crash in CCP and zero-filling issues in CCP and LDC by @Dentosal in #524
- Bump dalek version because of RustSec Advisory by @MitchTurner in #547
Full Changelog: v0.36.0...v0.36.1
v0.36.0
Version 0.36.0
Changed
- #525: The
$hp
register is no longer restored to it's previous value when returning from a call, making it possible to return heap-allocated types fromCALL
. - #535: Add better test coverage for TR and TRO.
Breaking
- #514: Add
ChainId
andGasCosts
toConsensusParameters
.
Break downConsensusParameters
into sub-structs to match usage. Change signatures of functions to ask for
necessary fields only. - #532: The
TRO
instruction now reverts when attempting to send zero coins to an output. Panic reason of thisTransferZeroCoins
, andTR
was changed to use the same panic reason as well.
Fixed
-
#511: Changes multiple panic reasons to be more accurate, and internally refactors instruction fetch logic to be less error-prone.
-
#529 #534: Enforcing async WASM initialization for all NPM wrapper packages.
-
#531: UtxoId::from_str and TxPointer::from_str no longer crash on invalid input with multibyte characters. Also adds clippy lints to prevent future issues.
Breaking
- #527: The balances are empty during predicate estimation/verification.
What's Changed
- Decompose consensus params by @MitchTurner in #514
- Make
ConsensusParameters
Serialize/Derserialize again by @MitchTurner in #526 - Follow-up clean ups and fixed for the VM initialization by @xgreenx in #527
- Add a CI action to enforce changelog modification by @xgreenx in #528
- Initializing WASM synchronously by @arboleya in #529
- Reimplement
with_params
method for TxBuilder by @MitchTurner in #530 - Do not restore $hp when returning from a context by @Dentosal in #525
- Make TRO instruction revert on zero coin amount by @Dentosal in #532
- Fix a crash in UtxoId::from_str and TxPointer::from_str with multibyte characters by @Dentosal in #531
- Forcing async wasm initialization by @arboleya in #534
- Duplicate release 0.35.2 by @xgreenx in #540
- Add more test cases for
transfer
andtransfer_output
by @MitchTurner in #535 - Duplicate changes from 0.35.3 release by @xgreenx in #543
- Return correct PanicReason on memory-related panics by @Dentosal in #511
- Add push/pop instructions by @Dentosal in #498
- Fix urls to specification by @Voxelot in #544
- Release v0.36.0 by @xgreenx in #545
New Contributors
- @MitchTurner made their first contribution in #514
Full Changelog: v0.35.3...v0.36.0
v0.35.3
v0.35.2
Version 0.35.2
Changed
Breaking
- #539: Rollbacked the change for the gas charging formula.
Actualized the gas prices for opcodes.
What's Changed
- Actualization of the gas prices for the
fuel-core 0.20
release in #539 - The change reverts part of the #504 related to gas charging in #539
Full Changelog: v0.35.1...v0.35.2
v0.35.1
Release v0.35.1
The minor release to trigger publishing of the fuel-asm
and fuel-types
to npm.
Added
- #499: The
wasm_bindgen
support offuel-asm
andfuel-types
.
Each new release also publish a typescript analog of thefuel-asm
andfuel-types
crates to the npm.
What's Changed
- The
wasm_bindgen
support offuel-asm
andfuel-types
by @xgreenx in #499 - Release v0.35.1 by @xgreenx in #517
- Fixing NPM-publish workflow by @arboleya in #519
Full Changelog: v0.35.0...v0.35.1
v0.35.0
Release v0.35.0
The release mostly fixes funding during the audit and integration with the bridge. But the release also contains some new features like:
- Asynchronous predicate estimation/verification.
- Multi-asset support per contract.
- Support Secp256r1 signature recovery and Ed25519 verificaiton.
Added
-
#486: Adds
ed25519
signature verification andsecp256r1
signature recovery tofuel-crypto
, and corresponding opcodesED19
andECR1
tofuel-vm
. -
#500: Introduced
ParallelExecutor
trait
and made available async versions of verify and estimate predicates.
Updated tests to test for both parallel and sequential execution.
Fixed a bug intransaction/check_predicate_owners
.
Breaking
- #506: Added new
Mint
andBurn
variants toReceipt
enum.
It affects serialization and deserialization with new variants.
Changed
Breaking
-
#506: The
mint
andburn
opcodes accept a new$rB
register. It is a sub-identifier used to generate an
AssetId
by this rule.
This feature allows having multi-asset per one contract. It is a huge breaking change, and
after this point,ContractId
can't be equal toAssetId
.The conversion like
AssetId::from(*contract_id)
is no longer valid. Instead, theContractId
implements theContractIdExt
trait:/// Trait extends the functionality of the `ContractId` type. pub trait ContractIdExt { /// Creates an `AssetId` from the `ContractId` and `sub_id`. fn asset_id(&self, sub_id: &Bytes32) -> AssetId; }
-
#506: The
mint
andburn
opcodes affect thereceipts_root
of theScript
transaction.
Removed
Breaking
- #486: Removes apparently unused
Keystore
andSigner
traits fromfuel-crypto
. Also renamesECR
opcode toECK1
.
Fixed
- #500: Fixed a bug where
MessageCoinPredicate
wasn't checked for incheck_predicate_owners
.
Breaking
-
#502: The algorithm used by the
binary Merkle tree for generating Merkle proofs has been updated to remove
the leaf data from the proof set. This change allows BMT proofs to conform
to the format expected by the Solidity contracts used for verifying proofs. -
#503: Use correct amount of gas in call
receipts when limited by cgas. Before this change, theReceipt::Call
could show an incorrect value for the gas limit. -
#504: The
CROO
andCSIZ
opcodes require
the existence of correspondingContractId
in the transaction's
inputs(the same behavior as for theCROO
opcode). -
#504: The size of the contract
was incorrectly padded. It affects the end of the call frame in the memory,
making it not 8 bytes align. Also, it affects the cost of the contract
call(in some cases, we charged less in some more). -
#504: The charging for
DependentCost
was done incorrectly, devaluing thedep_per_unit
part. After the fixing of
this, the execution should become much more expensive. -
#505: The
data
field of theReceipt
is not part of the canonical serialization and deserialization anymore. The SDK should use the
Receipt
type instead ofOpaqueReceipt
. TheReceipt.raw_payload
will be removed for the
fuel-core 0.20
. Thedata
field is optional now. The SDK should update serialization and
deserialization forMessageOut
,LogData
, andReturnData
receipts. -
#505: The
len
field of theReceipt
is not padded anymore and represents an initial value.
All changes:
What's Changed
- Some additional test to verify ecrecovery with
TxId
and coin witness by @xgreenx in #495 - Add argument names to fuel-asm opcodes by @Dentosal in #497
- Use correct amount of gas in call receipts when limited by cgas by @Dentosal in #503
- bug: Remove leaf data from BMT proofs by @bvrooman in #502
- Bugfixes found during chatting with Auditors on July 7th by @xgreenx in #504
- Removed the
data
field from canonical serialization and deserialization of receipts by @xgreenx in #505 - Secp256r1 signature recovery and Ed25519 verification by @Dentosal in #486
- enable parallel predicate verification by @leviathanbeak in #500
- Support of the multi-assets per contract by @xgreenx in #506
Full Changelog: v0.34.1...v0.35.0
v0.34.1
Release v0.34.1
Mainly new opcodes prices and small performance improvements in the BinaryMerkleTree
.
Changed
- #492 Minor improvements to BMT internals, including a reduction in usage of
Box
, usingexpect(...)
overunwrap()
, and additional comments.
Breaking
- #493 The default
GasCostsValues
is updated according to the benches withfuel-core 0.19
. It may break some unit tests that compare actual gas usage with expected.
What's Changed
- chore: BMT clean up by @bvrooman in #492
- Update gas prices based on
fuel-core 0.19
by @xgreenx in #493
Full Changelog: v0.34.0...v0.34.1