-
Notifications
You must be signed in to change notification settings - Fork 319
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
bug: decrementing 0 should fail, but it's getting successful transaction #683
Comments
why does the note talk about value and payable? |
@Eikix I am testing from the "Solidity-by-example" contracts examples, the comments in the contract are from there. Yes, I tried to reproduce on normal remix, the "Expected behavior" mentioned is from the normal remix evm. |
also, the "payable" note from remix I guess it's a default note in some errors, just in case. |
I remember that we once used Actually, running in the playground I do see that it's reverting, but after |
just tried rn adding a test to See #767 |
Time spent on this PR: 0.1 ## Pull request type Please check the type of change your PR introduces: - [ ] Bugfix - [ ] Feature - [x] Code style update (formatting, renaming) - [ ] Refactoring (no functional changes, no api changes) - [ ] Build related changes - [ ] Documentation content changes - [ ] Other (please describe): ## What is the current behavior? A test is marked as failed while it has the expected behavior No test for safe sub. Resolves #683 ## What is the new behavior? Fixed tests. Behavior was already correct.
Bug Report
Kakarot version:
when decrementing 0 it normally should get a failed transaction, but actually it is getting a successful transaction.
Current behavior:
while testing that decrement function with a
count
state0
:when trying to decrementing from the 0 value, although the state value still remains 0, it is getting a successful transaction, it should fail.
Expected behavior:
when trying to decrementing from the 0 value, the txn should revert with an error like that:
Steps to reproduce:
I used that contract:
at the initial state, with count at 0, I tried to call
dec()
, it got a successful transaction.Other information:
EVM environment: Kakarot ZKEVM blockchain (Testnet)
Solidity version: 0.8.17
No balance was sent to the contract upon deployment.
The text was updated successfully, but these errors were encountered: