-
Notifications
You must be signed in to change notification settings - Fork 65
blockifier: box TransactionFeeError in TransactionPreValidationError #7641
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
blockifier: box TransactionFeeError in TransactionPreValidationError #7641
Conversation
|
Artifacts upload workflows: |
e64172f to
e275910
Compare
079d3a4 to
6786b24
Compare
e275910 to
04e09a6
Compare
6786b24 to
0b1815b
Compare
dorimedini-starkware
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reviewable status: 0 of 5 files reviewed, all discussions resolved (waiting on @amosStarkware)
crates/apollo_gateway/src/stateful_transaction_validator_test.rs line 56 at r1 (raw file):
}, ), );
- only used once (inlined below)
Boxfields can't be const
Code quote:
pub const STATEFUL_VALIDATOR_FEE_ERROR: BlockifierStatefulValidatorError =
BlockifierStatefulValidatorError::TransactionPreValidationError(
TransactionPreValidationError::TransactionFeeError(
TransactionFeeError::GasBoundsExceedBalance {
resource: Resource::L1DataGas,
max_amount: GasAmount(VALID_L1_GAS_MAX_AMOUNT),
max_price: GasPrice(VALID_L1_GAS_MAX_PRICE_PER_UNIT),
balance: BigUint::ZERO,
},
),
);
amosStarkware
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reviewed 5 of 5 files at r1, all commit messages.
Reviewable status: all files reviewed, 1 unresolved discussion (waiting on @dorimedini-starkware)
crates/blockifier/src/transaction/execution_flavors_test.rs line 283 at r1 (raw file):
err, TransactionExecutionError::TransactionPreValidationError(boxed_error) => assert_matches!(
There's no difference between an assert_matches! and a guard expression here?
Code quote:
=> assert_matches!(
dorimedini-starkware
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reviewable status: all files reviewed, 1 unresolved discussion (waiting on @amosStarkware)
crates/blockifier/src/transaction/execution_flavors_test.rs line 283 at r1 (raw file):
Previously, amosStarkware wrote…
There's no difference between an
assert_matches!and a guard expression here?
not sure what you mean
if you're asking why can't i do
if matches!(
x,
Y::(boxed_y),
if matches!(
*boxed_y,
Z::ZY(y),
if y == expected_y
)
)
it's because rust complained about ownership; I think moving boxed_y into the inner matches! violates ownership rules
amosStarkware
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reviewable status:
complete! all files reviewed, all discussions resolved (waiting on @dorimedini-starkware)
0b1815b to
e830c2e
Compare
Merge activity
|

No description provided.