Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add a separate error for nonexistent contract input #868

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,9 @@ and this project adheres to [Semantic Versioning](http://semver.org/).
### Fixed
- [860](https://github.com/FuelLabs/fuel-vm/pull/860): Fixed missing fuzzing coverage report in CI.

### Breaking
- [868](https://github.com/FuelLabs/fuel-vm/pull/868): Fixed error message when having a nonexistent contract in inputs. Instead of saying "contract was in inputs, but doesn't exist", the message was just "contract not in inputs". Now there's a separate error for that.

## [Version 0.58.2]

### Fixed
Expand Down
2 changes: 2 additions & 0 deletions fuel-asm/src/panic_reason.rs
Original file line number Diff line number Diff line change
Expand Up @@ -152,6 +152,8 @@ enum_from! {
BlobIdAlreadyUploaded = 0x37,
/// Active gas costs do not define the cost for this instruction.
GasCostNotDefined = 0x38,
/// Given input contract does not exist.
InputContractDoesNotExist = 0x39,
}
}

Expand Down
2 changes: 1 addition & 1 deletion fuel-vm/src/interpreter/executors/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -905,7 +905,7 @@ where
false
}
}) {
return Err(InterpreterError::Panic(PanicReason::ContractNotInInputs));
return Err(InterpreterError::Panic(PanicReason::InputContractDoesNotExist));
}

let gas_limit;
Expand Down
Loading