Commit 336abcd
authored
# Release notes
In this release, we:
- Bumped `fuel-core` to `0.42.0`
- Added support for simulating calls at specific block height
# Breaking Changes
- **Error Variant Renaming:**
- The transaction `Reason` error variant previously named `Reverted` in
transaction errors is now renamed to `Failure`.
- The associated `revert_id` field is now an `Option<u64>` rather than a
plain `u64`.
- **Usage:** Update pattern matches and error handling to check for
`Error::Transaction(Reason::Failure { .. })` and handle the optional
`revert_id` accordingly.
- **Execution Simulation API Changes:**
- The simulation execution mode has changed from enum variants to a
struct with helper functions:
- Replace **`Execution::Realistic`** with **`Execution::realistic()`**.
- Replace **`Execution::StateReadOnly`** with
**`Execution::state_read_only()`**.
- To simulate at a specific block height, chain the call with
`.at_height(height)`. Note that the node needs to support historical
execution.
- The `dry_run_opt` method's `utxo_validation` argument changed to
`Option<bool>` and a new argument `at_height: Option<BlockHeight>` is
added.
- The method **`determine_missing_contracts`** no longer accepts an
optional parameter; it is now called without arguments and will
determine all missing contracts in one simulation.
- **`tx_status` changes**
- The `Revert` variant has been replaced by the `Failure` variant.
- New variants have been added: `PreconfirmationSuccess` and
`PreconfirmationFailure`.
- The `revert_id` type changed to `Option<u64>`
- **Usage:** Update your pattern matching and error handling logic.
- **Amount Type Updates:**
- Functions across accounts, wallets, predicates, and providers have
switched from using `u64` to `u128` for asset amounts.
- **Usage:** Modify function calls (e.g., `get_asset_inputs_for_amount`,
`adjust_for_fee`, etc.) to pass amounts as `u128` (or convert them using
`.into()` if needed).
- **Node Configuration Adjustments:**
- The `NodeConfig` struct now includes a new boolean field:
`historical_execution`.
- **Usage:** To use `historical_execution` launch a node (with `rocksdb`
enabled) and the `historical_execution` flag set.
1 parent 3f84ea3 commit 336abcd
File tree
31 files changed
+721
-326
lines changed- .github/workflows
- docs/src/calling-contracts
- e2e/tests
- examples
- contracts
- src
- cookbook/src
- packages
- fuels-accounts/src
- provider
- schema
- fuels-core/src/types
- wrappers
- fuels-programs/src
- calls
- fuels-test-helpers/src
31 files changed
+721
-326
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
16 | 16 | | |
17 | 17 | | |
18 | 18 | | |
19 | | - | |
| 19 | + | |
20 | 20 | | |
21 | 21 | | |
22 | 22 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
95 | 95 | | |
96 | 96 | | |
97 | 97 | | |
98 | | - | |
| 98 | + | |
99 | 99 | | |
100 | 100 | | |
101 | | - | |
102 | | - | |
103 | | - | |
104 | | - | |
105 | | - | |
| 101 | + | |
| 102 | + | |
| 103 | + | |
| 104 | + | |
| 105 | + | |
106 | 106 | | |
107 | 107 | | |
108 | | - | |
109 | | - | |
110 | | - | |
111 | | - | |
112 | | - | |
113 | | - | |
114 | | - | |
| 108 | + | |
| 109 | + | |
| 110 | + | |
| 111 | + | |
| 112 | + | |
| 113 | + | |
| 114 | + | |
115 | 115 | | |
116 | 116 | | |
117 | 117 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2 | 2 | | |
3 | 3 | | |
4 | 4 | | |
5 | | - | |
| 5 | + | |
6 | 6 | | |
7 | 7 | | |
8 | 8 | | |
9 | 9 | | |
10 | 10 | | |
11 | | - | |
| 11 | + | |
12 | 12 | | |
13 | 13 | | |
14 | 14 | | |
15 | 15 | | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
14 | 14 | | |
15 | 15 | | |
16 | 16 | | |
17 | | - | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
18 | 23 | | |
19 | 24 | | |
20 | 25 | | |
21 | 26 | | |
22 | 27 | | |
23 | | - | |
24 | | - | |
25 | | - | |
| 28 | + | |
0 commit comments