Skip to content

Commit

Permalink
Skip panic reason in the canonical form (#609)
Browse files Browse the repository at this point in the history
The main reason for removing it from canonical serialization is to avoid
affecting the block ID for different panic reasons. The primary goal is
just to know that some operation was done incorrectly; what exactly
failed is less important. It reduces the chance of getting different
blocks within one panic.

Related VM change: FuelLabs/fuel-vm#826

### Before requesting review
- [x] I have reviewed the code myself
  • Loading branch information
xgreenx authored Sep 13, 2024
1 parent aece3d3 commit b35a2bf
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/abi/receipts.md
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,8 @@ _Important note:_ For the JSON representation of receipts, we represent 64-bit u

- `type`: `Panic`.
- `id`: Hexadecimal string representation of the 256-bit (32-byte) contract ID of the current context if in an internal context. `null` otherwise.
- `reason`: Decimal string representation of an 8-bit unsigned integer; panic reason.
- `reason`: Optional decimal string representation of an 8-bit unsigned integer; panic reason.
Not included in canonical receipt form.
- `pc`: Hexadecimal string representation of a 64-bit unsigned integer; value of register `$pc`.
- `is`: Hexadecimal string representation of a 64-bit unsigned integer; value of register `$is`.
- `contractId`: Optional hexadecimal string representation of the 256-bit (32-byte) contract ID if applicable. `null` otherwise.
Expand Down

0 comments on commit b35a2bf

Please sign in to comment.